iPhone - phone goes to sleep even if idleTimerDisabled is YES

前端 未结 9 1379
难免孤独
难免孤独 2020-11-30 03:45

I am using this in my appdelegate\'s applicationDidFinishLaunching: method to make sure the iPhone doesn\'t go to sleep during the time the app is open

[appl         


        
9条回答
  •  天命终不由人
    2020-11-30 04:01

    If your application is using camera then app will go to sleep after using camera . So you need to add UIRequiredDeviceCapabilities in your app plist . Different devices you can add as shown here

提交回复
热议问题