Day 47: Stanford CS193p – Modal Segues

Day 47: Stanford CS193p – Modal Segues

Screen Shot 2015-06-27 at 11.27.14 AM

Lecture 15
Modal View Controllers
a way of segueing that takes over the screen

alerts and action screens are done modally

default coming up and down from bottom of screen

do block UI to do just this one thing
Modal is not ideal for many situations for segueing

Went over popovers, form sheet, and others.

prepare for segue just like any segue

Hearing back from a Modally segue-to View Controller:
Unwind.

Unwind always has a dismissal

How to dismiss a view controller:
the presenting view controller needs to dismiss, not the presented.
func dismissViewConrollerAnimated(Bool, completion: () -> Void)

How is modal view animated onto screen?
.CoverVertical //the default
.FlipHorizontal
.CrossDissolve
.PartialCurl //only if presenter’s in full screen

Screen Shot 2015-06-27 at 1.36.43 PM

The demo for this lecture was an extension of the Trax app, adding some nifty modal segues to the app. There was a lot covered in the demo and would be silly to try and take detailed notes of it all. It is definitely an app project I will be playing with, maybe even adding some of the features to a larger app. Maps are awesome, so why not!?

Screen Shot 2015-06-27 at 1.37.04 PM

Advertisements

Published by: Travis Deaton

I studied International Relations at American University, volunteered for various organizations, and have recently returned from a 5 month tour of our National Parks. More on that is forthcoming. I paint on the side, you can find my work on fineartdeaton.wordpress.com.

Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s