3

How to handle permission dialog box during screen orientation in Android M devices?

In my case, after changing screen orientation, and clicking Okay button in permission dialog box crashes the app.

naXa stands with Ukraine
  • 35,493
  • 19
  • 190
  • 259
Sudhir Sinha
  • 693
  • 9
  • 18

1 Answers1

1

My workaround for this situation: Once permission dialog box is coming, I am locking up the screen to its current orientation (portrait/landscape). When user presses the button, I am unlocking the screen.

For Locking/unlocking the orientation, refer the link: Android: Temporarily disable orientation changes in an Activity

Community
  • 1
  • 1
Sudhir Sinha
  • 693
  • 9
  • 18