简体   繁体   中英

How to dismiss permissions dialog programmatically?

When the user pauses/closes the screen, while a permissions prompt dialog is active, the dialog persists over the locked screen when the user tries to use the phone again (and needs to make a choice for the dialog to go away).

Although a detail, it does not look very nice, and I would like to dismiss that prompt dialog in onPause() . How can I do that? Perhaps I should programmatically choose to deny permissions in onPause() instead?

From another point of view, it is also not very nice that user can't continue his task when returning to your app. So, persistent dialog is a feature and the point is that user decides when to deny or accept permissions - it's the best to not do anything programmatically

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM