Dim iPhone Screen, but don't let it sleep

前端 未结 5 792
无人及你
无人及你 2021-01-31 18:12

Update

https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIScreen_Class/index.html#//apple_ref/occ/instp/UIScreen/brightness

That\'s the Ap

5条回答
  •  眼角桃花
    2021-01-31 18:19

    You can use this approach http://oleb.net/blog/2014/02/alarm-clock-apps-ios/

    Just add a parameter into info.plist. And your app still run when your screen dim, your device locked.

    When you debug, your app still run and never dim automatically, you just press lock button to test.

    When you run your app without debug, you can see this feature do, like Music app of Apple, the music still play when device go to turn off screen.

提交回复
热议问题