Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App is crashing - permission denied on window type 2006 error #48

Open
ShrutiSantosh opened this issue May 6, 2019 · 15 comments
Open

Comments

@ShrutiSantosh
Copy link

App is crashing with permission denied on window type 2006 error , on Initializing bubble on android p version devices, even though I added permission in manifest as well as java class.

@Ahsaashafeez
Copy link

Same issue!

@mohElsayed1997
Copy link

same issue

@janakact
Copy link

Same issue

07-17 15:20:33.399 28742 28742 E AndroidRuntime: FATAL EXCEPTION: main
07-17 15:20:33.399 28742 28742 E AndroidRuntime: Process: ******* PID: 28742
07-17 15:20:33.399 28742 28742 E AndroidRuntime: android.view.WindowManager$BadTokenException: Unable to add window android.view.ViewRootImpl$W@83f9942 -- permission denied for window type 2006
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.view.ViewRootImpl.setView(ViewRootImpl.java:958)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java:398)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:131)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at com.txusballesteros.bubbles.h.run(Unknown Source:12)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.os.Handler.handleCallback(Handler.java:907)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.os.Handler.dispatchMessage(Handler.java:105)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.os.Looper.loop(Looper.java:216)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at android.app.ActivityThread.main(ActivityThread.java:7593)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at java.lang.reflect.Method.invoke(Native Method)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
07-17 15:20:33.399 28742 28742 E AndroidRuntime:        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)
07-17 15:20:33.400 28742 28742 E e.g.a.d : FATAL EXCEPTION: mainandroid.view.WindowManager$BadTokenException: Unable to add window android.view.ViewRootImpl$W@83f9942 -- permission denied for window type 2006

@SilvioLuis
Copy link

Same here!

@anibalbastiass
Copy link

same issue

@M-Cholewa
Copy link

Try
if (!Settings.canDrawOverlays(this)) { Intent intent = new Intent(Settings.ACTION_MANAGE_OVERLAY_PERMISSION, Uri.parse("package:" + getPackageName())); startActivityForResult(intent, 5054); }else { bubblesManager.addBubble(bubbleView, 60, 20); }

@abdelrahmana
Copy link

i have been working on this issue and i fixed it please go a head to my modification and clone it
https://github.com/abdelrahmana/bubble-Android-
cheers

@Try64
Copy link

Try64 commented Jan 27, 2020

i have been working on this issue and i fixed it please go a head to my modification and clone it
https://github.com/abdelrahmana/bubble-Android-
cheers

Worked for me. Thank you @abdelrahmana. [BTW I have given star at your repo :) ]
Just added permission before initialization and Woala......

@farhaanbukhsh
Copy link

i have been working on this issue and i fixed it please go a head to my modification and clone it
https://github.com/abdelrahmana/bubble-Android-
cheers

Hey why don't you make a proper PR to this fix? It will be a valid help to all of us thanks, in case you need help to do that I can help you. ❤️

@princevatsal
Copy link

princevatsal commented Apr 9, 2020

I find a solution and worked for me
in Build.grade (Module:app)
replace compile 'com.txusballesteros:bubbles:1.2.1'
to
implementation 'com.github.txusballesteros:bubbles-for-android:develop-SNAPSHOT'

@farhaanbukhsh
Copy link

I find a solution and worked for me
in Build.grade (Module:app)
replace compile 'com.txusballesteros:bubbles:1.2.1'
to
implementation 'com.github.txusballesteros:bubbles-for-android:develop-SNAPSHOT'

Because it's not official release its from develop branch

@muriloinflue
Copy link

'com.github.txusballesteros:bubbles-for-android:develop-SNAPSHOT'

This worked. Can't this be applied to the live version of the package?

@cparello
Copy link

cparello commented Oct 22, 2020 via email

@KuiGoan
Copy link

KuiGoan commented Dec 17, 2020

@nils-trubkin
Copy link

I find a solution and worked for me
in Build.grade (Module:app)
replace compile 'com.txusballesteros:bubbles:1.2.1'
to
implementation 'com.github.txusballesteros:bubbles-for-android:develop-SNAPSHOT'

This is a fair workaround considering that dev branch is 2 commits ahead, fixing this exact issue. Furthermore, I had to add "maven { url "https://jitpack.io" }" under repositories for this to work. I followed this answer https://stackoverflow.com/questions/33058358/jitpack-io-failed-to-resolve-github-repo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests