When clicking on the app-shortcut, I am opening an Activity with a Dialog theme. It seems that the app-shortcuts are not closed if I use that theme on the Activity. If I delete the Dialog theme, the app-shortcuts are closed after clicking on one of them. Any idea? Thanks!
Asked
Active
Viewed 350 times
5
-
Hi, I tried the same to launch an Activity which has a dialog theme. But every time the activity is launched. The screen flickers and feels like the dialog is displayed twice. Any idea where I would be going wrong? – PunK _l_ RuLz Sep 11 '18 at 08:19
1 Answers
1
I was able to reproduce your problem, at least with the Pixel Launcher.
The rendering and behavior of app shortcuts is up to the app that is showing the shortcuts. Perhaps the Pixel Launcher is only collapsing the app shortcuts panel in onStop()
. When a shortcut launches a full-screen activity, the launcher activity is called with onStop()
, and so the app shortcuts panel goes away. But, when a shortcut launches a dialog-themed activity, the launcher activity is not called with onStop()
(since it is still visible), and so the app shortcuts panel remains.
Regardless, this behavior will vary by home screen (or other user of app shortcuts), and there is nothing much that you can really do about it.

CommonsWare
- 986,068
- 189
- 2,389
- 2,491