I hope this question wasn´t asked before, but I couldn´t find any solution for my problem. I have a widget which is also used for keyguard. I want to add an onClick handler for my widget. There is no problem, when the widget is on home-screen, the activity starts normally. But on keyguard the activity is launched, but isn´t shown, because the device is locked.
I don´t want to dismiss the keyguard with flags like WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED
and WindowManager.LayoutParams.FLAG_DISMISS_KEYGUARD
. I just want a little window to be shown, where I am asked to unlock the device, like it is opened when you click on several keyguard widgets, like for the android e-mail application.
Is there another flag to achieve this? Or do I have to do something with my intent, called to open the activity? Thanks for help.