开发者

How to preform an activity at the android lock screen?

I would like to perform an activity at the key guard screen, but the only way I can find to do so is to disable the key guard, do my ac开发者_JAVA百科tivity, then re enable the key guard. This would be ok if it didn't cause the key guard screen to flash off and on (disable makes it disappear then re enable brings it back). I am wondering how I can perform an activity with it still being displayed? Kinda like how when the alarm goes off it shows a pop-up which is displayed over the key-guard screen?


You can check out Alarm clock source on Android git, maybe that will help, also Music player does something similar to what you mentioned. So my advice is download snapshots of Music Player app and AlarmClock app from android git, and search those files for KeyGuardManager.

https://android.googlesource.com/platform/packages/apps/Music/+/master

https://android.googlesource.com/platform/packages/apps/AlarmClock/+/master

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜