I have an app running fine on Fire OS 7 (Fire HD 10 9th & 11th gen), but has this issue on Fire OS 8 (Fire HD 10 13th gen.): Can’t auto-dismiss the Keyguard: I get these messages within Logcat when I try to do it:
cannot setShowWhenLocked without com.amazon.permission.ENABLE_KEYGUARD_FLAGS permission.
cannot dismissKeyguard without com.amazon.permission.ENABLE_KEYGUARD_FLAGS permission.
The question is: How can I grant this permission? I have tried adding the permission to the Manifest and requesting it at runtime, but is never granted. I also haven’t found any related entry within the Settings app.
Some more details:
- My app runs a foreground service, that launches an activity when some alert is received.
- The activity turns the screen on and dismisses the keyguard using the following code in onResume():
setTurnScreenOn(true);
setShowWhenLocked(true);
keyguardManager.requestDismissKeyguard(this, new KeyguardManager.KeyguardDismissCallback() ...
- It works fine on the latest Fire OS 7 (7.3.3.1)
- It doesn’t work on the latest Fire OS 8 (8.3.3.1)
Thanks.