Home > Software design >  Is there any way to remove "While Using The App" option from each permissions popup?
Is there any way to remove "While Using The App" option from each permissions popup?

Time:11-27

Due to some compliance, We are only allowed to take respective permission each time when user use that feature.

Obvious Scenario Required Scenario
Obvious Scenario Required Scenario

CodePudding user response:

The short answer is, you can't.

As android documentation puts:

When your app calls requestPermissions(), the system shows a standard dialog box to the user. Your app cannot configure or alter that dialog box. If you need to provide any information or explanation to the user, you should do that before you call requestPermissions(), as described in "Explain why the app needs permissions".

So, there is no way to change dialog for the permission.

You can find more detailed information here: http://developer.android.com/training/permissions/requesting.html

CodePudding user response:

There's no way to do that. But what you can do is use checkSelfPermission to see if you've already been granted that permission, and if so pop up a custom dialog to ensure it's still ok. Obviously the OS can't enforce that, but you can.

  • Related