Implementing Navigation with UINavigationController
Implementing Navigation with UINavigationController
Problem
You would like to allow your users to move from one view controller to the other with a smooth and built-in animation.
Solution
Use an instance of UINavigationController.
#import "AppDelegate.h" #import "FirstViewController.h" @interface AppDelegate () @property (nonatomic, strong) UINavigationController *navigationController; @end @implementation AppDelegate ...
- (BOOL) application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{
FirstViewController *viewController = [[FirstViewController alloc]
initWithNibName:nil
bundle:nil];
self.navigationController = [[UINavigationController alloc]
initWithRootViewController:viewController];
self.window = [[UIWindow alloc]
initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.rootViewController = self.navigationController;
self.window.backgroundColor = [UIColor whiteColor]; [self.window makeKeyAndVisible];
return YES;
}
如下图所示,我们得到了一个能够跳转的view.

这个是详情页面

Implementing Navigation with UINavigationController的更多相关文章
- IOS 7 Study - Implementing Navigation with UINavigationController
ProblemYou would like to allow your users to move from one view controller to the other witha smooth ...
- 1: 介绍Prism5.0 Introduction to the Prism Library 5.0 for WPF(英汉对照版)
Prism provides guidance designed to help you more easily design and build rich, flexible, and easy- ...
- 从Cell的视图推出一个新的界面
先写一个方法, 强制增加一个navigation的属性. 这样self就可以调出来navigation了 - (UINavigationController*)naviController { for ...
- Start Developing iOS Apps Today
view types - view常见类型
- UINavigationController出现nested push animation can result in corrupted navigation bar的错误提示
今天在測试过程中,出现了这样一个bug.分别有两种情景: (前提是:app是基于UINavigationController构建的) 1.从Controller-A中push进来B.在B中点击返回,返 ...
- [Angular HTML] Implementing The Input Mask Cursor Navigation Functionality -- setSelectionRange
@HostListener('keydown', ['$event', '$event.keyCode']) onKeyDown($event: KeyboardEvent, keyCode) { i ...
- iOS Programming UINavigationController
iOS Programming UINavigationController the Settings application has multiple related screens of info ...
- iOS第八课——Navigation Controller和Tab bar Controller
今天我们要学习Navigation Controller和Tab bar Controller. Navigation Controller是iOS编程中比较常用的一种容器,用来管理多个视图控制器. ...
- navigation controller
一.程序框架 1.程序结构
随机推荐
- 【leetcode】Reverse Linked List II
Reverse Linked List II Reverse a linked list from position m to n. Do it in-place and in one-pass. F ...
- POJ 1258
http://poj.org/problem?id=1258 今天晚上随便找了两道题,没想到两道都是我第一次碰到的类型———最小生成树.我以前并没有见过,也不知道怎么做,然后就看书,思路很容易理解 但 ...
- Appium+Robotframework实现Android应用的自动化测试-1:Appium在Windows中的安装
让我们开始在Windows中开始安装Appium吧,Appium在OS X中的具体安装后面的文章会介绍. 另外,官网上说先要装Node.js,还要装Apache Ant和Apache Maven,Gi ...
- poj3341
AC自动机,用40^4 * 50 * 10的空间进行dp. 最大的难点在于hash. hash一个数列f,数列中的每一位都有一个上限g,即f[i]<=g[i]. 那么可以将该数列hash为这样一 ...
- hnu11187
AC自动机+DP #include <cstdio> #include <queue> #include <cstring> using namespace std ...
- DataTemplate应用
在WPF中,决定数据外观的是DataTemplate,即DataTemplate是数据内容的表现形式,一条数据显示成什么样子,是简单的文本还是直观的图形,就是由DataTemplate决定的.下面通过 ...
- python之基本数据类型
Python运算符及基本数据类型 运算符: 1.算数运算 2. 比较运算 3. 赋值运算 4. 逻辑运算 5. 成员运算 基本数据类型: 1. 数字 int(整型) 在32位机器上,整数的位数为32位 ...
- HDU 2602 Bone Collector WA谁来帮忙找找错
Problem Description Many years ago , in Teddy’s hometown there was a man who was called “Bone Collec ...
- linux权限不够,sh不能用
linux下权限不够 chmod +x 脚本命令 ./脚本命令 即可... sh startup.sh启动tomcat,出现 This file is needed to run this prog ...
- Struts2应用流程注解
当Web容器收到请求(HttpServletReques t)它将请求传递给一个标准的的过滤链包括(ActionContextCleanUp)过滤器. 经过Other filters(SiteMe ...