How to simulate sleep mode on Android emulator

前端 未结 6 1809
遇见更好的自我
遇见更好的自我 2020-12-30 19:36

Some users of my Android application report bugs when the mobile enters sleep/power saving mode.

I would like to test that issue on the Android Virtual Device. Is it

6条回答
  •  情歌与酒
    2020-12-30 20:09

    Try the following on emulator

    1. Go to Settings
    2. Go to Developer options
    3. Un-check Stay awake (3rd option from the top)

    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 is not enabled by default, to enable it, do the following:

    1. Go to Settings
    2. Click About emulated device
    3. Click Build number 7 times, you should be notified that Developer options is now enabled
    4. Go back and you should see Developer options

提交回复
热议问题