开发者

Sweep Views left-right

开发者 https://www.devze.com 2023-01-18 18:17 出处:网络
We\'ve got an application planned that is a very basic 7 page presetation. Our client wants to be able to sweep the views from right to left as a form of navigation, similar to the page control on开发

We've got an application planned that is a very basic 7 page presetation. Our client wants to be able to sweep the views from right to left as a form of navigation, similar to the page control on开发者_如何学JAVA the home screen.

I understand the presentModalViewController and pushViewController, but how do I detect a directional finger sweep?


You can use UIScrollView horizontal paging. An Apple's sample code here


See UIScrollView, and its pagingEnabled property. UIKit does almost all of the work for you.

0

精彩评论

暂无评论...
验证码 换一张
取 消