What is the callback function when app unlock from lock screen to my app screen in iOS?

StackOverflow https://stackoverflow.com/questions/23624791

  •  21-07-2023
  •  | 
  •  

Вопрос

I thought it was viewWillAppear function, but it did not.

Is not exist unlock callback function in iOS?

Это было полезно?

Решение

The methods called when locking the device with your app currently in foreground are in order

-[MyAppDelegate applicationWillResignActive:]
-[MyAppDelegate applicationDidEnterBackground:]
-[MyAppDelegate applicationWillEnterForeground:]
-[MyAppDelegate applicationDidBecomeActive:]

The first two are called when locking, the others when unlocking

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top