This repository has been archived by the owner on Jun 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 336
HomeWork 2.2 NavigationController
ginrou edited this page Apr 17, 2013
·
2 revisions
UINavigationControllerとボタンのカスタマイズと、popToRootViewControllerについて
- UINavigationControllerを無限にpushできるようにする(講義中と同じ)
- navigationbarのボタンについては
- 右上はpushというタイトルのボタンで、タップすると同じview controllerがpushされる
- 左上には、第一階層の時はpopボタンを、第二階層以降では戻るとpopボタンを配置する
- 戻るボタンをタップすると、一つ前の階層に戻り
- popボタンをタップすると、第一階層に戻る
- 右上のボタンは
self.navigationItem setRightBarButtonItem:
でセットできます。渡す引数はUIBarButtonItem型です - 左上のボタンをセットすると戻るボタンが消えてしまいます。その時は
self.navigationItem.leftItemsSupplementBackButton = YES
としてください。 - 第一階層に戻るにはUINavigationControllerの
popToRootViewControllerAnimated:
を呼べば戻れます
はじめに
-
導入
-
1.3 UIViewController1 UIViewController のカスタマイズ(xib, autoresizing)
-
UIKit 1 - container, rotate-
-
UIKit 2- UIView -
-
UIKit 3 - table view -
-
UIKit 4 - image and text -
-
ネットワーク処理
-
ローカルキャッシュと通知
-
Blocks, GCD
-
設計とデザインパターン
-
開発ツール
-
テスト
-
In-App Purchase
-
付録