如何在Android模拟器上模拟睡眠模式 [英] How to simulate sleep mode on Android emulator
本文介绍了如何在Android模拟器上模拟睡眠模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的Android应用程序的某些用户在手机进入睡眠/省电模式时报告错误.
Some users of my Android application report bugs when the mobile enters sleep/power saving mode.
我想在Android虚拟设备上测试该问题.是否可以在AVD上模拟手机进入睡眠/省电模式?
I would like to test that issue on the Android Virtual Device. Is it possible to simulate the mobile entering in sleep/power saving mode on the AVD ?
谢谢.
推荐答案
在模拟器上尝试以下操作
Try the following on emulator
- 转到
Settings
- 转到
Developer options
- 取消选中
Stay awake
(顶部的第3个选项)
- Go to
Settings
- Go to
Developer options
- Un-check
Stay awake
(3rd option from the top)
如果未更改,模拟器将在1分钟后进入睡眠状态(默认设置).
The emulator will go to sleep after 1 min (default setting) if not changed.
按下电源按钮唤醒仿真器.
Press the power button to wake up the emulator.
Developer options
默认情况下未启用,要启用它,请执行以下操作:
Developer options
is not enabled by default, to enable it, do the following:
- 转到
Settings
- 点击
About emulated device
- 单击
Build number
7次,系统会通知您Developer options
已启用 - 返回,您应该会看到
Developer options
- Go to
Settings
- Click
About emulated device
- Click
Build number
7 times, you should be notified thatDeveloper options
is now enabled - Go back and you should see
Developer options
这篇关于如何在Android模拟器上模拟睡眠模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文