dimecres, 22 de gener del 2014

New features of iOS7: Dimiss the keyboard while scrolling


Now you can dismiss the keyboard while scrolling. Sure you know this nice experience from Messages.app. 

Now your app can behave like Messages.app just by changing a single property on your Storyboard, or alternatively by adding one line of code!
This property uses the new UIScrollViewKeyboardDismissMode enum. The possible values of this enum are as follows:
UIScrollViewKeyboardDismissModeNone        // the keyboard is not dismissed automatically when scrolling
UIScrollViewKeyboardDismissModeOnDrag      // dismisses the keyboard when a drag begins
UIScrollViewKeyboardDismissModeInteractive // the keyboard follows the dragging touch off screen, and may be pulled upward again to cancel the dismiss

Cap comentari:

Publica un comentari a l'entrada