Can we lock the app while app goes to sleep mode in IPhone?

后端 未结 4 1863
孤独总比滥情好
孤独总比滥情好 2021-02-11 10:52

I am working an app where lock option is included.My app starts with passcode screen.If I enter correct code then it navigates to next screen.If I dont use the app for long time

4条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-11 11:45

    Yes ofcourse it is possible. You must open the screen in a method called applicationDidBecomeActive in your Application Delegate. This method is called every time the application is opened from background.

    So whenever the user starts the already running app, this method will be called and from this you can first show the Password screen, and after that the respective screen.

提交回复
热议问题