摘要: UITabBarController的使用UITabBarController 是IOS中很常用的一个视图控件,它通常作为整个程序的根视图控制器,不能添加到别的viewController中。UITabBarController的结构示意图如下:1.手动创建TabController:通过在AppDelegate类当中的application:didFinishedLaunchingWithOptions:方法中添加代码:self.window=[[UIWindow alloc]initWithFrame:[[UIScreen mainScreen] bounds]];ViewControll 阅读全文
posted @ 2014-01-11 18:38 湖心北斗 阅读(2958) 评论(0) 推荐(0) 编辑
摘要: UIActionSheet 是IOS中从底部弹出的按钮选项,可以为每一个选择设置触发事件。为了快速完成这个例子我们在xcode中建立一个singleview 项目,在窗口中添加一个button用来弹出actionsheet1.首先在头文件中声明协议。#import @interface sheetviewViewController : UIViewController- (IBAction)showSheet:(id)sender;@end2.添加button。3.为button建立action连线。4.在m文件上添加事件代码,弹出actionsheet- (IBAction)showShe 阅读全文
posted @ 2014-01-11 10:48 湖心北斗 阅读(272) 评论(0) 推荐(0) 编辑