`
zl4393753
  • 浏览: 333383 次
  • 性别: Icon_minigender_1
  • 来自: 武汉
社区版块
存档分类
最新评论

iphone下toolbar的使用

iOS 
阅读更多
IOS 3.0以后,navigation controller自带toolbar, 原文如下:“In iOS 3.0 and later, a navigation interface can display a toolbar and populate it with items provided by the currently visible view controller. The toolbar itself is managed by the navigation controller object.”
显示toolbar以及toolbar基本的设置代码如下:
[self.navigationController setToolbarHidden:NO animated:NO];
self.navigationController.toolbar.barStyle = UIBarStyleBlack;
	
UIBarButtonItem *item = [[UIBarButtonItem alloc] initWithBarButtonSystemItem: UIBarButtonSystemItemCompose target:self action:@selector(settingButtonClicked)];
NSArray *myToolbarItems = [[NSArray alloc] initWithObjects: item, nil];                 
[self setToolbarItems: myToolbarItems animated:YES];

toolbar的隐藏:
NewOrderViewController *newOrder = [[NewOrderViewController alloc] initWithNibName:@"NewOrderView" bundle:[NSBundle mainBundle]];
newOrder.hidesBottomBarWhenPushed = YES;
[self.navigationController pushViewController:newOrder animated:YES];

具体解释的原文为:
“To hide the toolbar for a specific view controller, set the hidesBottomBarWhenPushed property of that view controller to YES. When the navigation controller encounters a view controller with this property set to YES, it generates an appropriate transition animation whenever the view controller is pushed onto (or removed from) the navigation stack.”


分享到:
评论

相关推荐

    iPhone toolbar拖拽效果 代码实例

    iPhone 开发 toolbar 拖拽 代码实例,toolbar使用范例,图标拖拽

    iphone toolbar导航图标集合

    120个iphone的toolbar icon,可以用于开发的导航条的一下背景等等

    iphone_toolbar_icons所有iphone_icon打包

    所有iphone_icon打包,非常难的的资源,不可多得,你还犹豫什么呢????

    iOS iphone工具栏创建简单的多视图

    iphone开发入门经典中的例子 在一个view toolbar中切换几个view,入门必备

    关于Iphone多线程和UDP协议

    UITableView,ToolBar,Navigation 页面设计。。。

    Informatic Toolbar(iPhone源代码)

    来源:Licence:CC BY-SA 3.0平台:iOS设备:iPhone作者:Greg Wang  实现弹出工具条(tool bar),并且在工具条上加上其他控件。实现类似iPhone自带邮件app发送邮件时,屏幕底部弹出的tool bar,显示邮件发送状态...

    Progress Toolbar(iPhone源代码)

    来源:Licence:MIT平台:iOS设备:iPhone / iPad作者:Adar Porat  在当前界面底部弹出加载有进度条(UIProgressView)的视图,弹出的进度条不会阻碍当前的进程,可用于显示下载文件的进度。 [优才 · Code4...

    NXDrawKit, NXDrawKit是一款简单而简单但实用的iPhone绘图工具.zip

    NXDrawKit, NXDrawKit是一款简单而简单但实用的iPhone绘图工具 它刚开始为我的个人iPhone应用。 但是,它不能像你所需的那样定制,你可以使用... 我为使用 Canvas 制作了 Palette 和 ToolBar,因此你不需要使用 Palet

    NXDrawKit:NXDrawKit是一个用于iPhone的简单易用但有用的绘图工具包

    :warning: 要与Swift 3.x一起使用,请确保您使用的>> 0.5.0 :warning: :warning: 要与Swift 2.3一起使用,请确保您使用的== 0.4.1 :warning:目的我的iPhone个人应用程序才刚刚开始。 尽管无法根据需要进行自定义,...

    iphone自定义工具栏

    自定义工具栏,可以做很多特效,!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    IQKeyBoardManager(iPhone源代码)

    来源:github/IQKeyboardManageLicence:MIT平台:iOS设备:iPhone / iPad作者:Diego Ramirez  只需一句代码就能轻松解决键盘遮挡住输入框的问题。当界面上有多个文字输入框时,弹出的键盘往往会遮挡住需要输入...

    iPad Human Interface Guideline

    Chapter 2 From iPhone Application to iPad Application 11 Design Strategies for Translating Your iPhone Application 11 Case Study: From Mail on iPhone to Mail on iPad 12 Chapter 3 iPad User Experience ...

    AFPickerView(iPhone源代码)

    来源:Licence:Unspecified平台:iOS设备:iPhone / iPad作者:Fraerman Arkady  自定义picker的颜色、toolbar等等。 Code4App编译测试,适用环境:Xcode 4.3, iOS 5.0。

    NJKScrollFullScreen(iPhone源代码)

    来源:github/NJKScrollFullScrLicence:MIT... 滚动视图,可以隐藏界面顶部的导航条(NavigationBar)以及底部的工具条(ToolBar),使得滚动的内容能够全屏显示。可以使用在ScrollView,TableView以及WebView中。

    UIToolBar快速切换图标

    UIToolBar快速切换图标,UIToolBar快速切换图标

    MHTextField(iPhone源代码)

     实现功能比较齐全的 UITextField 输入表单,具体功能包括:输入有效性判断(Validation)、键盘工具条(Toolbar)、表单滑动避免被弹出的键盘挡住(Keyboard Avoiding)等等。基本可以直接拿来作为应用中表单输入...

    iOS 人机交互指南(iOS Human Interface Guidelines)

    Ensure that Universal Apps Run Well on Both iPhone and iPad 28 Reconsider Web-Based Designs 28 Tailor Customization to the Task 29 Prototype and Iterate 31 Chapter 4 Case Studies: Transitioning to iOS...

    ionic-ios-header:一个模拟iOS 11标头的简单离子模块

    Ionic iOS标题 模拟ios 11标头的简单离子模块。 仍在开发中 :smiling_face_... 只需在页面中使用header-content组件,而不是ion-header和ion-content即可! < header-content search =" true " [(query)] =" que

    Jumble Email Encryption-crx插件

    并使用jumble帐户登录 - 如果您没有帐户,则可以在https://www.jumble.io/users/register免费注册3)打开Gmail4)按正常撰写新电子邮件5)通过单击Compose Toolbar中的Blue Jambumble“安全附件”图标,添加安全附件...

    Android 刘海屏适配总结(推荐)

    随着 Apple 发布 iPhone X 之后,各大手机厂商也开始模仿这种刘海屏的设计,而且刘海屏手机的用户也是越来越大,前段时间将项目进行了所有主流厂商的刘海屏手机的适配,以便让刘海屏手机的用户也能有更好的体验。...

Global site tag (gtag.js) - Google Analytics