1

Hi i am trying to get SYSTEM_ALERT_WINDOW permission i have added <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" /> in my manifest file. Now when i install the release build, it asks for permission and everything works as expected in marshmallow. But when i install it from playstore it automatically grants me SYSTEM_ALERT_WINDOW permission, but when i try to start a System overlay service, it is giving me error.

W/ActivityManager: Appop Denial: Accessing service ComponentInfo{packagename/packagename.classname} from pid=6189, uid=10289 requires appop SYSTEM_ALERT_WINDOW

But when i checked facebook chathead it was working without asking me permissions.

How do i check for appop denial permissions?

Pranav Agrawal
  • 466
  • 6
  • 17

1 Answers1

0

It may not be asking for the permissions if already allowed please check as below:

No permissions have been granted if you go to Settings > Apps > "Your app" > Permissions.

You should uninstall clear app data and uninstall it completely, then install via playstore.

If you don't want to do implement the new system yet then you can reduce your target sdk version to 22 to get the old permission system. You can still compile with sdk version 23 though.

Thanks

Androider
  • 3,833
  • 2
  • 14
  • 24
  • When i am installing via playstore at that time i am facing is appop denial problem, refering this post : http://stackoverflow.com/questions/36016369/system-alert-window-how-to-get-this-permission-automatically-on-android-6-0-an/36019034 – Pranav Agrawal Oct 19 '16 at 12:20