Questions tagged [system-alert-window]

Allows an app to create windows using the type TYPE_SYSTEM_ALERT, shown on top of all other apps. Very few apps should use this permission; these windows are intended for system-level interaction with the user.

Allows an app to create windows using the type TYPE_SYSTEM_ALERT, shown on top of all other apps. Very few apps should use this permission; these windows are intended for system-level interaction with the user. https://developer.android.com/reference/android/Manifest.permission.html#SYSTEM_ALERT_WINDOW

61 questions
99
votes
5 answers

SYSTEM_ALERT_WINDOW - How to get this permission automatically on Android 6.0 and targetSdkVersion 23

Facebook, Evernote, Pocket - all apps get this permission on Android 6.0 automatically, even though they are targeting 23 (targetSdkVersion=23). There has been a lot of documentation regarding the new Marshmallow permission model. One of them is…
13
votes
0 answers

Which permissions do not stay upon upgrade to targetSdk 23 or Android 6?

Background I remember that it was told (on one of Google's videos) that if the previous version of the app was updated to have targetSdk 23 on the new version, ALL permissions that were granted before - will stay granted now. So, for example, if you…
android developer
  • 114,585
  • 152
  • 739
  • 1,270
13
votes
2 answers

DialogFragment not showing after adding Alert Window

I have a function that when triggered, succesfully displays a DialogFragment with the following code DialogFragment DialogFragment dialog; View dialogView; Context activityContext; ... dialog = new DialogFragment(){ @Override public Dialog…
6
votes
2 answers

How does AccessibilityService draw on top of other apps?

Background SAW (system alert window) permission can be used to draw content on top of other apps. I was told a very long time ago that accessibility service can do this too, but I never found any tutorial, sample, documentation and even an app that…
android developer
  • 114,585
  • 152
  • 739
  • 1,270
6
votes
1 answer

How to make background of system-overlay view MULTIPLY (blending-mode)?

A little context for my problem first: I'm trying to create a system-overlay type view (i.e. draw over other apps) that is (for now) just a full-screen solid colour. I'm turning it on/off by starting/stopping a service. Here's what my code looks…
andeart
  • 935
  • 6
  • 19
5
votes
5 answers

Settings.canDrawOverlays is returning false even after turning the permission on from settings

I am trying billow Code from this answer to check if the permission is enabled. but it is returning false even when the permission is enabled from the settings. public static boolean canDrawOverlayViews(Context con){ if(Build.VERSION.SDK_INT<…
Shafin Abrar
  • 471
  • 1
  • 5
  • 12
5
votes
2 answers

How to detect when my Activity has been obscured?

I would like to be able to detect if my Activity has been obscured by, say, a system alert or some other overlay (for example the power menu when I long press on the power button), or some malware that detects the launch of my Activity. I noticed…
user1118764
  • 9,255
  • 18
  • 61
  • 113
5
votes
0 answers

There is a way to detect the some app is obscured my app, not by touch

I know there is a way to detect if some app overlays my app, i.e. touch filtering(flag android:filterTouchesWhenObscured) against hijacking attacks. If you want to create some policy to handle touches you may override the method public boolean…
yugico
  • 161
  • 2
  • 11
4
votes
2 answers

Android 11 SYSTEM_ALERT_WINDOW behaviour changes with SurfaceView

Some time ago with Android 11 SYSTEM_ALERT_WINDOW draw-over-applications touch behaviour was limited with a number of exceptions. Interactions within your app. Accessibility windows Input method editor (IME) windows Assistant windows Completely…
Arturs Vancans
  • 4,531
  • 14
  • 47
  • 76
4
votes
1 answer

Prevent application with SYSTEM_ALERT_WINDOW from obscuring my application

Is there any way to assure that my application's window is not obscured by any other application's view using with SYSTEM_ALERT_WINDOW permission? If not, then is there any better way to assure that my app is not obscured by such window apart from…
3
votes
2 answers

Android: App Can't Be Granted SYSTEM_ALERT_WINDOW,

I am creating an android application that uses WindowManager type: TYPE_APLICATION_OVERLAY so it requires this permission in the manifest file: Which already exists in the…
3
votes
3 answers

How do apps detect that SAW permission is currently being used?

Background I've noticed many times, that when I use an app that uses SAW (system-alert-window, AKA "display over other apps) permission (example here), and I open Chrome web browser and reach some website that requires a permission (example here,…
android developer
  • 114,585
  • 152
  • 739
  • 1,270
3
votes
0 answers

How to test SYSTEM_ALERT_WINDOW permission granted when downloaded from Google Play Store

According to this : SYSTEM_ALERT_WINDOW - How to get this permission automatically on Android 6.0 and targetSdkVersion 23, the permission SYSTEM_ALERT_WINDOW is automatically given when the app is downloaded from the play store. Is there a way to…
3
votes
1 answer

Android AlertDialog: TYPE_SYSTEM_ALERT

I have tried out everything I know and can find, but still I cannot get my alert dialog to show as a TYPE_SYSTEM_ALERT. It shows on my app when I open it, but it does not pop up if my app is not on front. I've got: final AlertDialog.Builder d = new…
raki
  • 53
  • 1
  • 8
2
votes
0 answers

How to show a window overlay over the accessibility menu in android 10?

I have done some code which is working fine everywhere except settings app -> accessibility menu or device admin apps menu I need to display overlay in settings -> accessibility and device admin apps menu I have a application where i see this type…
1
2 3 4 5