├── .gitignore ├── .travis.yml ├── ABCustomUINavigationController.podspec ├── ABCustomUINavigationController.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── andresbrun.xcuserdatad │ │ └── WorkspaceSettings.xcsettings └── xcuserdata │ └── andresbrun.xcuserdatad │ ├── xcdebugger │ └── Breakpoints.xcbkptlist │ └── xcschemes │ ├── SquaresFlipNavigationExample.xcscheme │ └── xcschememanagement.plist ├── ABCustomUINavigationControllerExample ├── ABCustomUINavigationController-Info.plist ├── ABCustomUINavigationController-Prefix.pch ├── AppDelegate.h ├── AppDelegate.m ├── Default-568h@2x.png ├── Default.png ├── Default@2x.png ├── ViewControllers │ ├── SecondViewController.h │ ├── SecondViewController.m │ ├── ThirthViewController.h │ ├── ThirthViewController.m │ ├── ViewController.h │ ├── ViewController.m │ └── Views │ │ ├── SecondViewController_iPad.xib │ │ ├── SecondViewController_iPhone.xib │ │ ├── ThirthViewController_iPad.xib │ │ ├── ThirthViewController_iPhone.xib │ │ ├── ViewController_iPad.xib │ │ └── ViewController_iPhone.xib ├── assets │ ├── bg_1.jpg │ ├── bg_1_iPad.jpg │ ├── bg_2.jpg │ ├── bg_2_iPad.jpg │ ├── bg_3.png │ └── bg_3_iPad.jpg ├── en.lproj │ └── InfoPlist.strings └── main.m ├── CustomUINavigationController ├── Categories │ ├── NSNumber+ABGenerator.h │ ├── NSNumber+ABGenerator.m │ ├── NSObject+ABExtras.h │ ├── NSObject+ABExtras.m │ ├── UIImage+ABExtras.h │ ├── UIImage+ABExtras.m │ ├── UIView+ABExtras.h │ └── UIView+ABExtras.m ├── Classes │ ├── NSArrayMatrix.h │ └── NSArrayMatrix.m └── NavigationClasses │ ├── BaseControllerAnimatedTransitioningDelegate.h │ ├── BaseControllerAnimatedTransitioningDelegate.m │ ├── BaseNavigationController.h │ ├── BaseNavigationController.m │ ├── BaseNavigationControllerDelegate.h │ ├── BaseNavigationControllerDelegate.m │ ├── CubeNavigation │ ├── CubeAnimator.h │ ├── CubeAnimator.m │ ├── CubeNavigationController.h │ └── CubeNavigationController.m │ └── GridBaseNavigation │ ├── GridBaseAnimator.h │ ├── GridBaseAnimator.m │ ├── PixelateNavigation │ ├── PixelateGridAnimator.h │ ├── PixelateGridAnimator.m │ ├── PixelateNavigationController.h │ └── PixelateNavigationController.m │ └── SquaresFlipNavigation │ ├── FlipSquaresGridAnimator.h │ ├── FlipSquaresGridAnimator.m │ ├── FlipSquaresNavigationController.h │ └── FlipSquaresNavigationController.m ├── LICENSE.txt ├── README.md └── example_images ├── example.gif ├── example.mov ├── example_1.png ├── example_2.png ├── example_3.png ├── example_4.png ├── example_5.png ├── example_6.png ├── example_cube.gif ├── example_cube_1.png ├── example_cube_2.png └── example_full.png /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | .DS_Store 3 | */build/* 4 | *.pbxuser 5 | !default.pbxuser 6 | *.mode1v3 7 | !default.mode1v3 8 | *.mode2v3 9 | !default.mode2v3 10 | *.perspectivev3 11 | !default.perspectivev3 12 | xcuserdata 13 | profile 14 | *.moved-aside 15 | DerivedData 16 | .idea/ 17 | *.hmap 18 | *.xccheckout 19 | 20 | #CocoaPods 21 | Pods 22 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: objective-c -------------------------------------------------------------------------------- /ABCustomUINavigationController.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | 3 | s.name = "ABCustomUINavigationController" 4 | s.version = "1.2.2" 5 | s.summary = "Custom UINavigationController. SquaresFlips and Cube effects" 6 | 7 | s.description = <<-DESC 8 | Subclass of UINavigationController that overwrite push and pop methods to create new transitions effects. Currently it has been implemented two transition animations: 9 | 10 | SquaresFlip 11 | The screen is split in squares and each one rotates until showing the new controller. It has two animation variation: Randomly and Horizontally 12 | 13 | Cube effect 14 | The views are shown in differents sides of a cube. It has two animation variation: Horizontal and Vertical 15 | 16 | Pixelate 17 | The screen is split in pixels and randomly change to show the nex screen. It has two animation variation: Horizontal and Vertical 18 | DESC 19 | 20 | s.homepage = "https://github.com/andresbrun/ABCustomUINavigationController" 21 | 22 | s.license = { :type => 'MIT', :file => 'LICENSE.txt' } 23 | s.author = { "Andres Brun" => "andresbrunmoreno@gmail.com" } 24 | 25 | s.platform = :ios, '7.0' 26 | s.source = { :git => "https://github.com/andresbrun/ABCustomUINavigationController.git", :tag => s.version } 27 | 28 | s.source_files = 'CustomUINavigationController/**/*.{h,m}' 29 | 30 | s.frameworks = 'QuartzCore', 'CoreGraphics' 31 | s.requires_arc = true 32 | 33 | end -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 3CCCEAE117B4E0A800750A12 /* NSObject+ABExtras.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAD417B4E0A800750A12 /* NSObject+ABExtras.m */; }; 11 | 3CCCEAE417B4E0A800750A12 /* UIView+ABExtras.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEADA17B4E0A800750A12 /* UIView+ABExtras.m */; }; 12 | 3CCCEB0817B4E0F800750A12 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAEB17B4E0F800750A12 /* AppDelegate.m */; }; 13 | 3CCCEB0917B4E0F800750A12 /* bg_1.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAED17B4E0F800750A12 /* bg_1.jpg */; }; 14 | 3CCCEB0A17B4E0F800750A12 /* bg_1_iPad.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAEE17B4E0F800750A12 /* bg_1_iPad.jpg */; }; 15 | 3CCCEB0B17B4E0F800750A12 /* bg_2.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAEF17B4E0F800750A12 /* bg_2.jpg */; }; 16 | 3CCCEB0C17B4E0F800750A12 /* bg_2_iPad.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF017B4E0F800750A12 /* bg_2_iPad.jpg */; }; 17 | 3CCCEB0D17B4E0F800750A12 /* bg_3.png in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF117B4E0F800750A12 /* bg_3.png */; }; 18 | 3CCCEB0E17B4E0F800750A12 /* bg_3_iPad.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF217B4E0F800750A12 /* bg_3_iPad.jpg */; }; 19 | 3CCCEB0F17B4E0F800750A12 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF317B4E0F800750A12 /* Default-568h@2x.png */; }; 20 | 3CCCEB1017B4E0F800750A12 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF417B4E0F800750A12 /* Default.png */; }; 21 | 3CCCEB1117B4E0F800750A12 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF517B4E0F800750A12 /* Default@2x.png */; }; 22 | 3CCCEB1217B4E0F800750A12 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF617B4E0F800750A12 /* InfoPlist.strings */; }; 23 | 3CCCEB1317B4E0F800750A12 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAF817B4E0F800750A12 /* main.m */; }; 24 | 3CCCEB1417B4E0F800750A12 /* SecondViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAFB17B4E0F800750A12 /* SecondViewController.m */; }; 25 | 3CCCEB1517B4E0F800750A12 /* ThirthViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAFD17B4E0F800750A12 /* ThirthViewController.m */; }; 26 | 3CCCEB1617B4E0F800750A12 /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3CCCEAFF17B4E0F800750A12 /* ViewController.m */; }; 27 | 3CCCEB1717B4E0F800750A12 /* SecondViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0117B4E0F800750A12 /* SecondViewController_iPad.xib */; }; 28 | 3CCCEB1817B4E0F800750A12 /* SecondViewController_iPhone.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0217B4E0F800750A12 /* SecondViewController_iPhone.xib */; }; 29 | 3CCCEB1917B4E0F800750A12 /* ThirthViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0317B4E0F800750A12 /* ThirthViewController_iPad.xib */; }; 30 | 3CCCEB1A17B4E0F800750A12 /* ThirthViewController_iPhone.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0417B4E0F800750A12 /* ThirthViewController_iPhone.xib */; }; 31 | 3CCCEB1B17B4E0F800750A12 /* ViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0517B4E0F800750A12 /* ViewController_iPad.xib */; }; 32 | 3CCCEB1C17B4E0F800750A12 /* ViewController_iPhone.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3CCCEB0617B4E0F800750A12 /* ViewController_iPhone.xib */; }; 33 | 3CF16BB617930123006E912F /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3CF16BB517930123006E912F /* UIKit.framework */; }; 34 | 3CF16BB817930123006E912F /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3CF16BB717930123006E912F /* Foundation.framework */; }; 35 | 3CF16BBA17930123006E912F /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3CF16BB917930123006E912F /* CoreGraphics.framework */; }; 36 | 3CF16BDC179309B1006E912F /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3CF16BDB179309B1006E912F /* QuartzCore.framework */; }; 37 | DD3C776C1AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77591AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.m */; }; 38 | DD3C776D1AA257A500D425B1 /* BaseNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C775B1AA257A500D425B1 /* BaseNavigationController.m */; }; 39 | DD3C776E1AA257A500D425B1 /* BaseNavigationControllerDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C775D1AA257A500D425B1 /* BaseNavigationControllerDelegate.m */; }; 40 | DD3C776F1AA257A500D425B1 /* CubeAnimator.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77601AA257A500D425B1 /* CubeAnimator.m */; }; 41 | DD3C77701AA257A500D425B1 /* CubeNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77621AA257A500D425B1 /* CubeNavigationController.m */; }; 42 | DD3C77721AA257A500D425B1 /* PixelateNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77681AA257A500D425B1 /* PixelateNavigationController.m */; }; 43 | DD3C77731AA257A500D425B1 /* FlipSquaresNavigationController.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C776B1AA257A500D425B1 /* FlipSquaresNavigationController.m */; }; 44 | DD3C77791AA259F000D425B1 /* GridBaseAnimator.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77781AA259F000D425B1 /* GridBaseAnimator.m */; }; 45 | DD3C777C1AA25A8200D425B1 /* PixelateGridAnimator.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C777B1AA25A8200D425B1 /* PixelateGridAnimator.m */; }; 46 | DD3C77831AA25CD200D425B1 /* NSArrayMatrix.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77821AA25CD200D425B1 /* NSArrayMatrix.m */; }; 47 | DD3C77931AA3192400D425B1 /* FlipSquaresGridAnimator.m in Sources */ = {isa = PBXBuildFile; fileRef = DD3C77921AA3192400D425B1 /* FlipSquaresGridAnimator.m */; }; 48 | DD909A2C1AA3671600A79883 /* NSNumber+ABGenerator.m in Sources */ = {isa = PBXBuildFile; fileRef = DD909A2B1AA3671600A79883 /* NSNumber+ABGenerator.m */; }; 49 | DDEB0C8B1DB029A8001C170E /* UIImage+ABExtras.m in Sources */ = {isa = PBXBuildFile; fileRef = DDEB0C891DB02101001C170E /* UIImage+ABExtras.m */; }; 50 | /* End PBXBuildFile section */ 51 | 52 | /* Begin PBXFileReference section */ 53 | 3CCCEAD317B4E0A800750A12 /* NSObject+ABExtras.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+ABExtras.h"; sourceTree = ""; }; 54 | 3CCCEAD417B4E0A800750A12 /* NSObject+ABExtras.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+ABExtras.m"; sourceTree = ""; }; 55 | 3CCCEAD917B4E0A800750A12 /* UIView+ABExtras.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+ABExtras.h"; sourceTree = ""; }; 56 | 3CCCEADA17B4E0A800750A12 /* UIView+ABExtras.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIView+ABExtras.m"; sourceTree = ""; }; 57 | 3CCCEAE917B4E0F800750A12 /* ABCustomUINavigationController-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "ABCustomUINavigationController-Prefix.pch"; sourceTree = ""; }; 58 | 3CCCEAEA17B4E0F800750A12 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 59 | 3CCCEAEB17B4E0F800750A12 /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 60 | 3CCCEAED17B4E0F800750A12 /* bg_1.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = bg_1.jpg; sourceTree = ""; }; 61 | 3CCCEAEE17B4E0F800750A12 /* bg_1_iPad.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = bg_1_iPad.jpg; sourceTree = ""; }; 62 | 3CCCEAEF17B4E0F800750A12 /* bg_2.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = bg_2.jpg; sourceTree = ""; }; 63 | 3CCCEAF017B4E0F800750A12 /* bg_2_iPad.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = bg_2_iPad.jpg; sourceTree = ""; }; 64 | 3CCCEAF117B4E0F800750A12 /* bg_3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = bg_3.png; sourceTree = ""; }; 65 | 3CCCEAF217B4E0F800750A12 /* bg_3_iPad.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = bg_3_iPad.jpg; sourceTree = ""; }; 66 | 3CCCEAF317B4E0F800750A12 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; 67 | 3CCCEAF417B4E0F800750A12 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = ""; }; 68 | 3CCCEAF517B4E0F800750A12 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = ""; }; 69 | 3CCCEAF717B4E0F800750A12 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 70 | 3CCCEAF817B4E0F800750A12 /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 71 | 3CCCEAFA17B4E0F800750A12 /* SecondViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SecondViewController.h; sourceTree = ""; }; 72 | 3CCCEAFB17B4E0F800750A12 /* SecondViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SecondViewController.m; sourceTree = ""; }; 73 | 3CCCEAFC17B4E0F800750A12 /* ThirthViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ThirthViewController.h; sourceTree = ""; }; 74 | 3CCCEAFD17B4E0F800750A12 /* ThirthViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ThirthViewController.m; sourceTree = ""; }; 75 | 3CCCEAFE17B4E0F800750A12 /* ViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; 76 | 3CCCEAFF17B4E0F800750A12 /* ViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; 77 | 3CCCEB0117B4E0F800750A12 /* SecondViewController_iPad.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SecondViewController_iPad.xib; sourceTree = ""; }; 78 | 3CCCEB0217B4E0F800750A12 /* SecondViewController_iPhone.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SecondViewController_iPhone.xib; sourceTree = ""; }; 79 | 3CCCEB0317B4E0F800750A12 /* ThirthViewController_iPad.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ThirthViewController_iPad.xib; sourceTree = ""; }; 80 | 3CCCEB0417B4E0F800750A12 /* ThirthViewController_iPhone.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ThirthViewController_iPhone.xib; sourceTree = ""; }; 81 | 3CCCEB0517B4E0F800750A12 /* ViewController_iPad.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ViewController_iPad.xib; sourceTree = ""; }; 82 | 3CCCEB0617B4E0F800750A12 /* ViewController_iPhone.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ViewController_iPhone.xib; sourceTree = ""; }; 83 | 3CCCEB1F17B4E29700750A12 /* ABCustomUINavigationController-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "ABCustomUINavigationController-Info.plist"; sourceTree = ""; }; 84 | 3CF16BB217930123006E912F /* ABCustomUINavigationController.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ABCustomUINavigationController.app; sourceTree = BUILT_PRODUCTS_DIR; }; 85 | 3CF16BB517930123006E912F /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 86 | 3CF16BB717930123006E912F /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 87 | 3CF16BB917930123006E912F /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 88 | 3CF16BDB179309B1006E912F /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 89 | DD3C77581AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseControllerAnimatedTransitioningDelegate.h; sourceTree = ""; }; 90 | DD3C77591AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BaseControllerAnimatedTransitioningDelegate.m; sourceTree = ""; }; 91 | DD3C775A1AA257A500D425B1 /* BaseNavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseNavigationController.h; sourceTree = ""; }; 92 | DD3C775B1AA257A500D425B1 /* BaseNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BaseNavigationController.m; sourceTree = ""; }; 93 | DD3C775C1AA257A500D425B1 /* BaseNavigationControllerDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BaseNavigationControllerDelegate.h; sourceTree = ""; }; 94 | DD3C775D1AA257A500D425B1 /* BaseNavigationControllerDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BaseNavigationControllerDelegate.m; sourceTree = ""; }; 95 | DD3C775F1AA257A500D425B1 /* CubeAnimator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CubeAnimator.h; sourceTree = ""; }; 96 | DD3C77601AA257A500D425B1 /* CubeAnimator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CubeAnimator.m; sourceTree = ""; }; 97 | DD3C77611AA257A500D425B1 /* CubeNavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CubeNavigationController.h; sourceTree = ""; }; 98 | DD3C77621AA257A500D425B1 /* CubeNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CubeNavigationController.m; sourceTree = ""; }; 99 | DD3C77671AA257A500D425B1 /* PixelateNavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PixelateNavigationController.h; sourceTree = ""; }; 100 | DD3C77681AA257A500D425B1 /* PixelateNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PixelateNavigationController.m; sourceTree = ""; }; 101 | DD3C776A1AA257A500D425B1 /* FlipSquaresNavigationController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FlipSquaresNavigationController.h; sourceTree = ""; }; 102 | DD3C776B1AA257A500D425B1 /* FlipSquaresNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FlipSquaresNavigationController.m; sourceTree = ""; }; 103 | DD3C77771AA259F000D425B1 /* GridBaseAnimator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GridBaseAnimator.h; sourceTree = ""; }; 104 | DD3C77781AA259F000D425B1 /* GridBaseAnimator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GridBaseAnimator.m; sourceTree = ""; }; 105 | DD3C777A1AA25A8200D425B1 /* PixelateGridAnimator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PixelateGridAnimator.h; sourceTree = ""; }; 106 | DD3C777B1AA25A8200D425B1 /* PixelateGridAnimator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PixelateGridAnimator.m; sourceTree = ""; }; 107 | DD3C77811AA25CD200D425B1 /* NSArrayMatrix.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSArrayMatrix.h; sourceTree = ""; }; 108 | DD3C77821AA25CD200D425B1 /* NSArrayMatrix.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSArrayMatrix.m; sourceTree = ""; }; 109 | DD3C77911AA3192400D425B1 /* FlipSquaresGridAnimator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FlipSquaresGridAnimator.h; sourceTree = ""; }; 110 | DD3C77921AA3192400D425B1 /* FlipSquaresGridAnimator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FlipSquaresGridAnimator.m; sourceTree = ""; }; 111 | DD909A2A1AA3671600A79883 /* NSNumber+ABGenerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSNumber+ABGenerator.h"; sourceTree = ""; }; 112 | DD909A2B1AA3671600A79883 /* NSNumber+ABGenerator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSNumber+ABGenerator.m"; sourceTree = ""; }; 113 | DDEB0C881DB02101001C170E /* UIImage+ABExtras.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImage+ABExtras.h"; sourceTree = ""; }; 114 | DDEB0C891DB02101001C170E /* UIImage+ABExtras.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIImage+ABExtras.m"; sourceTree = ""; }; 115 | /* End PBXFileReference section */ 116 | 117 | /* Begin PBXFrameworksBuildPhase section */ 118 | 3CF16BAF17930123006E912F /* Frameworks */ = { 119 | isa = PBXFrameworksBuildPhase; 120 | buildActionMask = 2147483647; 121 | files = ( 122 | 3CF16BDC179309B1006E912F /* QuartzCore.framework in Frameworks */, 123 | 3CF16BB617930123006E912F /* UIKit.framework in Frameworks */, 124 | 3CF16BB817930123006E912F /* Foundation.framework in Frameworks */, 125 | 3CF16BBA17930123006E912F /* CoreGraphics.framework in Frameworks */, 126 | ); 127 | runOnlyForDeploymentPostprocessing = 0; 128 | }; 129 | /* End PBXFrameworksBuildPhase section */ 130 | 131 | /* Begin PBXGroup section */ 132 | 3CCCEAD117B4E0A800750A12 /* CustomUINavigationController */ = { 133 | isa = PBXGroup; 134 | children = ( 135 | DD3C77801AA25CA300D425B1 /* Classes */, 136 | DD3C77571AA257A500D425B1 /* NavigationClasses */, 137 | 3CCCEAD217B4E0A800750A12 /* Categories */, 138 | ); 139 | path = CustomUINavigationController; 140 | sourceTree = ""; 141 | }; 142 | 3CCCEAD217B4E0A800750A12 /* Categories */ = { 143 | isa = PBXGroup; 144 | children = ( 145 | DD909A2A1AA3671600A79883 /* NSNumber+ABGenerator.h */, 146 | DD909A2B1AA3671600A79883 /* NSNumber+ABGenerator.m */, 147 | 3CCCEAD317B4E0A800750A12 /* NSObject+ABExtras.h */, 148 | 3CCCEAD417B4E0A800750A12 /* NSObject+ABExtras.m */, 149 | 3CCCEAD917B4E0A800750A12 /* UIView+ABExtras.h */, 150 | 3CCCEADA17B4E0A800750A12 /* UIView+ABExtras.m */, 151 | DDEB0C881DB02101001C170E /* UIImage+ABExtras.h */, 152 | DDEB0C891DB02101001C170E /* UIImage+ABExtras.m */, 153 | ); 154 | path = Categories; 155 | sourceTree = ""; 156 | }; 157 | 3CCCEAE717B4E0F800750A12 /* ABCustomUINavigationControllerExample */ = { 158 | isa = PBXGroup; 159 | children = ( 160 | 3CCCEB1F17B4E29700750A12 /* ABCustomUINavigationController-Info.plist */, 161 | 3CCCEAE917B4E0F800750A12 /* ABCustomUINavigationController-Prefix.pch */, 162 | 3CCCEAEA17B4E0F800750A12 /* AppDelegate.h */, 163 | 3CCCEAEB17B4E0F800750A12 /* AppDelegate.m */, 164 | 3CCCEAEC17B4E0F800750A12 /* assets */, 165 | 3CCCEAF317B4E0F800750A12 /* Default-568h@2x.png */, 166 | 3CCCEAF417B4E0F800750A12 /* Default.png */, 167 | 3CCCEAF517B4E0F800750A12 /* Default@2x.png */, 168 | 3CCCEAF617B4E0F800750A12 /* InfoPlist.strings */, 169 | 3CCCEAF817B4E0F800750A12 /* main.m */, 170 | 3CCCEAF917B4E0F800750A12 /* ViewControllers */, 171 | ); 172 | path = ABCustomUINavigationControllerExample; 173 | sourceTree = ""; 174 | }; 175 | 3CCCEAEC17B4E0F800750A12 /* assets */ = { 176 | isa = PBXGroup; 177 | children = ( 178 | 3CCCEAED17B4E0F800750A12 /* bg_1.jpg */, 179 | 3CCCEAEE17B4E0F800750A12 /* bg_1_iPad.jpg */, 180 | 3CCCEAEF17B4E0F800750A12 /* bg_2.jpg */, 181 | 3CCCEAF017B4E0F800750A12 /* bg_2_iPad.jpg */, 182 | 3CCCEAF117B4E0F800750A12 /* bg_3.png */, 183 | 3CCCEAF217B4E0F800750A12 /* bg_3_iPad.jpg */, 184 | ); 185 | path = assets; 186 | sourceTree = ""; 187 | }; 188 | 3CCCEAF917B4E0F800750A12 /* ViewControllers */ = { 189 | isa = PBXGroup; 190 | children = ( 191 | 3CCCEAFA17B4E0F800750A12 /* SecondViewController.h */, 192 | 3CCCEAFB17B4E0F800750A12 /* SecondViewController.m */, 193 | 3CCCEAFC17B4E0F800750A12 /* ThirthViewController.h */, 194 | 3CCCEAFD17B4E0F800750A12 /* ThirthViewController.m */, 195 | 3CCCEAFE17B4E0F800750A12 /* ViewController.h */, 196 | 3CCCEAFF17B4E0F800750A12 /* ViewController.m */, 197 | 3CCCEB0017B4E0F800750A12 /* Views */, 198 | ); 199 | path = ViewControllers; 200 | sourceTree = ""; 201 | }; 202 | 3CCCEB0017B4E0F800750A12 /* Views */ = { 203 | isa = PBXGroup; 204 | children = ( 205 | 3CCCEB0117B4E0F800750A12 /* SecondViewController_iPad.xib */, 206 | 3CCCEB0217B4E0F800750A12 /* SecondViewController_iPhone.xib */, 207 | 3CCCEB0317B4E0F800750A12 /* ThirthViewController_iPad.xib */, 208 | 3CCCEB0417B4E0F800750A12 /* ThirthViewController_iPhone.xib */, 209 | 3CCCEB0517B4E0F800750A12 /* ViewController_iPad.xib */, 210 | 3CCCEB0617B4E0F800750A12 /* ViewController_iPhone.xib */, 211 | ); 212 | path = Views; 213 | sourceTree = ""; 214 | }; 215 | 3CF16BA917930123006E912F = { 216 | isa = PBXGroup; 217 | children = ( 218 | 3CCCEAD117B4E0A800750A12 /* CustomUINavigationController */, 219 | 3CCCEAE717B4E0F800750A12 /* ABCustomUINavigationControllerExample */, 220 | 3CF16BB417930123006E912F /* Frameworks */, 221 | 3CF16BB317930123006E912F /* Products */, 222 | ); 223 | sourceTree = ""; 224 | }; 225 | 3CF16BB317930123006E912F /* Products */ = { 226 | isa = PBXGroup; 227 | children = ( 228 | 3CF16BB217930123006E912F /* ABCustomUINavigationController.app */, 229 | ); 230 | name = Products; 231 | sourceTree = ""; 232 | }; 233 | 3CF16BB417930123006E912F /* Frameworks */ = { 234 | isa = PBXGroup; 235 | children = ( 236 | 3CF16BDB179309B1006E912F /* QuartzCore.framework */, 237 | 3CF16BB517930123006E912F /* UIKit.framework */, 238 | 3CF16BB717930123006E912F /* Foundation.framework */, 239 | 3CF16BB917930123006E912F /* CoreGraphics.framework */, 240 | ); 241 | name = Frameworks; 242 | sourceTree = ""; 243 | }; 244 | DD3C77571AA257A500D425B1 /* NavigationClasses */ = { 245 | isa = PBXGroup; 246 | children = ( 247 | DD3C775A1AA257A500D425B1 /* BaseNavigationController.h */, 248 | DD3C775B1AA257A500D425B1 /* BaseNavigationController.m */, 249 | DD3C775C1AA257A500D425B1 /* BaseNavigationControllerDelegate.h */, 250 | DD3C775D1AA257A500D425B1 /* BaseNavigationControllerDelegate.m */, 251 | DD3C77581AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.h */, 252 | DD3C77591AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.m */, 253 | DD3C775E1AA257A500D425B1 /* CubeNavigation */, 254 | DD3C77631AA257A500D425B1 /* GridBaseNavigation */, 255 | ); 256 | path = NavigationClasses; 257 | sourceTree = ""; 258 | }; 259 | DD3C775E1AA257A500D425B1 /* CubeNavigation */ = { 260 | isa = PBXGroup; 261 | children = ( 262 | DD3C775F1AA257A500D425B1 /* CubeAnimator.h */, 263 | DD3C77601AA257A500D425B1 /* CubeAnimator.m */, 264 | DD3C77611AA257A500D425B1 /* CubeNavigationController.h */, 265 | DD3C77621AA257A500D425B1 /* CubeNavigationController.m */, 266 | ); 267 | path = CubeNavigation; 268 | sourceTree = ""; 269 | }; 270 | DD3C77631AA257A500D425B1 /* GridBaseNavigation */ = { 271 | isa = PBXGroup; 272 | children = ( 273 | DD3C77771AA259F000D425B1 /* GridBaseAnimator.h */, 274 | DD3C77781AA259F000D425B1 /* GridBaseAnimator.m */, 275 | DD3C77661AA257A500D425B1 /* PixelateNavigation */, 276 | DD3C77691AA257A500D425B1 /* SquaresFlipNavigation */, 277 | ); 278 | path = GridBaseNavigation; 279 | sourceTree = ""; 280 | }; 281 | DD3C77661AA257A500D425B1 /* PixelateNavigation */ = { 282 | isa = PBXGroup; 283 | children = ( 284 | DD3C77671AA257A500D425B1 /* PixelateNavigationController.h */, 285 | DD3C77681AA257A500D425B1 /* PixelateNavigationController.m */, 286 | DD3C777A1AA25A8200D425B1 /* PixelateGridAnimator.h */, 287 | DD3C777B1AA25A8200D425B1 /* PixelateGridAnimator.m */, 288 | ); 289 | path = PixelateNavigation; 290 | sourceTree = ""; 291 | }; 292 | DD3C77691AA257A500D425B1 /* SquaresFlipNavigation */ = { 293 | isa = PBXGroup; 294 | children = ( 295 | DD3C776A1AA257A500D425B1 /* FlipSquaresNavigationController.h */, 296 | DD3C776B1AA257A500D425B1 /* FlipSquaresNavigationController.m */, 297 | DD3C77911AA3192400D425B1 /* FlipSquaresGridAnimator.h */, 298 | DD3C77921AA3192400D425B1 /* FlipSquaresGridAnimator.m */, 299 | ); 300 | path = SquaresFlipNavigation; 301 | sourceTree = ""; 302 | }; 303 | DD3C77801AA25CA300D425B1 /* Classes */ = { 304 | isa = PBXGroup; 305 | children = ( 306 | DD3C77811AA25CD200D425B1 /* NSArrayMatrix.h */, 307 | DD3C77821AA25CD200D425B1 /* NSArrayMatrix.m */, 308 | ); 309 | path = Classes; 310 | sourceTree = ""; 311 | }; 312 | /* End PBXGroup section */ 313 | 314 | /* Begin PBXNativeTarget section */ 315 | 3CF16BB117930123006E912F /* ABCustomUINavigationController */ = { 316 | isa = PBXNativeTarget; 317 | buildConfigurationList = 3CF16BD517930123006E912F /* Build configuration list for PBXNativeTarget "ABCustomUINavigationController" */; 318 | buildPhases = ( 319 | 3CF16BAE17930123006E912F /* Sources */, 320 | 3CF16BAF17930123006E912F /* Frameworks */, 321 | 3CF16BB017930123006E912F /* Resources */, 322 | ); 323 | buildRules = ( 324 | ); 325 | dependencies = ( 326 | ); 327 | name = ABCustomUINavigationController; 328 | productName = SquaresFlipNavigationExample; 329 | productReference = 3CF16BB217930123006E912F /* ABCustomUINavigationController.app */; 330 | productType = "com.apple.product-type.application"; 331 | }; 332 | /* End PBXNativeTarget section */ 333 | 334 | /* Begin PBXProject section */ 335 | 3CF16BAA17930123006E912F /* Project object */ = { 336 | isa = PBXProject; 337 | attributes = { 338 | LastUpgradeCheck = 0800; 339 | ORGANIZATIONNAME = "Andrés Brun"; 340 | TargetAttributes = { 341 | 3CF16BB117930123006E912F = { 342 | ProvisioningStyle = Automatic; 343 | }; 344 | }; 345 | }; 346 | buildConfigurationList = 3CF16BAD17930123006E912F /* Build configuration list for PBXProject "ABCustomUINavigationController" */; 347 | compatibilityVersion = "Xcode 3.2"; 348 | developmentRegion = English; 349 | hasScannedForEncodings = 0; 350 | knownRegions = ( 351 | en, 352 | ); 353 | mainGroup = 3CF16BA917930123006E912F; 354 | productRefGroup = 3CF16BB317930123006E912F /* Products */; 355 | projectDirPath = ""; 356 | projectRoot = ""; 357 | targets = ( 358 | 3CF16BB117930123006E912F /* ABCustomUINavigationController */, 359 | ); 360 | }; 361 | /* End PBXProject section */ 362 | 363 | /* Begin PBXResourcesBuildPhase section */ 364 | 3CF16BB017930123006E912F /* Resources */ = { 365 | isa = PBXResourcesBuildPhase; 366 | buildActionMask = 2147483647; 367 | files = ( 368 | 3CCCEB0917B4E0F800750A12 /* bg_1.jpg in Resources */, 369 | 3CCCEB0A17B4E0F800750A12 /* bg_1_iPad.jpg in Resources */, 370 | 3CCCEB0B17B4E0F800750A12 /* bg_2.jpg in Resources */, 371 | 3CCCEB0C17B4E0F800750A12 /* bg_2_iPad.jpg in Resources */, 372 | 3CCCEB0D17B4E0F800750A12 /* bg_3.png in Resources */, 373 | 3CCCEB0E17B4E0F800750A12 /* bg_3_iPad.jpg in Resources */, 374 | 3CCCEB0F17B4E0F800750A12 /* Default-568h@2x.png in Resources */, 375 | 3CCCEB1017B4E0F800750A12 /* Default.png in Resources */, 376 | 3CCCEB1117B4E0F800750A12 /* Default@2x.png in Resources */, 377 | 3CCCEB1217B4E0F800750A12 /* InfoPlist.strings in Resources */, 378 | 3CCCEB1717B4E0F800750A12 /* SecondViewController_iPad.xib in Resources */, 379 | 3CCCEB1817B4E0F800750A12 /* SecondViewController_iPhone.xib in Resources */, 380 | 3CCCEB1917B4E0F800750A12 /* ThirthViewController_iPad.xib in Resources */, 381 | 3CCCEB1A17B4E0F800750A12 /* ThirthViewController_iPhone.xib in Resources */, 382 | 3CCCEB1B17B4E0F800750A12 /* ViewController_iPad.xib in Resources */, 383 | 3CCCEB1C17B4E0F800750A12 /* ViewController_iPhone.xib in Resources */, 384 | ); 385 | runOnlyForDeploymentPostprocessing = 0; 386 | }; 387 | /* End PBXResourcesBuildPhase section */ 388 | 389 | /* Begin PBXSourcesBuildPhase section */ 390 | 3CF16BAE17930123006E912F /* Sources */ = { 391 | isa = PBXSourcesBuildPhase; 392 | buildActionMask = 2147483647; 393 | files = ( 394 | DD3C77731AA257A500D425B1 /* FlipSquaresNavigationController.m in Sources */, 395 | DD3C776F1AA257A500D425B1 /* CubeAnimator.m in Sources */, 396 | DD3C77931AA3192400D425B1 /* FlipSquaresGridAnimator.m in Sources */, 397 | 3CCCEAE117B4E0A800750A12 /* NSObject+ABExtras.m in Sources */, 398 | DD3C776D1AA257A500D425B1 /* BaseNavigationController.m in Sources */, 399 | DD3C776E1AA257A500D425B1 /* BaseNavigationControllerDelegate.m in Sources */, 400 | DD3C77831AA25CD200D425B1 /* NSArrayMatrix.m in Sources */, 401 | DDEB0C8B1DB029A8001C170E /* UIImage+ABExtras.m in Sources */, 402 | 3CCCEAE417B4E0A800750A12 /* UIView+ABExtras.m in Sources */, 403 | DD909A2C1AA3671600A79883 /* NSNumber+ABGenerator.m in Sources */, 404 | 3CCCEB0817B4E0F800750A12 /* AppDelegate.m in Sources */, 405 | DD3C77721AA257A500D425B1 /* PixelateNavigationController.m in Sources */, 406 | DD3C77791AA259F000D425B1 /* GridBaseAnimator.m in Sources */, 407 | DD3C77701AA257A500D425B1 /* CubeNavigationController.m in Sources */, 408 | 3CCCEB1317B4E0F800750A12 /* main.m in Sources */, 409 | DD3C776C1AA257A500D425B1 /* BaseControllerAnimatedTransitioningDelegate.m in Sources */, 410 | 3CCCEB1417B4E0F800750A12 /* SecondViewController.m in Sources */, 411 | 3CCCEB1517B4E0F800750A12 /* ThirthViewController.m in Sources */, 412 | 3CCCEB1617B4E0F800750A12 /* ViewController.m in Sources */, 413 | DD3C777C1AA25A8200D425B1 /* PixelateGridAnimator.m in Sources */, 414 | ); 415 | runOnlyForDeploymentPostprocessing = 0; 416 | }; 417 | /* End PBXSourcesBuildPhase section */ 418 | 419 | /* Begin PBXVariantGroup section */ 420 | 3CCCEAF617B4E0F800750A12 /* InfoPlist.strings */ = { 421 | isa = PBXVariantGroup; 422 | children = ( 423 | 3CCCEAF717B4E0F800750A12 /* en */, 424 | ); 425 | name = InfoPlist.strings; 426 | sourceTree = ""; 427 | }; 428 | /* End PBXVariantGroup section */ 429 | 430 | /* Begin XCBuildConfiguration section */ 431 | 3CF16BD317930123006E912F /* Debug */ = { 432 | isa = XCBuildConfiguration; 433 | buildSettings = { 434 | ALWAYS_SEARCH_USER_PATHS = NO; 435 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 436 | CLANG_CXX_LIBRARY = "libc++"; 437 | CLANG_ENABLE_OBJC_ARC = YES; 438 | CLANG_WARN_BOOL_CONVERSION = YES; 439 | CLANG_WARN_CONSTANT_CONVERSION = YES; 440 | CLANG_WARN_EMPTY_BODY = YES; 441 | CLANG_WARN_ENUM_CONVERSION = YES; 442 | CLANG_WARN_INFINITE_RECURSION = YES; 443 | CLANG_WARN_INT_CONVERSION = YES; 444 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 445 | CLANG_WARN_UNREACHABLE_CODE = YES; 446 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 447 | CODE_SIGN_IDENTITY = "iPhone Developer: Andres Moreno (GEKTAXUSVL)"; 448 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 449 | COPY_PHASE_STRIP = NO; 450 | ENABLE_STRICT_OBJC_MSGSEND = YES; 451 | ENABLE_TESTABILITY = YES; 452 | GCC_C_LANGUAGE_STANDARD = gnu99; 453 | GCC_DYNAMIC_NO_PIC = NO; 454 | GCC_NO_COMMON_BLOCKS = YES; 455 | GCC_OPTIMIZATION_LEVEL = 0; 456 | GCC_PREPROCESSOR_DEFINITIONS = ( 457 | "DEBUG=1", 458 | "$(inherited)", 459 | ); 460 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 461 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 462 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 463 | GCC_WARN_UNDECLARED_SELECTOR = YES; 464 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 465 | GCC_WARN_UNUSED_FUNCTION = YES; 466 | GCC_WARN_UNUSED_VARIABLE = YES; 467 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 468 | ONLY_ACTIVE_ARCH = YES; 469 | PROVISIONING_PROFILE = "AF9FBB6F-40DA-4DDC-B334-3C3889D55A43"; 470 | SDKROOT = iphoneos; 471 | }; 472 | name = Debug; 473 | }; 474 | 3CF16BD417930123006E912F /* Release */ = { 475 | isa = XCBuildConfiguration; 476 | buildSettings = { 477 | ALWAYS_SEARCH_USER_PATHS = NO; 478 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 479 | CLANG_CXX_LIBRARY = "libc++"; 480 | CLANG_ENABLE_OBJC_ARC = YES; 481 | CLANG_WARN_BOOL_CONVERSION = YES; 482 | CLANG_WARN_CONSTANT_CONVERSION = YES; 483 | CLANG_WARN_EMPTY_BODY = YES; 484 | CLANG_WARN_ENUM_CONVERSION = YES; 485 | CLANG_WARN_INFINITE_RECURSION = YES; 486 | CLANG_WARN_INT_CONVERSION = YES; 487 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 488 | CLANG_WARN_UNREACHABLE_CODE = YES; 489 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 490 | CODE_SIGN_IDENTITY = "iPhone Developer: Andres Moreno (GEKTAXUSVL)"; 491 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 492 | COPY_PHASE_STRIP = YES; 493 | ENABLE_STRICT_OBJC_MSGSEND = YES; 494 | GCC_C_LANGUAGE_STANDARD = gnu99; 495 | GCC_NO_COMMON_BLOCKS = YES; 496 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 497 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 498 | GCC_WARN_UNDECLARED_SELECTOR = YES; 499 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 500 | GCC_WARN_UNUSED_FUNCTION = YES; 501 | GCC_WARN_UNUSED_VARIABLE = YES; 502 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 503 | OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; 504 | PROVISIONING_PROFILE = "AF9FBB6F-40DA-4DDC-B334-3C3889D55A43"; 505 | SDKROOT = iphoneos; 506 | VALIDATE_PRODUCT = YES; 507 | }; 508 | name = Release; 509 | }; 510 | 3CF16BD617930123006E912F /* Debug */ = { 511 | isa = XCBuildConfiguration; 512 | buildSettings = { 513 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 514 | DEVELOPMENT_TEAM = ""; 515 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 516 | GCC_PREFIX_HEADER = "ABCustomUINavigationControllerExample/ABCustomUINavigationController-Prefix.pch"; 517 | INFOPLIST_FILE = "ABCustomUINavigationControllerExample/ABCustomUINavigationController-Info.plist"; 518 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 519 | PRODUCT_BUNDLE_IDENTIFIER = "BrunosSoftware.${PRODUCT_NAME:rfc1034identifier}"; 520 | PRODUCT_NAME = ABCustomUINavigationController; 521 | PROVISIONING_PROFILE = ""; 522 | PROVISIONING_PROFILE_SPECIFIER = ""; 523 | TARGETED_DEVICE_FAMILY = "1,2"; 524 | WRAPPER_EXTENSION = app; 525 | }; 526 | name = Debug; 527 | }; 528 | 3CF16BD717930123006E912F /* Release */ = { 529 | isa = XCBuildConfiguration; 530 | buildSettings = { 531 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 532 | DEVELOPMENT_TEAM = ""; 533 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 534 | GCC_PREFIX_HEADER = "ABCustomUINavigationControllerExample/ABCustomUINavigationController-Prefix.pch"; 535 | INFOPLIST_FILE = "ABCustomUINavigationControllerExample/ABCustomUINavigationController-Info.plist"; 536 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 537 | PRODUCT_BUNDLE_IDENTIFIER = "BrunosSoftware.${PRODUCT_NAME:rfc1034identifier}"; 538 | PRODUCT_NAME = ABCustomUINavigationController; 539 | PROVISIONING_PROFILE_SPECIFIER = ""; 540 | TARGETED_DEVICE_FAMILY = "1,2"; 541 | WRAPPER_EXTENSION = app; 542 | }; 543 | name = Release; 544 | }; 545 | /* End XCBuildConfiguration section */ 546 | 547 | /* Begin XCConfigurationList section */ 548 | 3CF16BAD17930123006E912F /* Build configuration list for PBXProject "ABCustomUINavigationController" */ = { 549 | isa = XCConfigurationList; 550 | buildConfigurations = ( 551 | 3CF16BD317930123006E912F /* Debug */, 552 | 3CF16BD417930123006E912F /* Release */, 553 | ); 554 | defaultConfigurationIsVisible = 0; 555 | defaultConfigurationName = Release; 556 | }; 557 | 3CF16BD517930123006E912F /* Build configuration list for PBXNativeTarget "ABCustomUINavigationController" */ = { 558 | isa = XCConfigurationList; 559 | buildConfigurations = ( 560 | 3CF16BD617930123006E912F /* Debug */, 561 | 3CF16BD717930123006E912F /* Release */, 562 | ); 563 | defaultConfigurationIsVisible = 0; 564 | defaultConfigurationName = Release; 565 | }; 566 | /* End XCConfigurationList section */ 567 | }; 568 | rootObject = 3CF16BAA17930123006E912F /* Project object */; 569 | } 570 | -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/project.xcworkspace/xcuserdata/andresbrun.xcuserdatad/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges 6 | 7 | SnapshotAutomaticallyBeforeSignificantChanges 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/xcuserdata/andresbrun.xcuserdatad/xcdebugger/Breakpoints.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/xcuserdata/andresbrun.xcuserdatad/xcschemes/SquaresFlipNavigationExample.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 51 | 52 | 58 | 59 | 60 | 61 | 62 | 63 | 69 | 70 | 76 | 77 | 78 | 79 | 81 | 82 | 85 | 86 | 87 | -------------------------------------------------------------------------------- /ABCustomUINavigationController.xcodeproj/xcuserdata/andresbrun.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | SquaresFlipNavigationExample.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | 3CF16BB117930123006E912F 16 | 17 | primary 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ABCustomUINavigationController-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | ${PRODUCT_NAME} 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | UIInterfaceOrientationPortraitUpsideDown 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ABCustomUINavigationController-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header for all source files of the 'SquaresFlipNavigationExample' target in the 'SquaresFlipNavigationExample' project 3 | // 4 | 5 | #import 6 | 7 | #ifndef __IPHONE_4_0 8 | #warning "This project uses features only available in iOS SDK 4.0 and later." 9 | #endif 10 | 11 | #ifdef __OBJC__ 12 | #import 13 | #import 14 | #endif 15 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "ViewController.h" 12 | 13 | @interface AppDelegate : UIResponder 14 | 15 | @property (strong, nonatomic) UIWindow *window; 16 | 17 | @property (strong, nonatomic) ViewController *viewController; 18 | 19 | @end 20 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | 11 | #import "ViewController.h" 12 | 13 | #import "FlipSquaresNavigationController.h" 14 | #import "CubeNavigationController.h" 15 | #import "PixelateNavigationController.h" 16 | 17 | @implementation AppDelegate 18 | 19 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 20 | { 21 | self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; 22 | 23 | self.viewController = [[ViewController alloc] initViewController]; 24 | 25 | // self.window.rootViewController = [[CubeNavigationController alloc] initWithRootViewController:self.viewController]; 26 | self.window.rootViewController = [[FlipSquaresNavigationController alloc] initWithRootViewController:self.viewController]; 27 | // self.window.rootViewController = [[PixelateNavigationController alloc] initWithRootViewController:self.viewController]; 28 | 29 | [self.window makeKeyAndVisible]; 30 | 31 | return YES; 32 | } 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/Default-568h@2x.png -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/Default.png -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/Default@2x.png -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/SecondViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // SecondViewController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "ViewController.h" 10 | 11 | @interface SecondViewController : UIViewController 12 | 13 | - (id)initViewController; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/SecondViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // SecondViewController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "SecondViewController.h" 10 | #import "ThirthViewController.h" 11 | #import "FlipSquaresNavigationController.h" 12 | 13 | @interface SecondViewController () 14 | - (IBAction)popViewController:(id)sender; 15 | @end 16 | 17 | @implementation SecondViewController 18 | 19 | - (id)initViewController { 20 | if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) { 21 | self = [[SecondViewController alloc] initWithNibName:@"SecondViewController_iPhone" bundle:nil]; 22 | } else { 23 | self = [[SecondViewController alloc] initWithNibName:@"SecondViewController_iPad" bundle:nil]; 24 | } 25 | 26 | return self; 27 | } 28 | 29 | - (BOOL)shouldAutorotate { 30 | return YES; 31 | } 32 | 33 | - (UIInterfaceOrientationMask)supportedInterfaceOrientations { 34 | return UIInterfaceOrientationMaskAll; 35 | } 36 | 37 | 38 | - (IBAction)popViewController:(id)sender { 39 | [self.navigationController popViewControllerAnimated:YES]; 40 | } 41 | 42 | - (IBAction)pushViewController:(id)sender { 43 | ThirthViewController *thirthVC = [[ThirthViewController alloc] initViewController]; 44 | [self.navigationController pushViewController:thirthVC animated:YES]; 45 | } 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/ThirthViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ThirthViewController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/25/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ThirthViewController : UIViewController 12 | 13 | - (id)initViewController; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/ThirthViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ThirthViewController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/25/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "ThirthViewController.h" 10 | #import "ViewController.h" 11 | 12 | @interface ThirthViewController () 13 | 14 | @end 15 | 16 | @implementation ThirthViewController 17 | 18 | - (id)initViewController { 19 | if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) { 20 | self = [[ThirthViewController alloc] initWithNibName:@"ThirthViewController_iPhone" bundle:nil]; 21 | } else { 22 | self = [[ThirthViewController alloc] initWithNibName:@"ThirthViewController_iPad" bundle:nil]; 23 | } 24 | 25 | return self; 26 | } 27 | 28 | - (BOOL)shouldAutorotate { 29 | return YES; 30 | } 31 | 32 | - (UIInterfaceOrientationMask)supportedInterfaceOrientations { 33 | return UIInterfaceOrientationMaskAll; 34 | } 35 | 36 | - (IBAction)popViewController:(id)sender { 37 | [self.navigationController popViewControllerAnimated:YES]; 38 | } 39 | 40 | - (IBAction)popToFirstViewController:(id)sender { 41 | ViewController *firstVC = [self.navigationController.viewControllers objectAtIndex:0]; 42 | [self.navigationController popToViewController:firstVC animated:YES]; 43 | } 44 | 45 | - (IBAction)popToRootViewController:(id)sender { 46 | [self.navigationController popToRootViewControllerAnimated:YES]; 47 | } 48 | 49 | @end 50 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/ViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ViewController : UIViewController 12 | 13 | - (id)initViewController; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/ViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "ViewController.h" 10 | #import "SecondViewController.h" 11 | #import "ThirthViewController.h" 12 | #import "FlipSquaresNavigationController.h" 13 | 14 | @interface ViewController () 15 | - (IBAction)pushViewController:(id)sender; 16 | @end 17 | 18 | @implementation ViewController 19 | 20 | - (id)initViewController { 21 | if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) { 22 | self = [[ViewController alloc] initWithNibName:@"ViewController_iPhone" bundle:nil]; 23 | } else { 24 | self = [[ViewController alloc] initWithNibName:@"ViewController_iPad" bundle:nil]; 25 | } 26 | 27 | return self; 28 | } 29 | 30 | - (void)viewDidLoad { 31 | [super viewDidLoad]; 32 | 33 | [self.navigationController setNavigationBarHidden:YES]; 34 | } 35 | 36 | - (BOOL)shouldAutorotate { 37 | return NO; 38 | } 39 | 40 | - (UIInterfaceOrientationMask)supportedInterfaceOrientations { 41 | return UIInterfaceOrientationMaskAll; 42 | } 43 | 44 | - (IBAction)pushViewController:(id)sender { 45 | SecondViewController *secondVC = [[SecondViewController alloc] initViewController]; 46 | [self.navigationController pushViewController:secondVC animated:YES]; 47 | } 48 | 49 | - (IBAction)pushToThirthViewController:(id)sender { 50 | ThirthViewController *thirthVC = [[ThirthViewController alloc] initViewController]; 51 | [self.navigationController pushViewController:thirthVC animated:YES]; 52 | } 53 | 54 | @end 55 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/SecondViewController_iPad.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/SecondViewController_iPhone.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/ThirthViewController_iPad.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/ThirthViewController_iPhone.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/ViewController_iPad.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/ViewControllers/Views/ViewController_iPhone.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 38 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_1.jpg -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_1_iPad.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_1_iPad.jpg -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_2.jpg -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_2_iPad.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_2_iPad.jpg -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_3.png -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/assets/bg_3_iPad.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/ABCustomUINavigationControllerExample/assets/bg_3_iPad.jpg -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /ABCustomUINavigationControllerExample/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "AppDelegate.h" 12 | 13 | int main(int argc, char *argv[]) 14 | { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/NSNumber+ABGenerator.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSNumber+ABGenerator.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface NSNumber (ABGenerator) 12 | 13 | + (CGFloat) getRandomFloat01; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/NSNumber+ABGenerator.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSNumber+ABGenerator.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | 10 | #import "NSNumber+ABGenerator.h" 11 | 12 | #define ARC4RANDOM_MAX 0x100000000 13 | 14 | @implementation NSNumber (ABGenerator) 15 | 16 | + (CGFloat) getRandomFloat01 { 17 | return ((double)arc4random() / ARC4RANDOM_MAX); 18 | } 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/NSObject+ABExtras.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+ABExtras.h 3 | // uSpeak 4 | // 5 | // Created by uSpeak on 28/05/13. 6 | // Copyright (c) 2013 uSpeak Ltd. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface NSObject (ABExtras) 12 | 13 | - (void)performBlock:(void (^)(void))block afterDelay:(NSTimeInterval)delay; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/NSObject+ABExtras.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+ABExtras.m 3 | // uSpeak 4 | // 5 | // Created by uSpeak on 28/05/13. 6 | // Copyright (c) 2013 uSpeak Ltd. All rights reserved. 7 | // 8 | 9 | #import "NSObject+ABExtras.h" 10 | 11 | @implementation NSObject (ABExtras) 12 | 13 | - (void)performBlock:(void (^)(void))block 14 | afterDelay:(NSTimeInterval)delay { 15 | dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(delay * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ 16 | block(); 17 | }); 18 | } 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/UIImage+ABExtras.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIImage+ABExtras.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 13/10/2016. 6 | // Copyright © 2016 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface UIImage (ABExtras) 12 | 13 | - (UIImageView *)imageViewByCroppingInRect:(CGRect)rect; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/UIImage+ABExtras.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIImage+ABExtras.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 13/10/2016. 6 | // Copyright © 2016 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "UIImage+ABExtras.h" 10 | 11 | @implementation UIImage (ABExtras) 12 | 13 | - (UIImageView *)imageViewByCroppingInRect:(CGRect)rect 14 | { 15 | UIImage *imageCropped = [self cropImageInRect:rect]; 16 | UIImageView* imageViewCropped = [[UIImageView alloc] initWithImage:imageCropped]; 17 | [imageViewCropped setFrame:rect]; 18 | return imageViewCropped; 19 | } 20 | 21 | - (UIImage *)cropImageInRect:(CGRect)rect 22 | { 23 | double (^rad)(double) = ^(double deg) { 24 | return deg / 180.0 * M_PI; 25 | }; 26 | 27 | CGAffineTransform rectTransform; 28 | switch (self.imageOrientation) { 29 | case UIImageOrientationLeft: 30 | rectTransform = CGAffineTransformTranslate(CGAffineTransformMakeRotation(rad(90)), 0, -self.size.height); 31 | break; 32 | case UIImageOrientationRight: 33 | rectTransform = CGAffineTransformTranslate(CGAffineTransformMakeRotation(rad(-90)), -self.size.width, 0); 34 | break; 35 | case UIImageOrientationDown: 36 | rectTransform = CGAffineTransformTranslate(CGAffineTransformMakeRotation(rad(-180)), -self.size.width, -self.size.height); 37 | break; 38 | default: 39 | rectTransform = CGAffineTransformIdentity; 40 | }; 41 | rectTransform = CGAffineTransformScale(rectTransform, self.scale, self.scale); 42 | 43 | CGImageRef imageRef = CGImageCreateWithImageInRect([self CGImage], CGRectApplyAffineTransform(rect, rectTransform)); 44 | UIImage *result = [UIImage imageWithCGImage:imageRef scale:self.scale orientation:self.imageOrientation]; 45 | CGImageRelease(imageRef); 46 | 47 | return result; 48 | } 49 | 50 | @end 51 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/UIView+ABExtras.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+ABExtras.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 8/8/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface UIView (ABExtras) 13 | 14 | /** 15 | Method that adds a gradient sublayer in that view 16 | */ 17 | - (CAGradientLayer *)addLinearGradientWithColor:(UIColor *)theColor transparentToOpaque:(BOOL)transparentToOpaque; 18 | 19 | /** 20 | Create an snapshot view of the current view 21 | */ 22 | - (UIView *) createSnapshotView; 23 | 24 | /** 25 | Create an snapshot UIImage 26 | */ 27 | - (UIImage *) createImageView; 28 | 29 | /** 30 | Method that adds a view with color in that view 31 | */ 32 | - (UIView *)addOpacityWithColor:(UIColor *)theColor; 33 | 34 | /** 35 | Method that generate a new view adding self as subview 36 | */ 37 | - (UIView *)embedView; 38 | 39 | /** 40 | Method that return the embedded view if exists 41 | */ 42 | - (UIView *)getEmbeddedView; 43 | 44 | /** 45 | Method that generate a new view by cropping an area 46 | */ 47 | - (UIView *)viewByCroppingInRect:(CGRect)rect; 48 | 49 | @end 50 | -------------------------------------------------------------------------------- /CustomUINavigationController/Categories/UIView+ABExtras.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIView+ABExtras.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 8/8/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "UIView+ABExtras.h" 10 | 11 | const NSInteger TAG_EMBEDDED_VIEW = 999; 12 | 13 | @implementation UIView (ABExtras) 14 | 15 | - (CAGradientLayer *)addLinearGradientWithColor:(UIColor *)theColor transparentToOpaque:(BOOL)transparentToOpaque 16 | { 17 | CAGradientLayer *gradient = [CAGradientLayer layer]; 18 | 19 | //the gradient layer must be positioned at the origin of the view 20 | CGRect gradientFrame = self.frame; 21 | gradientFrame.origin.x = 0; 22 | gradientFrame.origin.y = 0; 23 | gradient.frame = gradientFrame; 24 | 25 | //build the colors array for the gradient 26 | NSArray *colors = [NSArray arrayWithObjects: 27 | (id)[theColor CGColor], 28 | (id)[[theColor colorWithAlphaComponent:0.9f] CGColor], 29 | (id)[[theColor colorWithAlphaComponent:0.6f] CGColor], 30 | (id)[[theColor colorWithAlphaComponent:0.4f] CGColor], 31 | (id)[[theColor colorWithAlphaComponent:0.3f] CGColor], 32 | (id)[[theColor colorWithAlphaComponent:0.1f] CGColor], 33 | (id)[[UIColor clearColor] CGColor], 34 | nil]; 35 | 36 | //reverse the color array if needed 37 | if(transparentToOpaque) { 38 | colors = [[colors reverseObjectEnumerator] allObjects]; 39 | } 40 | 41 | //apply the colors and the gradient to the view 42 | gradient.colors = colors; 43 | 44 | unsigned index = (unsigned)[self.layer.sublayers count]; 45 | [self.layer insertSublayer:gradient atIndex:index]; 46 | 47 | return gradient; 48 | } 49 | 50 | - (UIView *)addOpacityWithColor:(UIColor *)theColor 51 | { 52 | UIView *shadowView = [[UIView alloc] initWithFrame:self.bounds]; 53 | 54 | [shadowView setBackgroundColor:theColor]; 55 | 56 | [self addSubview:shadowView]; 57 | 58 | return shadowView; 59 | } 60 | 61 | - (UIView *)embedView 62 | { 63 | UIView *newView = [[UIView alloc] initWithFrame:self.frame]; 64 | [self setTag:TAG_EMBEDDED_VIEW]; 65 | [self setFrame:self.bounds]; 66 | [newView addSubview:self]; 67 | 68 | return newView; 69 | } 70 | 71 | - (UIView *)getEmbeddedView { 72 | return [self viewWithTag:TAG_EMBEDDED_VIEW]; 73 | } 74 | 75 | - (UIView *)viewByCroppingInRect:(CGRect)rect { 76 | return [self resizableSnapshotViewFromRect:rect afterScreenUpdates:YES withCapInsets:UIEdgeInsetsZero]; 77 | } 78 | 79 | - (UIImage *) createImageView { 80 | UIGraphicsBeginImageContextWithOptions(self.bounds.size, self.opaque, [UIScreen mainScreen].scale); 81 | [self.layer renderInContext:UIGraphicsGetCurrentContext()]; 82 | 83 | UIImage * img = UIGraphicsGetImageFromCurrentImageContext(); 84 | 85 | UIGraphicsEndImageContext(); 86 | 87 | return img; 88 | } 89 | 90 | - (UIView *) createSnapshotView 91 | { 92 | UIView *currentView = [self snapshotViewAfterScreenUpdates:YES]; 93 | 94 | return currentView; 95 | } 96 | 97 | @end 98 | -------------------------------------------------------------------------------- /CustomUINavigationController/Classes/NSArrayMatrix.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSArrayMatrix.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | @interface NSArrayMatrix : NSObject 10 | 11 | @property(nonatomic, assign, readonly) NSUInteger rows; 12 | @property(nonatomic, assign, readonly) NSUInteger columns; 13 | @property(nonatomic, strong, readonly) NSMutableArray *elements; 14 | 15 | - (instancetype)initWithRows:(NSUInteger)rows columns:(NSUInteger)columns; 16 | 17 | - (void) fillWithOrderData; 18 | - (void) iterateOverElementsWithBlock: (void (^)(NSUInteger row, NSUInteger col))iterationBlock; 19 | 20 | - (void) randomize; 21 | - (void) sortRightScanning; 22 | - (void) sortLeftScanning; 23 | 24 | @end 25 | -------------------------------------------------------------------------------- /CustomUINavigationController/Classes/NSArrayMatrix.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSArrayMatrix.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "NSArrayMatrix.h" 10 | 11 | @interface NSArrayMatrix () 12 | @property(nonatomic, assign) NSUInteger rows; 13 | @property(nonatomic, assign) NSUInteger columns; 14 | @property(nonatomic, strong) NSMutableArray *elements; 15 | @end 16 | 17 | @implementation NSArrayMatrix 18 | 19 | - (instancetype)initWithRows:(NSUInteger)rows columns:(NSUInteger)columns { 20 | self = [super init]; 21 | if (self) { 22 | self.rows = rows; 23 | self.columns = columns; 24 | self.elements = [NSMutableArray array]; 25 | } 26 | return self; 27 | } 28 | 29 | - (void) fillWithOrderData { 30 | for (int i=0; i 10 | 11 | @interface BaseControllerAnimatedTransitioningDelegate : NSObject 12 | 13 | @property (nonatomic, weak) UIView *containerView; 14 | @property (nonatomic, weak) UIView *fromView; 15 | @property (nonatomic, weak) UIView *toView; 16 | 17 | @property (nonatomic, assign) NSTimeInterval animationDuration; 18 | 19 | @property (nonatomic, assign, getter=isPresenting) BOOL presenting; 20 | 21 | - (void)animateWithCompletion:(void(^)(void))completion; 22 | 23 | @end 24 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/BaseControllerAnimatedTransitioningDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // BaseNavigationControllerDelegate.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "BaseControllerAnimatedTransitioningDelegate.h" 10 | #import "UIView+ABExtras.h" 11 | 12 | @implementation BaseControllerAnimatedTransitioningDelegate 13 | 14 | - (NSTimeInterval)transitionDuration:(id )transitionContext { 15 | return [self animationDuration]; 16 | } 17 | 18 | - (void)animateTransition:(id )transitionContext { 19 | [self captureViewsInContext:transitionContext]; 20 | 21 | self.toView.frame = self.containerView.frame; 22 | 23 | [self animateWithCompletion:^{ 24 | [self setFinalStateForTransitionContext:transitionContext]; 25 | [transitionContext completeTransition:YES]; 26 | }]; 27 | } 28 | 29 | - (void)setFinalStateForTransitionContext:(id )transitionContext { 30 | UIViewController *fromVC = [transitionContext viewControllerForKey:UITransitionContextFromViewControllerKey]; 31 | [fromVC.view setFrame:[transitionContext finalFrameForViewController:fromVC]]; 32 | 33 | UIViewController *toVC = [transitionContext viewControllerForKey:UITransitionContextToViewControllerKey]; 34 | [toVC.view setFrame:[transitionContext finalFrameForViewController:toVC]]; 35 | 36 | [self.containerView addSubview:toVC.view]; 37 | } 38 | 39 | - (void)animateWithCompletion:(void(^)(void))completion { 40 | NSAssert(YES, @"Abstract method, shouldn't be call directly"); 41 | } 42 | 43 | - (NSTimeInterval)animationDuration { 44 | return 1; 45 | } 46 | 47 | - (void)captureViewsInContext:(id )transitionContext { 48 | if ([transitionContext respondsToSelector:@selector(viewForKey:)]) { 49 | self.toView = [transitionContext viewForKey:UITransitionContextToViewKey]; 50 | self.fromView = [transitionContext viewForKey:UITransitionContextFromViewKey]; 51 | } else { 52 | self.toView = [transitionContext viewControllerForKey:UITransitionContextToViewControllerKey].view; 53 | self.fromView = [transitionContext viewControllerForKey:UITransitionContextFromViewControllerKey].view; 54 | } 55 | 56 | self.containerView = [transitionContext containerView]; 57 | } 58 | 59 | @end 60 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/BaseNavigationController.h: -------------------------------------------------------------------------------- 1 | // 2 | // BaseNavigationController.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | @class BaseControllerAnimatedTransitioningDelegate; 11 | 12 | @interface BaseNavigationController : UINavigationController 13 | 14 | - (BaseControllerAnimatedTransitioningDelegate *)createAnimatedTransitioningUsed; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/BaseNavigationController.m: -------------------------------------------------------------------------------- 1 | // 2 | // BaseNavigationController.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "BaseNavigationController.h" 10 | #import "BaseNavigationControllerDelegate.h" 11 | 12 | @interface BaseNavigationController () 13 | @property (nonatomic, strong) BaseNavigationControllerDelegate *navigationDelegate; 14 | @end 15 | 16 | @implementation BaseNavigationController 17 | 18 | - (instancetype)initWithRootViewController:(UIViewController *)rootViewController { 19 | self = [super initWithRootViewController:rootViewController]; 20 | if (self) { 21 | self.navigationDelegate = [[BaseNavigationControllerDelegate alloc] initWithAnimatedTransitioning:[self createAnimatedTransitioningUsed]]; 22 | self.delegate = self.navigationDelegate; 23 | } 24 | return self; 25 | } 26 | 27 | - (void)setDelegate:(id)delegate { 28 | if (!self.delegate) { 29 | [super setDelegate:delegate]; 30 | } 31 | 32 | if (delegate!=self.delegate) { 33 | [self.navigationDelegate setForwardDelegate: delegate]; 34 | } 35 | } 36 | 37 | - (BaseControllerAnimatedTransitioningDelegate *)createAnimatedTransitioningUsed { 38 | NSAssert(YES, @"Abstract method, it should be inherated"); 39 | return nil; 40 | } 41 | 42 | @end 43 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/BaseNavigationControllerDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // TransitionViewControllerDelegate.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | @class BaseControllerAnimatedTransitioningDelegate; 11 | 12 | @interface BaseNavigationControllerDelegate : NSObject 13 | 14 | - (instancetype)initWithAnimatedTransitioning:(BaseControllerAnimatedTransitioningDelegate *)animatedTransitioningUsed; 15 | 16 | @property (weak) id forwardDelegate; 17 | @property (nonatomic, strong) BaseControllerAnimatedTransitioningDelegate *transitionDelegate; 18 | 19 | @end 20 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/BaseNavigationControllerDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // TransitionViewControllerDelegate.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "BaseNavigationControllerDelegate.h" 10 | #import "BaseControllerAnimatedTransitioningDelegate.h" 11 | 12 | @implementation BaseNavigationControllerDelegate 13 | 14 | - (instancetype)initWithAnimatedTransitioning:(BaseControllerAnimatedTransitioningDelegate *)animatedTransitioningUsed { 15 | self = [super init]; 16 | if (self) { 17 | self.transitionDelegate = animatedTransitioningUsed; 18 | } 19 | return self; 20 | } 21 | 22 | - (id)navigationController:(UINavigationController *)navigationController 23 | animationControllerForOperation:(UINavigationControllerOperation)operation 24 | fromViewController:(UIViewController *)fromVC 25 | toViewController:(UIViewController *)toVC { 26 | self.transitionDelegate.presenting = (operation == UINavigationControllerOperationPush); 27 | return self.transitionDelegate; 28 | } 29 | 30 | - (void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated { 31 | if (self.forwardDelegate && [self.forwardDelegate respondsToSelector:@selector(navigationController:willShowViewController:animated:)]) { 32 | [self.forwardDelegate navigationController:navigationController willShowViewController:viewController animated:animated]; 33 | } 34 | } 35 | 36 | - (void)navigationController:(UINavigationController *)navigationController didShowViewController:(UIViewController *)viewController animated:(BOOL)animated { 37 | if (self.forwardDelegate && [self.forwardDelegate respondsToSelector:@selector(navigationController:didShowViewController:animated:)]) { 38 | [self.forwardDelegate navigationController:navigationController didShowViewController:viewController animated:animated]; 39 | } 40 | } 41 | 42 | - (id)navigationController:(UINavigationController *)navigationController interactionControllerForAnimationController:(id)animationController { 43 | if (self.forwardDelegate && [self.forwardDelegate respondsToSelector:@selector(navigationController:interactionControllerForAnimationController:)]) { 44 | return [self.forwardDelegate navigationController:navigationController interactionControllerForAnimationController:animationController]; 45 | } 46 | return nil; 47 | } 48 | 49 | @end 50 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/CubeNavigation/CubeAnimator.h: -------------------------------------------------------------------------------- 1 | // 2 | // CubeNavigationController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 8/8/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "BaseControllerAnimatedTransitioningDelegate.h" 11 | 12 | typedef enum { 13 | CubeAnimationTypeHorizontal, 14 | CubeAnimationTypeVertical 15 | } CubeAnimationType; 16 | 17 | @interface CubeAnimator : BaseControllerAnimatedTransitioningDelegate 18 | 19 | @property (nonatomic, assign) CubeAnimationType cubeAnimationType; 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/CubeNavigation/CubeAnimator.m: -------------------------------------------------------------------------------- 1 | // 2 | // CubeNavigationController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 8/8/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "CubeAnimator.h" 10 | #import "UIView+ABExtras.h" 11 | 12 | const NSTimeInterval TIME_ANIMATION = 1.0; 13 | const CGFloat PERSPECTIVE = -1.0 / 200.0; 14 | const CGFloat ROTATION_ANGLE = M_PI_2; 15 | 16 | @interface CubeAnimator () 17 | @property (nonatomic, assign) CATransform3D viewFromTransform; 18 | @property (nonatomic, assign) CATransform3D viewToTransform; 19 | @property (nonatomic, strong) UIView *auxiliarContainerView; 20 | @property (nonatomic, weak) UIView *fromShadow; 21 | @property (nonatomic, weak) UIView *toShadow; 22 | 23 | @property (nonatomic,copy)void (^completionBlock)(); 24 | @end 25 | 26 | @implementation CubeAnimator 27 | 28 | #pragma mark - Inhereted Methods 29 | - (instancetype)init { 30 | self = [super init]; 31 | if (self) { 32 | self.cubeAnimationType = CubeAnimationTypeHorizontal; 33 | } 34 | return self; 35 | } 36 | 37 | - (NSTimeInterval)animationDuration { 38 | return TIME_ANIMATION; 39 | } 40 | 41 | - (void)animateWithCompletion:(void (^)(void))completion { 42 | 43 | self.completionBlock = completion; 44 | 45 | [self setUpTransition]; 46 | 47 | [self doAnimation]; 48 | } 49 | 50 | #pragma mark - Private methods 51 | - (void)setUpTransition { 52 | self.auxiliarContainerView = [self createAuxiliarContainerView]; 53 | [self create3DTransforms]; 54 | [self setToViewInitialTransform]; 55 | [self setUpViewsHierarchyInContainer:self.auxiliarContainerView]; 56 | [self addShadows]; 57 | [self shadowsDarkenFromViewLightToView]; 58 | } 59 | 60 | - (UIView *) createAuxiliarContainerView { 61 | return [[UIView alloc] initWithFrame:self.containerView.bounds]; 62 | } 63 | 64 | - (void)create3DTransforms { 65 | switch (self.cubeAnimationType) { 66 | case CubeAnimationTypeHorizontal: 67 | [self prepareHorizontalAnimation]; 68 | break; 69 | 70 | case CubeAnimationTypeVertical: 71 | [self prepareVerticalAnimation]; 72 | break; 73 | } 74 | } 75 | 76 | - (void)prepareHorizontalAnimation { 77 | CATransform3D viewFromTransform = CATransform3DMakeRotation(self.transitionDirection * ROTATION_ANGLE, 0.0, 1.0, 0.0); 78 | CATransform3D viewToTransform = CATransform3DMakeRotation(-self.transitionDirection * ROTATION_ANGLE, 0.0, 1.0, 0.0); 79 | viewToTransform.m34 = viewFromTransform.m34 = PERSPECTIVE; 80 | self.viewFromTransform = viewFromTransform; 81 | self.viewToTransform = viewToTransform; 82 | 83 | [self.toView.layer setAnchorPoint:CGPointMake(self.presenting?0:1, 0.5)]; 84 | [self.fromView.layer setAnchorPoint:CGPointMake(self.presenting?1:0, 0.5)]; 85 | 86 | [self.auxiliarContainerView setTransform:CGAffineTransformMakeTranslation(self.transitionDirection * (self.auxiliarContainerView.frame.size.width)/2.0, 0)]; 87 | } 88 | 89 | - (void)prepareVerticalAnimation { 90 | CATransform3D viewFromTransform = CATransform3DMakeRotation(-self.transitionDirection * ROTATION_ANGLE, 1.0, 0.0, 0.0); 91 | CATransform3D viewToTransform = CATransform3DMakeRotation(self.transitionDirection * ROTATION_ANGLE, 1.0, 0.0, 0.0); 92 | viewToTransform.m34 = viewFromTransform.m34 = PERSPECTIVE; 93 | self.viewFromTransform = viewFromTransform; 94 | self.viewToTransform = viewToTransform; 95 | 96 | [self.toView.layer setAnchorPoint:CGPointMake(0.5, self.presenting?0:1)]; 97 | [self.fromView.layer setAnchorPoint:CGPointMake(0.5, self.presenting?1:0)]; 98 | 99 | // TODO: check y position 100 | [self.auxiliarContainerView setTransform:CGAffineTransformMakeTranslation(0, self.transitionDirection * (self.auxiliarContainerView.frame.size.height)/2.0)]; 101 | } 102 | 103 | - (void)setToViewInitialTransform { 104 | self.toView.layer.transform = self.viewToTransform; 105 | } 106 | 107 | - (void)setUpViewsHierarchyInContainer: (UIView *) auxiliarContainer { 108 | [auxiliarContainer addSubview:self.toView]; 109 | [auxiliarContainer addSubview:self.fromView]; 110 | [self.containerView addSubview:auxiliarContainer]; 111 | } 112 | 113 | - (NSInteger)transitionDirection { 114 | return [self isPresenting] ? 1 : -1; 115 | } 116 | 117 | - (void)addShadows { 118 | self.fromShadow = [self.fromView addOpacityWithColor:[[UIColor blackColor] colorWithAlphaComponent:0.8]]; 119 | self.toShadow = [self.toView addOpacityWithColor:[[UIColor blackColor] colorWithAlphaComponent:0.8]]; 120 | } 121 | 122 | - (void)doAnimation { 123 | [UIView animateWithDuration:[self animationDuration] animations:^{ 124 | [self moveCube]; 125 | [self shadowsLightFromViewDarkenToView]; 126 | }completion:^(BOOL finished) { 127 | [self cleanContext]; 128 | self.completionBlock(); 129 | }]; 130 | } 131 | 132 | - (void)shadowsDarkenFromViewLightToView { 133 | [self.fromShadow setAlpha:0.0]; 134 | [self.toShadow setAlpha:1.0]; 135 | } 136 | 137 | - (void)shadowsLightFromViewDarkenToView { 138 | [self.fromShadow setAlpha:1.0]; 139 | [self.toShadow setAlpha:0.0]; 140 | } 141 | 142 | - (void)moveCube { 143 | switch (self.cubeAnimationType) { 144 | case CubeAnimationTypeHorizontal: 145 | [self.auxiliarContainerView setTransform:CGAffineTransformMakeTranslation(-self.transitionDirection * self.auxiliarContainerView.frame.size.width/2.0, 0)]; 146 | break; 147 | 148 | case CubeAnimationTypeVertical: 149 | //TODO: check Y position 150 | [self.auxiliarContainerView setTransform:CGAffineTransformMakeTranslation(0, -self.transitionDirection * (self.auxiliarContainerView.frame.size.height)/2.0)]; 151 | break; 152 | 153 | default: 154 | break; 155 | } 156 | 157 | self.fromView.layer.transform = self.viewFromTransform; 158 | self.toView.layer.transform = CATransform3DIdentity; 159 | } 160 | 161 | - (void)cleanContext { 162 | for (UIView *view in @[self.fromView, self.toView, self.fromShadow, self.toShadow, self.auxiliarContainerView]) { 163 | [view.layer setAnchorPoint:CGPointMake(0.5, 0.5)]; 164 | [view removeFromSuperview]; 165 | [view setTransform:CGAffineTransformIdentity]; 166 | } 167 | } 168 | 169 | @end 170 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/CubeNavigation/CubeNavigationController.h: -------------------------------------------------------------------------------- 1 | // 2 | // CubeNavigationController.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "BaseNavigationController.h" 10 | 11 | @interface CubeNavigationController : BaseNavigationController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/CubeNavigation/CubeNavigationController.m: -------------------------------------------------------------------------------- 1 | // 2 | // CubeNavigationController.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 27/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "CubeNavigationController.h" 10 | #import "CubeAnimator.h" 11 | 12 | @implementation CubeNavigationController 13 | 14 | - (BaseControllerAnimatedTransitioningDelegate *)createAnimatedTransitioningUsed { 15 | return [CubeAnimator new]; 16 | } 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/GridBaseAnimator.h: -------------------------------------------------------------------------------- 1 | // 2 | // GridBaseAnimator.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "BaseControllerAnimatedTransitioningDelegate.h" 10 | 11 | typedef enum { 12 | ScanningSortMethodRandom, 13 | ScanningSortMethodHorizontal 14 | } ScanningSortMethod; 15 | 16 | @interface GridBaseAnimator : BaseControllerAnimatedTransitioningDelegate 17 | 18 | @property (nonatomic, assign) ScanningSortMethod sortMethod; 19 | @property (nonatomic, assign, readonly) NSUInteger rowsNumber; 20 | @property (nonatomic, assign, readonly) NSUInteger columnsNumber; 21 | 22 | - (void)animateFromCellView:(UIView *)fromCell 23 | toCellView:(UIView *)toCell 24 | inTime:(NSTimeInterval)time; 25 | 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/GridBaseAnimator.m: -------------------------------------------------------------------------------- 1 | // 2 | // GridBaseAnimator.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "GridBaseAnimator.h" 10 | 11 | #import "UIView+ABExtras.h" 12 | #import "UIImage+ABExtras.h" 13 | #import "NSObject+ABExtras.h" 14 | #import "NSNumber+ABGenerator.h" 15 | 16 | #import "NSArrayMatrix.h" 17 | 18 | @interface GridBaseAnimator () 19 | @property(nonatomic, strong) NSMutableArray *fromGridCellViewArray; 20 | @property(nonatomic, strong) NSMutableArray *toGridCellViewArray; 21 | @property(nonatomic, strong) NSArrayMatrix *orderMatrix; 22 | 23 | @property (nonatomic,copy)void (^completionBlock)(); 24 | @end 25 | 26 | @implementation GridBaseAnimator 27 | 28 | - (NSUInteger)rowsNumber { 29 | return 5; 30 | } 31 | 32 | - (NSUInteger)columnsNumber { 33 | return 5; 34 | } 35 | 36 | - (void)animateWithCompletion:(void (^)(void))completion { 37 | self.completionBlock = completion; 38 | 39 | [self setUpOrderMatrix]; 40 | [self startOperationsToAnimate]; 41 | } 42 | 43 | - (void)startOperationsToAnimate { 44 | NSInvocationOperation *createGridOperation = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(createGridViews) object:nil]; 45 | [createGridOperation setQualityOfService:NSQualityOfServiceBackground]; 46 | 47 | NSInvocationOperation *prepareEnvironmentOperation = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(prepareEnvironment) object:nil]; 48 | [prepareEnvironmentOperation setQualityOfService:NSQualityOfServiceBackground]; 49 | [prepareEnvironmentOperation addDependency:createGridOperation]; 50 | 51 | NSInvocationOperation *animateOperation = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(animate) object:nil]; 52 | [animateOperation setQualityOfService:NSQualityOfServiceUserInteractive]; 53 | [animateOperation addDependency:prepareEnvironmentOperation]; 54 | 55 | [[NSOperationQueue mainQueue] addOperations:@[createGridOperation, prepareEnvironmentOperation, animateOperation] waitUntilFinished:NO]; 56 | } 57 | 58 | - (void)createGridViews { 59 | self.fromGridCellViewArray = [NSMutableArray array]; 60 | self.toGridCellViewArray = [NSMutableArray array]; 61 | 62 | UIImage *fromImageView = [self.fromView createImageView]; 63 | UIImage *toImageView = [self.toView createImageView]; 64 | 65 | [self.orderMatrix iterateOverElementsWithBlock:^(NSUInteger row, NSUInteger col) { 66 | CGRect croppedRect = [self gridCellRectForRow:row column:col]; 67 | 68 | UIView *fromViewCrop = [self createCellForView:fromImageView withRect:croppedRect]; 69 | UIView *toViewCrop = [self createCellForView:toImageView withRect:croppedRect]; 70 | 71 | [self.fromGridCellViewArray addObject:fromViewCrop]; 72 | [self.toGridCellViewArray addObject:toViewCrop]; 73 | }]; 74 | } 75 | 76 | - (UIView *) createCellForView:(UIImage *)image withRect:(CGRect)croppedRect { 77 | return [[image imageViewByCroppingInRect: croppedRect] embedView]; 78 | } 79 | 80 | - (void)setUpOrderMatrix { 81 | self.orderMatrix = [[NSArrayMatrix alloc] initWithRows:self.rowsNumber columns:self.columnsNumber]; 82 | [self.orderMatrix fillWithOrderData]; 83 | 84 | [self shuffleOrderMatrix]; 85 | } 86 | 87 | - (void)prepareEnvironment { 88 | [self addFromGridViewsToContainer]; 89 | [self hideSourceView]; 90 | } 91 | 92 | - (void)animate { 93 | [self doAnimationWithCompletion:^{ 94 | [self finishAnimation]; 95 | }]; 96 | } 97 | 98 | - (void)shuffleOrderMatrix { 99 | switch (self.sortMethod) { 100 | case ScanningSortMethodRandom: 101 | [self.orderMatrix randomize]; 102 | break; 103 | case ScanningSortMethodHorizontal: 104 | if (self.presenting) { 105 | [self.orderMatrix sortRightScanning]; 106 | } else { 107 | [self.orderMatrix sortLeftScanning]; 108 | } 109 | break; 110 | } 111 | } 112 | 113 | - (CGRect)gridCellRectForRow:(NSUInteger)row column:(NSUInteger)column { 114 | float rowsWidth = self.fromView.frame.size.width / self.orderMatrix.rows; 115 | float columnsHeight = self.fromView.frame.size.height / self.orderMatrix.columns; 116 | CGRect croppedRect = CGRectMake(row * rowsWidth, 117 | column * columnsHeight, 118 | rowsWidth, 119 | columnsHeight); 120 | return croppedRect; 121 | } 122 | 123 | - (void)hideSourceView { 124 | [self.fromView setHidden:YES]; 125 | } 126 | 127 | - (void)restoreSourceView { 128 | [self.fromView setHidden:NO]; 129 | } 130 | 131 | - (void)addFromGridViewsToContainer { 132 | for (UIView *currentView in self.fromGridCellViewArray) { 133 | [self.containerView addSubview:currentView]; 134 | } 135 | } 136 | 137 | - (void)doAnimationWithCompletion:(void(^)(void))completion { 138 | float cellAnimationTime = self.animationDuration*0.3; 139 | 140 | for (NSNumber *currentPos in self.orderMatrix.elements) { 141 | NSInteger posIndex = [self.orderMatrix.elements indexOfObject:currentPos]; 142 | UIView *fromViewCrop = [self.fromGridCellViewArray objectAtIndex:[currentPos intValue]]; 143 | UIView *toViewCrop = [self.toGridCellViewArray objectAtIndex:[currentPos intValue]]; 144 | NSTimeInterval delay = [self calculateDelayForIndex:posIndex]; 145 | 146 | [self performBlock:^{ 147 | [self animateFromCellView:fromViewCrop toCellView:toViewCrop inTime:cellAnimationTime]; 148 | } afterDelay:delay]; 149 | } 150 | 151 | [self performBlock:^{ 152 | completion(); 153 | } afterDelay:self.animationDuration]; 154 | } 155 | 156 | - (NSTimeInterval)calculateDelayForIndex:(NSUInteger)posIndex { 157 | //we "order" the delays for sort the animation in time 158 | float positionPercent = posIndex / ([self.orderMatrix.elements count]*1.0); 159 | //Random + Fix -> MAX 70% of TIME_ANIMATION 160 | float delay = [NSNumber getRandomFloat01]*self.animationDuration*0.4*positionPercent + self.animationDuration*0.3*positionPercent; 161 | 162 | return delay; 163 | } 164 | 165 | -(void)animateFromCellView:(UIView *)fromCell toCellView:(UIView *)toCell inTime:(NSTimeInterval)time { 166 | NSAssert(YES, @"This method has to be inherated in order to get some animation"); 167 | } 168 | 169 | - (void)finishAnimation { 170 | [self removeCellViews]; 171 | [self restoreSourceView]; 172 | self.completionBlock(); 173 | } 174 | 175 | #pragma mark - Auxiliar methods 176 | - (void) removeCellViews { 177 | for (UIImageView *currentView in self.fromGridCellViewArray) { 178 | [[currentView getEmbeddedView] removeFromSuperview]; 179 | [currentView removeFromSuperview]; 180 | } 181 | for (UIImageView *currentView in self.toGridCellViewArray) { 182 | [UIView animateWithDuration:0.1 animations:^{ 183 | [currentView setAlpha:0.0]; 184 | }completion:^(BOOL finished) { 185 | [[currentView getEmbeddedView] removeFromSuperview]; 186 | [currentView removeFromSuperview]; 187 | }]; 188 | } 189 | 190 | [self.fromGridCellViewArray removeAllObjects]; 191 | [self.toGridCellViewArray removeAllObjects]; 192 | } 193 | 194 | @end 195 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/PixelateNavigation/PixelateGridAnimator.h: -------------------------------------------------------------------------------- 1 | // 2 | // PixelateGridAnimator.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "GridBaseAnimator.h" 10 | 11 | @interface PixelateGridAnimator : GridBaseAnimator 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/PixelateNavigation/PixelateGridAnimator.m: -------------------------------------------------------------------------------- 1 | // 2 | // PixelateGridAnimator.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 28/02/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "PixelateGridAnimator.h" 10 | 11 | @implementation PixelateGridAnimator 12 | 13 | - (NSUInteger)rowsNumber { 14 | return 22; 15 | } 16 | 17 | - (NSUInteger)columnsNumber { 18 | return 32; 19 | } 20 | 21 | - (void)animateFromCellView:(UIView *)fromCell toCellView:(UIView *)toCell inTime:(NSTimeInterval)time { 22 | 23 | [toCell setAlpha:0.0]; 24 | [self.containerView addSubview:toCell]; 25 | 26 | [UIView animateWithDuration:time animations:^{ 27 | [fromCell setAlpha:0.0]; 28 | [toCell setAlpha:1.0]; 29 | }]; 30 | } 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/PixelateNavigation/PixelateNavigationController.h: -------------------------------------------------------------------------------- 1 | // 2 | // PixelateNavigationController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "BaseNavigationController.h" 11 | 12 | @interface PixelateNavigationController : BaseNavigationController 13 | 14 | @end 15 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/PixelateNavigation/PixelateNavigationController.m: -------------------------------------------------------------------------------- 1 | // 2 | // PixelateNavigationController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "PixelateNavigationController.h" 10 | #import "PixelateGridAnimator.h" 11 | 12 | @implementation PixelateNavigationController 13 | 14 | - (BaseControllerAnimatedTransitioningDelegate *)createAnimatedTransitioningUsed { 15 | PixelateGridAnimator *animator = [PixelateGridAnimator new]; 16 | [animator setSortMethod:ScanningSortMethodHorizontal]; 17 | return animator; 18 | } 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/SquaresFlipNavigation/FlipSquaresGridAnimator.h: -------------------------------------------------------------------------------- 1 | // 2 | // FlipSquaresGridAnimator.h 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 01/03/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "GridBaseAnimator.h" 10 | 11 | @interface FlipSquaresGridAnimator : GridBaseAnimator 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/SquaresFlipNavigation/FlipSquaresGridAnimator.m: -------------------------------------------------------------------------------- 1 | // 2 | // FlipSquaresGridAnimator.m 3 | // ABCustomUINavigationController 4 | // 5 | // Created by Andres Brun Moreno on 01/03/15. 6 | // Copyright (c) 2015 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "FlipSquaresGridAnimator.h" 10 | #import "UIView+ABExtras.h" 11 | 12 | @implementation FlipSquaresGridAnimator 13 | 14 | - (NSUInteger)columnsNumber { 15 | return 6; 16 | } 17 | 18 | - (NSUInteger)rowsNumber { 19 | return 5; 20 | } 21 | 22 | -(void)animateFromCellView:(UIView *)fromCell toCellView:(UIView *)toCell inTime:(NSTimeInterval)time { 23 | CAGradientLayer *fromGradient = [fromCell addLinearGradientWithColor:[UIColor blackColor] transparentToOpaque:YES]; 24 | CAGradientLayer *toGradient = [toCell addLinearGradientWithColor:[UIColor blackColor] transparentToOpaque:YES]; 25 | 26 | [self animateLighting:fromGradient darking:toGradient inTime:time]; 27 | 28 | [UIView transitionFromView:[fromCell getEmbeddedView] 29 | toView:[toCell getEmbeddedView] 30 | duration:time 31 | options:[self optionsFromFlip] 32 | completion:^(BOOL finished) { 33 | [fromGradient removeFromSuperlayer]; 34 | [toGradient removeFromSuperlayer]; 35 | }]; 36 | } 37 | 38 | - (void) animateLighting:(CAGradientLayer *)fromGradient darking:(CAGradientLayer *)toGradient inTime:(NSTimeInterval)time { 39 | [fromGradient setOpacity:1.0]; 40 | [toGradient setOpacity:0.0]; 41 | 42 | [UIView animateWithDuration:time animations:^{ 43 | [fromGradient setOpacity:0.0]; 44 | [toGradient setOpacity:1.0]; 45 | }]; 46 | } 47 | 48 | - (UIViewAnimationOptions) optionsFromFlip { 49 | if (self.presenting) { 50 | return UIViewAnimationOptionTransitionFlipFromLeft; 51 | } else { 52 | return UIViewAnimationOptionTransitionFlipFromRight; 53 | } 54 | } 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/SquaresFlipNavigation/FlipSquaresNavigationController.h: -------------------------------------------------------------------------------- 1 | // 2 | // FlipSquaresNavigationController.h 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "BaseNavigationController.h" 11 | 12 | @interface FlipSquaresNavigationController : BaseNavigationController 13 | 14 | @end 15 | -------------------------------------------------------------------------------- /CustomUINavigationController/NavigationClasses/GridBaseNavigation/SquaresFlipNavigation/FlipSquaresNavigationController.m: -------------------------------------------------------------------------------- 1 | // 2 | // FlipSquaresNavigationController.m 3 | // SquaresFlipNavigationExample 4 | // 5 | // Created by Andrés Brun on 7/14/13. 6 | // Copyright (c) 2013 Andrés Brun. All rights reserved. 7 | // 8 | 9 | #import "FlipSquaresNavigationController.h" 10 | #import "FlipSquaresGridAnimator.h" 11 | 12 | @implementation FlipSquaresNavigationController 13 | 14 | - (BaseControllerAnimatedTransitioningDelegate *)createAnimatedTransitioningUsed { 15 | FlipSquaresGridAnimator *animator = [FlipSquaresGridAnimator new]; 16 | [animator setSortMethod:ScanningSortMethodHorizontal]; 17 | return animator; 18 | } 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | Información de una película 2 | Nombre 3 | Fecha 4 | Escenas 5 | Autor + cita 6 | ImageLarge para mainscreen 7 | ImageMedium para tarjeta 8 | 9 | Frases 10 | Autor (Nombre + Images) 11 | Cita 12 | 13 | Escenas 14 | Imagen 15 | Descripcion 16 | 17 | Películas 18 | o Gladiator 19 | o Pulp Fiction 20 | o El Padrino 21 | o La chaqueta metálica 22 | Lo que el viento se llevó 23 | CasaBlanca 24 | La lista de shindler 25 | o Amelie 26 | Resorvoir Dog 27 | Pretty woman 28 | o American History X 29 | o El Silencio de los Corderos 30 | o El exorcista 31 | Saw I 32 | Dracula de Bran Stoker 33 | La Milla Verde 34 | o Snach, Cerdos y Diamantes 35 | o Watchmen 36 | o Matrix 37 | o StarWars 38 | 300 39 | Inception 40 | Terminator II 41 | Die Hard 42 | La Vida es Bella 43 | Men In Black 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ABCustomUINavigationController 2 | ===================== 3 | [![License MIT](https://go-shields.herokuapp.com/license-MIT-blue.png)](https://github.com/andresbrun/ABCustomUINavigationController/blob/master/LICENSE) 4 | [![Build Platform](https://cocoapod-badges.herokuapp.com/p/ABCustomUINavigationController/badge.png)](https://github.com/andresbrun/ABCustomUINavigationController) 5 | [![Build Version](https://cocoapod-badges.herokuapp.com/v/ABCustomUINavigationController/badge.png)](https://github.com/andresbrun/ABCustomUINavigationController) 6 | [![Build Status](https://travis-ci.org/andresbrun/ABCustomUINavigationController.png?branch=origin)](https://github.com/andresbrun/ABCustomUINavigationController) 7 | 8 | Subclass of UINavigationController for overwriting push and pop methods to create new transitions effects. Currently it has been implemented two transition animations: 9 | 10 | ### SquaresFlip 11 | The screen is split into squares and each one rotates until showing the new controller. It has two animation variations: 12 | - Randomly 13 | - Horizontally 14 | 15 | ### Pixelate 16 | The screen is split into pixels and each one fadeout displaying next view. It has two animation variations: 17 | - Randomly 18 | - Horizontally 19 | 20 | ### Cube effect 21 | The views are showns in differents cube's faces. It has two animation variation: 22 | - Horizontal 23 | - vertical 24 | 25 | ## Installation with CocoaPods 26 | 27 | [CocoaPods](http://cocoapods.org) is a dependency manager for Objective-C, which automates and simplifies the process of using 3rd-party libraries like ABCustomUINavigationController in your projects. 28 | 29 | #### Podfile 30 | 31 | ```ruby 32 | use_frameworks! 33 | pod "ABCustomUINavigationController" 34 | ``` 35 | 36 | ## Use 37 | For using that component you only have to copy the SquaresFlipNavigation folder into your project and create the navigation controller as: 38 | 39 | ```objective-c 40 | #import "FlipSquaresNavigationController.h" 41 | [[FlipSquaresNavigationController alloc] initWithRootViewController:self.viewController]; 42 | ``` 43 | 44 | ```swift 45 | import ABCustomUINavigationController 46 | let navigationController = FlipSquaresNavigationController(rootViewController: viewController) 47 | ``` 48 | 49 | or 50 | 51 | ```objective-c 52 | #import "CubeNavigationController.h" 53 | [[CubeNavigationController alloc] initWithRootViewController:self.viewController]; 54 | ``` 55 | 56 | ```swift 57 | import ABCustomUINavigationController 58 | let navigationController = CubeNavigationController(rootViewController: viewController) 59 | ``` 60 | 61 | and pushing and pop as usual using commons methods like: 62 | 63 | ```objective-c 64 | - (void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated 65 | - (UIViewController *)popViewControllerAnimated:(BOOL)animated 66 | - (NSArray *)popToRootViewControllerAnimated:(BOOL)animated 67 | - (NSArray *)popToViewController:(UIViewController *)viewController animated:(BOOL)animated 68 | ``` 69 | 70 | ## Features 71 | - Supports every screen size. iPhone and iPad. 72 | - Supports rotation. 73 | - Support status bar, navigation bar and navigation toolbar. 74 | 75 | ## Examples 76 | 77 | ### SquaresFlip 78 | ![alt tag](https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/master/example_images/example.gif) 79 | ### Cube 80 | ![alt tag](https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/master/example_images/example_cube.gif) 81 | 82 | -------------------------------------------------------------------------------- /example_images/example.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example.gif -------------------------------------------------------------------------------- /example_images/example.mov: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example.mov -------------------------------------------------------------------------------- /example_images/example_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_1.png -------------------------------------------------------------------------------- /example_images/example_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_2.png -------------------------------------------------------------------------------- /example_images/example_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_3.png -------------------------------------------------------------------------------- /example_images/example_4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_4.png -------------------------------------------------------------------------------- /example_images/example_5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_5.png -------------------------------------------------------------------------------- /example_images/example_6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_6.png -------------------------------------------------------------------------------- /example_images/example_cube.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_cube.gif -------------------------------------------------------------------------------- /example_images/example_cube_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_cube_1.png -------------------------------------------------------------------------------- /example_images/example_cube_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_cube_2.png -------------------------------------------------------------------------------- /example_images/example_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/andresbrun/ABCustomUINavigationController/1a4078e236fc41e657f6aa93e02f6941cfc7380d/example_images/example_full.png --------------------------------------------------------------------------------