From the course: Apple watchOS App Development: Advanced APIs
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Default snapshots
From the course: Apple watchOS App Development: Advanced APIs
Default snapshots
- [Lecturer] Snapshots tell you in the dark the state of the app and keep it updated with relevant information. However not all visible interfaces are the same and you might not want it showing in the dark. You can change the visible UI to something that makes sense for a dark. Go ahead to our running app and get back to the timer. Hit reset and start it again. And now go ahead and hit About. The About has some information about the timer but doesn't have anything functional to do with it. If I hit the button now, I get for my snapshot, this line Timer and nothing else. If I scroll to it, all I get is the information about the timer not my time. Go ahead and stop the app. Within the background we can navigate to other controllers. In Snapshot task, just above the switch, add this. InterfaceController.popToRootController Now we have a push segue here so this is the correct one to use and we can use something different for a model or a page. But this one'll pop all the controllers back…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
(Locked)
Frontmost app state4m 24s
-
(Locked)
The dock and the background states5m 15s
-
(Locked)
The extension delegate7m 25s
-
(Locked)
Challenge: A background app27s
-
(Locked)
Solution: A background app2m 38s
-
Refresh app in the background6m 57s
-
(Locked)
userInfo in background apps7m 48s
-
(Locked)
Update interface with snapshot8m 16s
-
(Locked)
Default snapshots4m 54s
-
(Locked)
-
-
-
-