diff options
| -rw-r--r-- | core/java/android/provider/Settings.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java index 27ba72b97d7c..171407c88b5d 100644 --- a/core/java/android/provider/Settings.java +++ b/core/java/android/provider/Settings.java @@ -3061,7 +3061,9 @@ public final class Settings { */ public static boolean canDrawOverlays(Context context) { return Settings.isCallingPackageAllowedToDrawOverlays(context, Process.myUid(), - context.getOpPackageName(), false); + context.getOpPackageName(), false) || context.checkSelfPermission( + Manifest.permission.SYSTEM_APPLICATION_OVERLAY) + == PackageManager.PERMISSION_GRANTED; } /** |