Interface Transitions in Code

Not every transition can be implemented in your storyboard. Whether you need to gut your app’s interface entirely and start fresh or dynamically choose interface controllers to present, you may need to use some of WKInterfaceController’s methods to accomplish your tasks. Because of this, you may see interface controllers in your storyboard that don’t appear to be connected to anything. Fear not: you can always instantiate one by name, using the identifier that you give it in the storyboard. For that reason, Xcode will warn you if you have an interface controller in your storyboard with no linked segues or an identifier—there’s no way to get to it! Let’s look at two ways to transition in code. First, let’s transition ...

Get Developing for Apple Watch, 2nd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.