Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法获得锁屏预览。
我正在编写一个需要设置墙纸的应用程序,然后看看它会是什么样子。由于没有 API 支持显示锁定屏幕预览,所以我正在寻找其他方式。
这里有什么建议吗?
不,没有预览,但您始终可以通过代码锁定您的设备:
KeyguardManager keyguardManager = (KeyguardManager)getSystemService(Activity.KEYGUARD_SERVICE); KeyguardLock lock = keyguardManager.newKeyguardLock(KEYGUARD_SERVICE); lock.reenableKeyguard();