├── .gitignore ├── CHANGELOG.md ├── LICENSE ├── README.md ├── TLYShyNavBar.podspec ├── TLYShyNavBar.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ └── contents.xcworkspacedata └── xcshareddata │ └── xcschemes │ └── TLYShyNavBar.xcscheme ├── TLYShyNavBar ├── Categories │ ├── NSObject+TLYSwizzlingHelpers.h │ ├── NSObject+TLYSwizzlingHelpers.m │ ├── TLYDelegateProxy.h │ ├── TLYDelegateProxy.m │ ├── UIScrollView+Helpers.h │ ├── UIScrollView+Helpers.m │ ├── UIViewController+BetterLayoutGuides.h │ └── UIViewController+BetterLayoutGuides.m ├── Info.plist ├── ShyControllers │ ├── TLYShyChild.h │ ├── TLYShyParent.h │ ├── TLYShyScrollViewController.h │ ├── TLYShyScrollViewController.m │ ├── TLYShyStatusBarController.h │ ├── TLYShyStatusBarController.m │ ├── TLYShyViewController.h │ └── TLYShyViewController.m ├── TLYShyNavBar.h ├── TLYShyNavBarFade.h ├── TLYShyNavBarManager.h └── TLYShyNavBarManager.m ├── TLYShyNavBarDemo ├── TLYShyNavBarDemo.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ └── TLYShyNavBarDemo.xccheckout ├── TLYShyNavBarDemo │ ├── Base.lproj │ │ └── Main.storyboard │ ├── Images.xcassets │ │ ├── AppIcon.appiconset │ │ │ └── Contents.json │ │ ├── LaunchImage.launchimage │ │ │ └── Contents.json │ │ └── sample.imageset │ │ │ ├── Contents.json │ │ │ └── sample@2x.png │ ├── LaunchScreen.storyboard │ ├── TLYAppDelegate.h │ ├── TLYAppDelegate.m │ ├── TLYCollectionViewController.h │ ├── TLYCollectionViewController.m │ ├── TLYMenuTableViewController.h │ ├── TLYMenuTableViewController.m │ ├── TLYPopoverSegue.h │ ├── TLYPopoverSegue.m │ ├── TLYShyNavBarDemo-Info.plist │ ├── TLYShyNavBarDemo-Prefix.pch │ ├── TLYTableViewController.h │ ├── TLYTableViewController.m │ ├── TLYViewController.h │ ├── TLYViewController.m │ ├── en.lproj │ │ └── InfoPlist.strings │ └── main.m └── TLYShyNavBarDemoTests │ ├── TLYShyNavBarDemoTests-Info.plist │ ├── TLYShyNavBarDemoTests.m │ └── en.lproj │ └── InfoPlist.strings ├── TLYShyNavBarSwiftDemo ├── Bridging-Header.h ├── TLYShyNavBarSwiftDemo.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ └── TLYShyNavBarSwiftDemo.xccheckout ├── TLYShyNavBarSwiftDemo │ ├── AppDelegate.swift │ ├── Base.lproj │ │ ├── LaunchScreen.xib │ │ └── Main.storyboard │ ├── Images.xcassets │ │ └── AppIcon.appiconset │ │ │ └── Contents.json │ ├── Info.plist │ └── TableViewController.swift └── TLYShyNavBarSwiftDemoTests │ ├── Info.plist │ └── TLYShyNavBarSwiftDemoTests.swift ├── TODO.md └── resources ├── basic-feature.gif ├── battle-tested-demo.gif ├── collectionView.gif ├── fade-navbar.gif ├── features-testing.png ├── fully-featured.gif ├── in-app-call.gif ├── no-extension.gif ├── opaque-supported.gif ├── robust.gif ├── sticky-extension.gif ├── sticky-navbar.gif └── tableview.gif /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # PYSCRIPT-XCODE-IGNORE-START 3 | 4 | ######################### 5 | # .gitignore file for Xcode4 / OS X Source projects 6 | # 7 | # Version 2.0 8 | # For latest version, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects 9 | # 10 | # 2013 updates: 11 | # - fixed the broken "save personal Schemes" 12 | # 13 | # NB: if you are storing "built" products, this WILL NOT WORK, 14 | # and you should use a different .gitignore (or none at all) 15 | # This file is for SOURCE projects, where there are many extra 16 | # files that we want to exclude 17 | # 18 | ######################### 19 | 20 | ##### 21 | # OS X temporary files that should never be committed 22 | 23 | .DS_Store 24 | *.swp 25 | *.lock 26 | profile 27 | 28 | 29 | #### 30 | # Xcode temporary files that should never be committed 31 | # 32 | # NB: NIB/XIB files still exist even on Storyboard projects, so we want this... 33 | 34 | *~.nib 35 | 36 | 37 | #### 38 | # Xcode build files - 39 | # 40 | # NB: slash on the end, so we only remove the FOLDER, not any files that were badly named "DerivedData" 41 | 42 | DerivedData/ 43 | 44 | # NB: slash on the end, so we only remove the FOLDER, not any files that were badly named "build" 45 | 46 | build/ 47 | 48 | 49 | ##### 50 | # Xcode private settings (window sizes, bookmarks, breakpoints, custom executables, smart groups) 51 | # 52 | # This is complicated: 53 | # 54 | # SOMETIMES you need to put this file in version control. 55 | # Apple designed it poorly - if you use "custom executables", they are 56 | # saved in this file. 57 | # 99% of projects do NOT use those, so they do NOT want to version control this file. 58 | # ..but if you're in the 1%, comment out the line "*.pbxuser" 59 | 60 | *.pbxuser 61 | *.mode1v3 62 | *.mode2v3 63 | *.perspectivev3 64 | # NB: also, whitelist the default ones, some projects need to use these 65 | !default.pbxuser 66 | !default.mode1v3 67 | !default.mode2v3 68 | !default.perspectivev3 69 | 70 | 71 | #### 72 | # Xcode 4 - semi-personal settings 73 | # 74 | # 75 | # OPTION 1: --------------------------------- 76 | # throw away ALL personal settings (including custom schemes! 77 | # - unless they are "shared") 78 | # 79 | # NB: this is exclusive with OPTION 2 below 80 | xcuserdata 81 | 82 | # OPTION 2: --------------------------------- 83 | # get rid of ALL personal settings, but KEEP SOME OF THEM 84 | # - NB: you must manually uncomment the bits you want to keep 85 | # 86 | # NB: this is exclusive with OPTION 1 above 87 | # 88 | #xcuserdata/**/* 89 | 90 | # (requires option 2 above): Personal Schemes 91 | # 92 | #!xcuserdata/**/xcschemes/* 93 | 94 | #### 95 | # XCode 4 workspaces - more detailed 96 | # 97 | # Workspaces are important! They are a core feature of Xcode - don't exclude them :) 98 | # 99 | # Workspace layout is quite spammy. For reference: 100 | # 101 | # /(root)/ 102 | # /(project-name).xcodeproj/ 103 | # project.pbxproj 104 | # /project.xcworkspace/ 105 | # contents.xcworkspacedata 106 | # /xcuserdata/ 107 | # /(your name)/xcuserdatad/ 108 | # UserInterfaceState.xcuserstate 109 | # /xcsshareddata/ 110 | # /xcschemes/ 111 | # (shared scheme name).xcscheme 112 | # /xcuserdata/ 113 | # /(your name)/xcuserdatad/ 114 | # (private scheme).xcscheme 115 | # xcschememanagement.plist 116 | # 117 | # 118 | 119 | #### 120 | # Xcode 4 - Deprecated classes 121 | # 122 | # Allegedly, if you manually "deprecate" your classes, they get moved here. 123 | # 124 | # We're using source-control, so this is a "feature" that we do not want! 125 | 126 | *.moved-aside 127 | 128 | 129 | #### 130 | # UNKNOWN: recommended by others, but I can't discover what these files are 131 | # 132 | # ...none. Everything is now explained. 133 | # PYSCRIPT-XCODE-IGNORE-END 134 | 135 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | 2 | # Retired 3 | 4 | Please see the github releases for release notes 5 | 6 | # Legacy 7 | 8 | ## v0.10.1 9 | 10 | #### Fixes 11 | 12 | + Hot fix an issue with UIViewControllers that have a UIScrollView subclass as their view property (i.e. collectionView, tableView, ...) that caused shyNavBar to be stubbornNavBar, refusing to contract. 13 | 14 | ## v0.10.0 15 | 16 | #### Enhancements 17 | 18 | + New approach to calculate extension and navigation bar offsets.
19 | Initially, we externally injected the calculation through blocks. The calculations depended on layout guide, and other weird stuff. The new approach simply calculates the offset based on the parent: status bar -> navigation bar -> extension view. 20 | 21 | + Added support for sticky navigation bar 22 | 23 | ## v0.9.15 24 | 25 | #### Enhancements 26 | 27 | + Added support for fading the entire navigation bar 28 | 29 | + Added modal support by checking navigation bar overlap with status bar 30 | 31 | + Added visual tests in the demo to see all the features in action 32 | 33 | #### Fixes 34 | 35 | + Fixed an issue with scrolling to top functionality 36 | 37 | #### Deprecations 38 | 39 | + Deprecated the fading booleans in favour of a new enum. 40 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Mazyad Alabduljaleel 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | ![TLYShyNavBar banner](http://imgur.com/UVxJLxu.png)
3 | __v1.0, Finally! With better code design, and fully featured!__ 4 | ----- 5 | 6 | ![Pod Version](https://img.shields.io/cocoapods/v/TLYShyNavBar.svg) 7 | ![Pod License](https://img.shields.io/badge/license-MIT-blue.svg) 8 | [![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) 9 | 10 | This component helps you mimic the navigation bar auto scrolling that you see in the Facebook, Instagram, 9gag (which uses this!) and other apps. Not only that, but with the ability to add an additional extension that scrolls along as well! It is designed for **ease of use**, and is battle tested in our own [Telly app](https://itunes.apple.com/us/app/telly/id524552885?mt=8)[1]! 11 | 12 | ![Battle Tested!!](resources/battle-tested-demo.gif) 13 | 14 | [1]: AppStore version doesn't have the latest, though. Coming soon. :grin:
15 | [*]: Content are shown for demo purpose only of how this component is used in the Telly app. We hold the right to show those contents as part of our contract with Sony Pictures. 16 | 17 | ## Outline 18 | 19 | + **[Features](#features)**: See what this component has to offer! 20 | + **[Quick Start](#quick-start)**: TL;DR people, you'll love this. 21 | + **[Design Goals](#design-goals)**: The cherished aspects of this component. 22 | + **[A Deeper Look](#a-deeper-look)**: You're invested in this now and want to make the most out of it. 23 | + **[How it Works](#how-it-works)**: The deep stuff... 24 | + **[FAQ](#faq)**: Read this before losing all hope. 25 | + **[Contributing](#contributing)**: Together, making iOS better. 26 | + **[Author](#author)**: Watashi-da! 27 | + **[Similar Projects](#similar-projects)**: Similar projects that influenced the project in some way. 28 | 29 | ## Features 30 | 31 | | Feature | Demo | 32 | |---|---| 33 | | Scroll a `UINavigationBar` with an extension view | ![](resources/basic-feature.gif) | 34 | | Support opaque and translucent `UINavigationBar`s | ![](resources/opaque-supported.gif) | 35 | | Fully featured, with animations and variable resistance | ![](resources/fully-featured.gif) | 36 | | Responsive, resilient and robust | ![](resources/robust.gif) | 37 | | Supports `UITableView`, with headers, too! | ![](resources/tableview.gif) | 38 | | `UICollectionView` is more than welcome | ![](resources/collectionView.gif) | 39 | | In-call status bar? No problem! | ![](resources/in-app-call.gif) | 40 | | Sticky extension view (Thanks @yukaliao !) | ![](resources/sticky-extension.gif) | 41 | | Sticky navigation bar (Thanks [@TiagoVeloso](https://github.com/beloso)!) | ![](resources/sticky-navbar.gif) | 42 | | Fade the entire navbar (Thanks [__@longsview__](https://github.com/longsview)!) | ![](resources/fade-navbar.gif) | 43 | 44 | You can test some of these features in the Objective-C demo: 45 | 46 | ![](resources/features-testing.png) 47 | 48 | ## Quick Start 49 | 50 | 1. Get the component 51 | + Using [CocoaPods](http://cocoapods.org):
52 | Add the following to you [Podfile](http://guides.cocoapods.org/using/the-podfile.html) `pod 'TLYShyNavBar'`
53 | Import the header `#import ` 54 | 55 | + Using [Carthage](https://github.com/Carthage/Carthage) (Thanks [@bradleyayers](https://github.com/bradleyayers)!):
56 | Add the following to your [Cartfile](https://github.com/Carthage/Carthage/blob/master/Documentation/Artifacts.md) `github "telly/TLYShyNavBar"`
57 | Import the header `#import ` 58 | 59 | + Using Submodules:
60 | Download the project/git submodules, and drag the `TLYShyNavBar` folder to your project.
61 | Import the header `#import "TLYShyNavBarManager.h"` 62 | 63 | 2. Write one line of code to get started!! 64 | 65 | ```objc 66 | /* In your UIViewController viewDidLoad or after creating the scroll view. */ 67 | self.shyNavBarManager.scrollView = self.scrollView; 68 | ``` 69 | 70 | **IMPORTANT NOTES!!** 71 | 72 | 1. Don't use with `UITableViewController`. Add a `UITableView` as a subview of `UIViewController` instead. 73 | 2. If you are assigning a delegate to your scrollView, do that **before** assigning the scrollView to the `TLYShyNavBarManager`! To learn more, [see below](#how-it-works). 74 | 75 | ### Using TLYShyNavBar in Swift 76 | 77 | Nothing special is needed, really. Just make sure you have a [Bridging Header](http://stackoverflow.com/questions/31716413/xcode-not-automatically-creating-bridging-header) setup, and import: 78 | 79 | ```objc 80 | #import "TLYShyNavBarManager.h" 81 | ``` 82 | 83 | Then, you should be able to follow the Objective-C instructions, since the code is almost identical. 84 | 85 | ## Design Goals 86 | 87 | + **Ease of Use**: This is the most important, and should never be compromised. Even if compatability breaks or versatility is limited, the component should remain easy to integrate. 88 | + **Portable**: Less dependencies, lightweight, self-contained, ... etc. 89 | + **Compatability**: Whenever possible, the component should simply work with whatever you throw at it. 90 | 91 | ## A Deeper Look 92 | 93 | The above example, while small, is complete! It makes the navigation bar enriched with humility, that it will start getting out of the way when the scroll view starts scrolling. But, you may want to do more than that! 94 | 95 | #### ACCESS THE MANAGER OF SHYNESS 96 | 97 | Simply access it within your `UIViewController` subclass as a property. The property is lazy loaded for you, so you don't have to instantiate anything: 98 | 99 | ```objc 100 | self.shyNavBarManager 101 | ``` 102 | 103 | #### ADDING AN EXTENSION VIEW 104 | 105 | You can assign your own extension view, and it will appear right beneath the navigation bar. It will slide beneath the navigation bar, before the navigation bar starts shrinking (contracting). Adding an extension view is as simple as: 106 | 107 | ```objc 108 | /* Also in your UIViewController subclass */ 109 | [self.shyNavBarManager setExtensionView:self.toolbar]; 110 | ``` 111 | 112 | To stick the extension view to the top and have it remain visible when the navigation bar has been hidden: 113 | 114 | ```objc 115 | /* Also in your UIViewController subclass */ 116 | [self.shyNavBarManager setStickyExtensionView:YES]; 117 | ``` 118 | 119 | #### CONTROLLING THE RESISTANCE 120 | 121 | When you starting scrolling up (going down the view) or scrolling down (going up the view), you may want the navigation bar to hold off for a certain amount (tolerance) before changing states. (i.e. if the user scrolls down 10 px, don't immediately start showing the contracted navigation bar, but wait till he scrolls, say, 100 px). 122 | 123 | You can control that using the following properties on the `shyNavBarManager`: 124 | 125 | ```objc 126 | /* Control the resistance when scrolling up/down before the navbar 127 | * expands/contracts again. 128 | */ 129 | @property (nonatomic) CGFloat expansionResistance; // default 200 130 | @property (nonatomic) CGFloat contractionResistance; // default 0 131 | ``` 132 | 133 | #### CONTROLLING THE FADE BEHAVIOR 134 | 135 | You can customize the fade behavior of the `UINavigationBar` through this property: 136 | 137 | ```objc 138 | /* Choose how the navbar fades as it contracts/expands. 139 | * Defaults to FadeSubviews 140 | */ 141 | @property (nonatomic) TLYShyNavBarFade fadeBehavior; 142 | ``` 143 | 144 | ## How it Works 145 | 146 | OK, I'll admit that I added this section purely to rant about how this project came together, and the decision making process behind it. 147 | 148 | #### THE BASICS 149 | 150 | At a component-user level, this works by adding a category to `UIViewController` with a `TLYShyNavBarManager` property. The property is lazily loaded, to cut any unnecessary overhead, and lower the barrier of entry. From the property, you can start customizing the `TLYShyNavBarManager` for that view controller. 151 | 152 | Now, you may start asking, what about the navigation bar? Well, the navigation bar is accessed from the view controller your using the manager in. Let's break that down... 153 | 154 | 1. When you access the `shyNavBarManager` for the first time, it is created with the `self` parameter passed to it, effectively binding the `shyNavBarManager` to the `UIViewController`. 155 | 2. The `shyNavBarManager` accesses the `UINavigationBar` through the assigned `UIViewController`. 156 | 157 | ... And that is how the basic setup is done! 158 | 159 | #### THE EXTENSION VIEW 160 | 161 | When you call `setExtensionView:`, it simply resizes an internal container view, and adds your extension view to it. There is no magic here, just simple, single view extension. 162 | 163 | #### CAPTURING SCROLL VIEW EVENTS 164 | 165 | This one was a pain... First, the experiments that this project went through included: 166 | 167 | + Observing the contentOffset property 168 | + Adding self as a `UIGestureRecognizer` target 169 | + Adding a `UIPanGestureRecognizer` to the scroll view. 170 | + Make the user implement `UIScrollViewDelegate`, and send us the events. 171 | 172 | The above didn't yield the perfect experience we were hoping for, except the last one. It did, however, make for redundant code everywhere, and forced the component user to implement the `UIScrollViewDelegate`. That's when the `NSProxy` happened. 173 | 174 | When you assign the `scrollView` property to the TLYShyNavBarManager, we attach a proxy object to the `UIScrollView` as the delegate, and then the original delegate to that proxy. The proxy forwards the events we are interested in to the `TLYShyNavBarManager`, and of course, does everything else normally for the original selector, you won't even notice a thing! 175 | 176 | #### THE DRAWER CONCEPT 177 | 178 | The way the offsets are applied to the navigation bar and extension view is through an elegant doubly linked list implementation. We set the offset to the first node (navigation bar), and ... 179 | 180 | + If it is contracting: 181 | - We pass the contraction amount to the next node, and it returns a residual amount. 182 | 183 | + If we are expanding: 184 | - We process the offset in the first node, and pass the residual to the next node. 185 | 186 | It is a simple concept. Say we dragged down by 100 px while the navbar was contracted. The navigation bar would take 44 px of that to expand, and then pass the residual 56 px to the next node (extension view) to calculate its offset. The same goes for contracting, but it starts from the last node, all the way up to the navigation bar. 187 | 188 | We also add a parent relationship for a single purpose: Make the child follow its parent's offset. So, if the parent (e.g. navigation bar) is scrolling away to the top, we make sure the child accommodates the parent's offset in the calculation, so it appears as if the child is a subview of the parent. 189 | 190 | *Note:* Even though there might be an illusion that the views are expanding and contracting, it's really just a translation (scrolling) of the views. There might be an advantage to actually resizing the bounds, so the extension view doesn't appear behind the navigation bar, for example, so that approach might be explored in the future. 191 | 192 | ## FAQ 193 | 194 | #### Opaque Navbar Shows Black Bar When Scrolled Up 195 | 196 | You have to check the «Extend Edges» Under Opaque Bars in the View Controller configuration. Credit for this solution goes to @tiois. 197 | 198 | #### I get an exception saying: "Please make sure the viewController is already attached to a navigation controller" 199 | 200 | There are downsides in making this component as easy to use as it is. If you have read the how it works section carefully, you'd realize that trying to configure the the `shyNavBarManager` before it is included in the `UINavigationController` hierarchy, will break the component, since within the component, we cannot find the navigation bar, and an assert is triggered: 201 | 202 | ```objc 203 | NSAssert(navbar != nil, @"Please make sure the viewController is already attached to a navigation controller."); 204 | ``` 205 | 206 | Of course, that can be avoided by creating your own `TLYShyNavBarManager`, like so: 207 | 208 | ```objc 209 | TLYShyNavBarManager *shyManager = [TLYShyNavBarManager new]; 210 | shyManager.expansionResistance = 777.f; 211 | 212 | /* ... sometime after the view controller is added to the hierarchy */ 213 | viewController.shyNavBarManager = shyManager; 214 | ``` 215 | 216 | ## Contributing 217 | 218 | PRs are welcome! It is important to test changes, though. Simply go over the demo, make sure nothing is broken. Please do check both translucent and opaque modes. Once all is good, you're good to go! 219 | 220 | If it is a feature or bug, it would be greatly appreciated if a new view is added to the demo project demonstrating the bug/feature. 221 | 222 | Thanks for everyone who opened an issue, shot me an email, and submitted a PR. Special thanks to those who submitted code that got checked in! This project was made possible with your help. ([See contributors graph](https://github.com/telly/TLYShyNavBar/graphs/contributors)) 223 | 224 | ## Author 225 | 226 | Mazyod ([@Mazyod](http://twitter.com/mazyod)) 227 | 228 | ## Similar Projects 229 | 230 | + [BLKFlexibleHeightBar](https://github.com/bryankeller/BLKFlexibleHeightBar) 231 | + [AMScrollingNavbar](https://github.com/andreamazz/AMScrollingNavbar) 232 | + [GTScrollNavigationBar](https://github.com/luugiathuy/GTScrollNavigationBar) 233 | + [JKAutoShrinkView](https://github.com/fsjack/JKAutoShrinkView) 234 | + [SherginScrollableNavigationBar](https://github.com/shergin/SherginScrollableNavigationBar) 235 | -------------------------------------------------------------------------------- /TLYShyNavBar.podspec: -------------------------------------------------------------------------------- 1 | # 2 | # Be sure to run `pod spec lint TLYShyNavBar.podspec' to ensure this is a 3 | # valid spec and to remove all comments including this before submitting the spec. 4 | # 5 | # To learn more about Podspec attributes see http://docs.cocoapods.org/specification.html 6 | # To see working Podspecs in the CocoaPods repo see https://github.com/CocoaPods/Specs/ 7 | # 8 | 9 | Pod::Spec.new do |s| 10 | 11 | # ――― Spec Metadata ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 12 | # 13 | # These will help people to find your library, and whilst it 14 | # can feel like a chore to fill in it's definitely to your advantage. The 15 | # summary should be tweet-length, and the description more in depth. 16 | # 17 | 18 | s.name = "TLYShyNavBar" 19 | s.version = "1.1.1" 20 | s.summary = "TLYShyNavBar makes your UINavigationBar expand/shrink by adding just a single line. It also comes with extension view support!" 21 | 22 | s.description = <<-DESC 23 | # Purpose 24 | 25 | The purpose of writing this was to provide a super simple way to add the expansion/contraction UINavigationBar functionality, like the one found in facebook and instagram. 26 | 27 | It literally takes a single liner to get started and have your navigation bar expand/shrink based on the UIScrollView subclass that you attach to the designated object. 28 | 29 | In addition to the support for UINavigationBar, it also allows you to assign an extension view that will be managed for you, and that extension view is shown right below the navigation bar, and will expand/contract as well! 30 | 31 | The component has been carefully written, battle tested, and has more fine grain customization, like the tolerance range you want to hold off the expansion/contraction before applying the effect. 32 | 33 | Please read all about this component in the [github repo readme file](https://github.com/telly/TLYShyNavBar/blob/master/README.md). 34 | 35 | DESC 36 | 37 | s.homepage = "https://github.com/telly/TLYShyNavBar" 38 | s.screenshots = "http://imgur.com/dv1LK1v.png" 39 | 40 | 41 | # ――― Spec License ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 42 | # 43 | # Licensing your code is important. See http://choosealicense.com for more info. 44 | # CocoaPods will detect a license file if there is a named LICENSE* 45 | # Popular ones are 'MIT', 'BSD' and 'Apache License, Version 2.0'. 46 | # 47 | 48 | s.license = "MIT" 49 | s.license = { :type => 'MIT', :file => 'LICENSE' } 50 | 51 | 52 | # ――― Author Metadata ――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 53 | # 54 | # Specify the authors of the library, with email addresses. Email addresses 55 | # of the authors are extracted from the SCM log. E.g. $ git log. CocoaPods also 56 | # accepts just a name if you'd rather not provide an email address. 57 | # 58 | # Specify a social_media_url where others can refer to, for example a twitter 59 | # profile URL. 60 | # 61 | 62 | s.author = { "Mazyad Alabduljaleel" => "mazjaleel@gmail.com" } 63 | s.social_media_url = "http://twitter.com/Mazyod" 64 | 65 | # ――― Platform Specifics ――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 66 | # 67 | # If this Pod runs only on iOS or OS X, then specify the platform and 68 | # the deployment target. You can optionally include the target after the platform. 69 | # 70 | 71 | s.platform = :ios, "7.0" 72 | 73 | # When using multiple platforms 74 | # s.ios.deployment_target = "5.0" 75 | # s.osx.deployment_target = "10.7" 76 | 77 | 78 | # ――― Source Location ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 79 | # 80 | # Specify the location from where the source should be retrieved. 81 | # Supports git, hg, bzr, svn and HTTP. 82 | # 83 | 84 | s.source = { :git => "https://github.com/telly/TLYShyNavBar.git", :tag => "1.1.1" } 85 | 86 | 87 | # ――― Source Code ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 88 | # 89 | # CocoaPods is smart about how it includes source code. For source files 90 | # giving a folder will include any h, m, mm, c & cpp files. For header 91 | # files it will include any header in the folder. 92 | # Not including the public_header_files will make all headers public. 93 | # 94 | 95 | s.source_files = "TLYShyNavBar/**/*" 96 | s.exclude_files = "TLYShyNavBar/Info.plist" 97 | 98 | s.public_header_files = "TLYShyNavBar/*.h" 99 | 100 | 101 | # ――― Resources ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 102 | # 103 | # A list of resources included with the Pod. These are copied into the 104 | # target bundle with a build phase script. Anything else will be cleaned. 105 | # You can preserve files from being cleaned, please don't preserve 106 | # non-essential files like tests, examples and documentation. 107 | # 108 | 109 | # s.resource = "icon.png" 110 | # s.resources = "Resources/*.png" 111 | 112 | # s.preserve_paths = "FilesToSave", "MoreFilesToSave" 113 | 114 | 115 | # ――― Project Linking ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 116 | # 117 | # Link your library with frameworks, or libraries. Libraries do not include 118 | # the lib prefix of their name. 119 | # 120 | 121 | # ――― Project Settings ――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # 122 | # 123 | # If your library depends on compiler flags you can set them in the xcconfig hash 124 | # where they will only apply to your library. If you depend on other Podspecs 125 | # you can include multiple dependencies to ensure it works. 126 | 127 | s.requires_arc = true 128 | 129 | end 130 | -------------------------------------------------------------------------------- /TLYShyNavBar.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | A21B00001BFDD41100F9FB54 /* TLYShyScrollViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFF81BFDD41100F9FB54 /* TLYShyScrollViewController.m */; }; 11 | A21B00011BFDD41100F9FB54 /* TLYShyStatusBarController.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFF91BFDD41100F9FB54 /* TLYShyStatusBarController.h */; }; 12 | A21B00021BFDD41100F9FB54 /* TLYShyStatusBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFFA1BFDD41100F9FB54 /* TLYShyStatusBarController.m */; }; 13 | A21B00031BFDD41100F9FB54 /* TLYShyViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFFB1BFDD41100F9FB54 /* TLYShyViewController.h */; }; 14 | A21B00041BFDD41100F9FB54 /* TLYShyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFFC1BFDD41100F9FB54 /* TLYShyViewController.m */; }; 15 | A21B00081BFDD41900F9FB54 /* TLYShyNavBarFade.h in Headers */ = {isa = PBXBuildFile; fileRef = A21B00051BFDD41900F9FB54 /* TLYShyNavBarFade.h */; settings = {ATTRIBUTES = (Public, ); }; }; 16 | A21B00091BFDD41900F9FB54 /* TLYShyNavBarManager.h in Headers */ = {isa = PBXBuildFile; fileRef = A21B00061BFDD41900F9FB54 /* TLYShyNavBarManager.h */; settings = {ATTRIBUTES = (Public, ); }; }; 17 | A21B000A1BFDD41900F9FB54 /* TLYShyNavBarManager.m in Sources */ = {isa = PBXBuildFile; fileRef = A21B00071BFDD41900F9FB54 /* TLYShyNavBarManager.m */; }; 18 | A21BFFA71BFDCC8800F9FB54 /* TLYShyNavBar.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFA61BFDCC8800F9FB54 /* TLYShyNavBar.h */; settings = {ATTRIBUTES = (Public, ); }; }; 19 | A21BFFED1BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFE51BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.h */; }; 20 | A21BFFEE1BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFE61BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.m */; }; 21 | A21BFFEF1BFDD40800F9FB54 /* TLYDelegateProxy.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFE71BFDD40800F9FB54 /* TLYDelegateProxy.h */; }; 22 | A21BFFF01BFDD40800F9FB54 /* TLYDelegateProxy.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFE81BFDD40800F9FB54 /* TLYDelegateProxy.m */; }; 23 | A21BFFF11BFDD40800F9FB54 /* UIScrollView+Helpers.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFE91BFDD40800F9FB54 /* UIScrollView+Helpers.h */; }; 24 | A21BFFF21BFDD40800F9FB54 /* UIScrollView+Helpers.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFEA1BFDD40800F9FB54 /* UIScrollView+Helpers.m */; }; 25 | A21BFFF31BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFEB1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.h */; }; 26 | A21BFFF41BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.m in Sources */ = {isa = PBXBuildFile; fileRef = A21BFFEC1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.m */; }; 27 | A21BFFFD1BFDD41100F9FB54 /* TLYShyChild.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFF51BFDD41100F9FB54 /* TLYShyChild.h */; }; 28 | A21BFFFE1BFDD41100F9FB54 /* TLYShyParent.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFF61BFDD41100F9FB54 /* TLYShyParent.h */; }; 29 | A21BFFFF1BFDD41100F9FB54 /* TLYShyScrollViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = A21BFFF71BFDD41100F9FB54 /* TLYShyScrollViewController.h */; }; 30 | /* End PBXBuildFile section */ 31 | 32 | /* Begin PBXFileReference section */ 33 | A21B00051BFDD41900F9FB54 /* TLYShyNavBarFade.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarFade.h; sourceTree = ""; }; 34 | A21B00061BFDD41900F9FB54 /* TLYShyNavBarManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarManager.h; sourceTree = ""; }; 35 | A21B00071BFDD41900F9FB54 /* TLYShyNavBarManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyNavBarManager.m; sourceTree = ""; }; 36 | A21BFFA41BFDCC8800F9FB54 /* TLYShyNavBar.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = TLYShyNavBar.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 37 | A21BFFA61BFDCC8800F9FB54 /* TLYShyNavBar.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBar.h; sourceTree = ""; }; 38 | A21BFFA81BFDCC8800F9FB54 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 39 | A21BFFE51BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSObject+TLYSwizzlingHelpers.h"; path = "Categories/NSObject+TLYSwizzlingHelpers.h"; sourceTree = ""; }; 40 | A21BFFE61BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSObject+TLYSwizzlingHelpers.m"; path = "Categories/NSObject+TLYSwizzlingHelpers.m"; sourceTree = ""; }; 41 | A21BFFE71BFDD40800F9FB54 /* TLYDelegateProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYDelegateProxy.h; path = Categories/TLYDelegateProxy.h; sourceTree = ""; }; 42 | A21BFFE81BFDD40800F9FB54 /* TLYDelegateProxy.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TLYDelegateProxy.m; path = Categories/TLYDelegateProxy.m; sourceTree = ""; }; 43 | A21BFFE91BFDD40800F9FB54 /* UIScrollView+Helpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "UIScrollView+Helpers.h"; path = "Categories/UIScrollView+Helpers.h"; sourceTree = ""; }; 44 | A21BFFEA1BFDD40800F9FB54 /* UIScrollView+Helpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "UIScrollView+Helpers.m"; path = "Categories/UIScrollView+Helpers.m"; sourceTree = ""; }; 45 | A21BFFEB1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "UIViewController+BetterLayoutGuides.h"; path = "Categories/UIViewController+BetterLayoutGuides.h"; sourceTree = ""; }; 46 | A21BFFEC1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "UIViewController+BetterLayoutGuides.m"; path = "Categories/UIViewController+BetterLayoutGuides.m"; sourceTree = ""; }; 47 | A21BFFF51BFDD41100F9FB54 /* TLYShyChild.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYShyChild.h; path = ShyControllers/TLYShyChild.h; sourceTree = ""; }; 48 | A21BFFF61BFDD41100F9FB54 /* TLYShyParent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYShyParent.h; path = ShyControllers/TLYShyParent.h; sourceTree = ""; }; 49 | A21BFFF71BFDD41100F9FB54 /* TLYShyScrollViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYShyScrollViewController.h; path = ShyControllers/TLYShyScrollViewController.h; sourceTree = ""; }; 50 | A21BFFF81BFDD41100F9FB54 /* TLYShyScrollViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TLYShyScrollViewController.m; path = ShyControllers/TLYShyScrollViewController.m; sourceTree = ""; }; 51 | A21BFFF91BFDD41100F9FB54 /* TLYShyStatusBarController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYShyStatusBarController.h; path = ShyControllers/TLYShyStatusBarController.h; sourceTree = ""; }; 52 | A21BFFFA1BFDD41100F9FB54 /* TLYShyStatusBarController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TLYShyStatusBarController.m; path = ShyControllers/TLYShyStatusBarController.m; sourceTree = ""; }; 53 | A21BFFFB1BFDD41100F9FB54 /* TLYShyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TLYShyViewController.h; path = ShyControllers/TLYShyViewController.h; sourceTree = ""; }; 54 | A21BFFFC1BFDD41100F9FB54 /* TLYShyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TLYShyViewController.m; path = ShyControllers/TLYShyViewController.m; sourceTree = ""; }; 55 | /* End PBXFileReference section */ 56 | 57 | /* Begin PBXFrameworksBuildPhase section */ 58 | A21BFFA01BFDCC8800F9FB54 /* Frameworks */ = { 59 | isa = PBXFrameworksBuildPhase; 60 | buildActionMask = 2147483647; 61 | files = ( 62 | ); 63 | runOnlyForDeploymentPostprocessing = 0; 64 | }; 65 | /* End PBXFrameworksBuildPhase section */ 66 | 67 | /* Begin PBXGroup section */ 68 | A21BFF711BFDCB3E00F9FB54 = { 69 | isa = PBXGroup; 70 | children = ( 71 | A21BFFAC1BFDCCE000F9FB54 /* Products */, 72 | A21BFFA51BFDCC8800F9FB54 /* TLYShyNavBar */, 73 | ); 74 | sourceTree = ""; 75 | }; 76 | A21BFFA51BFDCC8800F9FB54 /* TLYShyNavBar */ = { 77 | isa = PBXGroup; 78 | children = ( 79 | A21B00051BFDD41900F9FB54 /* TLYShyNavBarFade.h */, 80 | A21B00061BFDD41900F9FB54 /* TLYShyNavBarManager.h */, 81 | A21B00071BFDD41900F9FB54 /* TLYShyNavBarManager.m */, 82 | A21BFFDE1BFDD1A500F9FB54 /* Categories */, 83 | A21BFFCD1BFDD18D00F9FB54 /* ShyControllers */, 84 | A21BFFA61BFDCC8800F9FB54 /* TLYShyNavBar.h */, 85 | A21BFFAD1BFDCD5100F9FB54 /* Supporting Files */, 86 | ); 87 | path = TLYShyNavBar; 88 | sourceTree = ""; 89 | }; 90 | A21BFFAC1BFDCCE000F9FB54 /* Products */ = { 91 | isa = PBXGroup; 92 | children = ( 93 | A21BFFA41BFDCC8800F9FB54 /* TLYShyNavBar.framework */, 94 | ); 95 | name = Products; 96 | sourceTree = ""; 97 | }; 98 | A21BFFAD1BFDCD5100F9FB54 /* Supporting Files */ = { 99 | isa = PBXGroup; 100 | children = ( 101 | A21BFFA81BFDCC8800F9FB54 /* Info.plist */, 102 | ); 103 | name = "Supporting Files"; 104 | sourceTree = ""; 105 | }; 106 | A21BFFCD1BFDD18D00F9FB54 /* ShyControllers */ = { 107 | isa = PBXGroup; 108 | children = ( 109 | A21BFFF51BFDD41100F9FB54 /* TLYShyChild.h */, 110 | A21BFFF61BFDD41100F9FB54 /* TLYShyParent.h */, 111 | A21BFFF71BFDD41100F9FB54 /* TLYShyScrollViewController.h */, 112 | A21BFFF81BFDD41100F9FB54 /* TLYShyScrollViewController.m */, 113 | A21BFFF91BFDD41100F9FB54 /* TLYShyStatusBarController.h */, 114 | A21BFFFA1BFDD41100F9FB54 /* TLYShyStatusBarController.m */, 115 | A21BFFFB1BFDD41100F9FB54 /* TLYShyViewController.h */, 116 | A21BFFFC1BFDD41100F9FB54 /* TLYShyViewController.m */, 117 | ); 118 | name = ShyControllers; 119 | sourceTree = ""; 120 | }; 121 | A21BFFDE1BFDD1A500F9FB54 /* Categories */ = { 122 | isa = PBXGroup; 123 | children = ( 124 | A21BFFE51BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.h */, 125 | A21BFFE61BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.m */, 126 | A21BFFE71BFDD40800F9FB54 /* TLYDelegateProxy.h */, 127 | A21BFFE81BFDD40800F9FB54 /* TLYDelegateProxy.m */, 128 | A21BFFE91BFDD40800F9FB54 /* UIScrollView+Helpers.h */, 129 | A21BFFEA1BFDD40800F9FB54 /* UIScrollView+Helpers.m */, 130 | A21BFFEB1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.h */, 131 | A21BFFEC1BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.m */, 132 | ); 133 | name = Categories; 134 | sourceTree = ""; 135 | }; 136 | /* End PBXGroup section */ 137 | 138 | /* Begin PBXHeadersBuildPhase section */ 139 | A21BFFA11BFDCC8800F9FB54 /* Headers */ = { 140 | isa = PBXHeadersBuildPhase; 141 | buildActionMask = 2147483647; 142 | files = ( 143 | A21BFFED1BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.h in Headers */, 144 | A21B00091BFDD41900F9FB54 /* TLYShyNavBarManager.h in Headers */, 145 | A21B00081BFDD41900F9FB54 /* TLYShyNavBarFade.h in Headers */, 146 | A21B00011BFDD41100F9FB54 /* TLYShyStatusBarController.h in Headers */, 147 | A21BFFF31BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.h in Headers */, 148 | A21BFFFD1BFDD41100F9FB54 /* TLYShyChild.h in Headers */, 149 | A21BFFEF1BFDD40800F9FB54 /* TLYDelegateProxy.h in Headers */, 150 | A21BFFF11BFDD40800F9FB54 /* UIScrollView+Helpers.h in Headers */, 151 | A21B00031BFDD41100F9FB54 /* TLYShyViewController.h in Headers */, 152 | A21BFFFF1BFDD41100F9FB54 /* TLYShyScrollViewController.h in Headers */, 153 | A21BFFA71BFDCC8800F9FB54 /* TLYShyNavBar.h in Headers */, 154 | A21BFFFE1BFDD41100F9FB54 /* TLYShyParent.h in Headers */, 155 | ); 156 | runOnlyForDeploymentPostprocessing = 0; 157 | }; 158 | /* End PBXHeadersBuildPhase section */ 159 | 160 | /* Begin PBXNativeTarget section */ 161 | A21BFFA31BFDCC8800F9FB54 /* TLYShyNavBar */ = { 162 | isa = PBXNativeTarget; 163 | buildConfigurationList = A21BFFA91BFDCC8800F9FB54 /* Build configuration list for PBXNativeTarget "TLYShyNavBar" */; 164 | buildPhases = ( 165 | A21BFF9F1BFDCC8800F9FB54 /* Sources */, 166 | A21BFFA01BFDCC8800F9FB54 /* Frameworks */, 167 | A21BFFA11BFDCC8800F9FB54 /* Headers */, 168 | A21BFFA21BFDCC8800F9FB54 /* Resources */, 169 | ); 170 | buildRules = ( 171 | ); 172 | dependencies = ( 173 | ); 174 | name = TLYShyNavBar; 175 | productName = TLYShyNavBar; 176 | productReference = A21BFFA41BFDCC8800F9FB54 /* TLYShyNavBar.framework */; 177 | productType = "com.apple.product-type.framework"; 178 | }; 179 | /* End PBXNativeTarget section */ 180 | 181 | /* Begin PBXProject section */ 182 | A21BFF721BFDCB3E00F9FB54 /* Project object */ = { 183 | isa = PBXProject; 184 | attributes = { 185 | LastUpgradeCheck = 0710; 186 | TargetAttributes = { 187 | A21BFFA31BFDCC8800F9FB54 = { 188 | CreatedOnToolsVersion = 7.1.1; 189 | }; 190 | }; 191 | }; 192 | buildConfigurationList = A21BFF751BFDCB3E00F9FB54 /* Build configuration list for PBXProject "TLYShyNavBar" */; 193 | compatibilityVersion = "Xcode 3.2"; 194 | developmentRegion = English; 195 | hasScannedForEncodings = 0; 196 | knownRegions = ( 197 | en, 198 | ); 199 | mainGroup = A21BFF711BFDCB3E00F9FB54; 200 | productRefGroup = A21BFF711BFDCB3E00F9FB54; 201 | projectDirPath = ""; 202 | projectRoot = ""; 203 | targets = ( 204 | A21BFFA31BFDCC8800F9FB54 /* TLYShyNavBar */, 205 | ); 206 | }; 207 | /* End PBXProject section */ 208 | 209 | /* Begin PBXResourcesBuildPhase section */ 210 | A21BFFA21BFDCC8800F9FB54 /* Resources */ = { 211 | isa = PBXResourcesBuildPhase; 212 | buildActionMask = 2147483647; 213 | files = ( 214 | ); 215 | runOnlyForDeploymentPostprocessing = 0; 216 | }; 217 | /* End PBXResourcesBuildPhase section */ 218 | 219 | /* Begin PBXSourcesBuildPhase section */ 220 | A21BFF9F1BFDCC8800F9FB54 /* Sources */ = { 221 | isa = PBXSourcesBuildPhase; 222 | buildActionMask = 2147483647; 223 | files = ( 224 | A21B00041BFDD41100F9FB54 /* TLYShyViewController.m in Sources */, 225 | A21BFFF21BFDD40800F9FB54 /* UIScrollView+Helpers.m in Sources */, 226 | A21B000A1BFDD41900F9FB54 /* TLYShyNavBarManager.m in Sources */, 227 | A21BFFF41BFDD40800F9FB54 /* UIViewController+BetterLayoutGuides.m in Sources */, 228 | A21BFFEE1BFDD40800F9FB54 /* NSObject+TLYSwizzlingHelpers.m in Sources */, 229 | A21BFFF01BFDD40800F9FB54 /* TLYDelegateProxy.m in Sources */, 230 | A21B00021BFDD41100F9FB54 /* TLYShyStatusBarController.m in Sources */, 231 | A21B00001BFDD41100F9FB54 /* TLYShyScrollViewController.m in Sources */, 232 | ); 233 | runOnlyForDeploymentPostprocessing = 0; 234 | }; 235 | /* End PBXSourcesBuildPhase section */ 236 | 237 | /* Begin XCBuildConfiguration section */ 238 | A21BFF8D1BFDCB3E00F9FB54 /* Debug */ = { 239 | isa = XCBuildConfiguration; 240 | buildSettings = { 241 | ALWAYS_SEARCH_USER_PATHS = NO; 242 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 243 | CLANG_CXX_LIBRARY = "libc++"; 244 | CLANG_ENABLE_MODULES = YES; 245 | CLANG_ENABLE_OBJC_ARC = YES; 246 | CLANG_WARN_BOOL_CONVERSION = YES; 247 | CLANG_WARN_CONSTANT_CONVERSION = YES; 248 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 249 | CLANG_WARN_EMPTY_BODY = YES; 250 | CLANG_WARN_ENUM_CONVERSION = YES; 251 | CLANG_WARN_INT_CONVERSION = YES; 252 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 253 | CLANG_WARN_UNREACHABLE_CODE = YES; 254 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 255 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 256 | COPY_PHASE_STRIP = NO; 257 | CURRENT_PROJECT_VERSION = 1; 258 | DEBUG_INFORMATION_FORMAT = dwarf; 259 | ENABLE_STRICT_OBJC_MSGSEND = YES; 260 | ENABLE_TESTABILITY = YES; 261 | GCC_C_LANGUAGE_STANDARD = gnu99; 262 | GCC_DYNAMIC_NO_PIC = NO; 263 | GCC_NO_COMMON_BLOCKS = YES; 264 | GCC_OPTIMIZATION_LEVEL = 0; 265 | GCC_PREPROCESSOR_DEFINITIONS = ( 266 | "DEBUG=1", 267 | "$(inherited)", 268 | ); 269 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 270 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 271 | GCC_WARN_UNDECLARED_SELECTOR = YES; 272 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 273 | GCC_WARN_UNUSED_FUNCTION = YES; 274 | GCC_WARN_UNUSED_VARIABLE = YES; 275 | IPHONEOS_DEPLOYMENT_TARGET = 9.1; 276 | MTL_ENABLE_DEBUG_INFO = YES; 277 | ONLY_ACTIVE_ARCH = YES; 278 | SDKROOT = iphoneos; 279 | TARGETED_DEVICE_FAMILY = "1,2"; 280 | VERSIONING_SYSTEM = "apple-generic"; 281 | VERSION_INFO_PREFIX = ""; 282 | }; 283 | name = Debug; 284 | }; 285 | A21BFF8E1BFDCB3E00F9FB54 /* Release */ = { 286 | isa = XCBuildConfiguration; 287 | buildSettings = { 288 | ALWAYS_SEARCH_USER_PATHS = NO; 289 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 290 | CLANG_CXX_LIBRARY = "libc++"; 291 | CLANG_ENABLE_MODULES = YES; 292 | CLANG_ENABLE_OBJC_ARC = YES; 293 | CLANG_WARN_BOOL_CONVERSION = YES; 294 | CLANG_WARN_CONSTANT_CONVERSION = YES; 295 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 296 | CLANG_WARN_EMPTY_BODY = YES; 297 | CLANG_WARN_ENUM_CONVERSION = YES; 298 | CLANG_WARN_INT_CONVERSION = YES; 299 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 300 | CLANG_WARN_UNREACHABLE_CODE = YES; 301 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 302 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 303 | COPY_PHASE_STRIP = NO; 304 | CURRENT_PROJECT_VERSION = 1; 305 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 306 | ENABLE_NS_ASSERTIONS = NO; 307 | ENABLE_STRICT_OBJC_MSGSEND = YES; 308 | GCC_C_LANGUAGE_STANDARD = gnu99; 309 | GCC_NO_COMMON_BLOCKS = YES; 310 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 311 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 312 | GCC_WARN_UNDECLARED_SELECTOR = YES; 313 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 314 | GCC_WARN_UNUSED_FUNCTION = YES; 315 | GCC_WARN_UNUSED_VARIABLE = YES; 316 | IPHONEOS_DEPLOYMENT_TARGET = 9.1; 317 | MTL_ENABLE_DEBUG_INFO = NO; 318 | SDKROOT = iphoneos; 319 | TARGETED_DEVICE_FAMILY = "1,2"; 320 | VALIDATE_PRODUCT = YES; 321 | VERSIONING_SYSTEM = "apple-generic"; 322 | VERSION_INFO_PREFIX = ""; 323 | }; 324 | name = Release; 325 | }; 326 | A21BFFAA1BFDCC8800F9FB54 /* Debug */ = { 327 | isa = XCBuildConfiguration; 328 | buildSettings = { 329 | CURRENT_PROJECT_VERSION = 1.0.0; 330 | DEFINES_MODULE = YES; 331 | DYLIB_COMPATIBILITY_VERSION = 1; 332 | DYLIB_CURRENT_VERSION = 1; 333 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 334 | INFOPLIST_FILE = TLYShyNavBar/Info.plist; 335 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 336 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 337 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 338 | PRODUCT_BUNDLE_IDENTIFIER = com.telly.TLYShyNavBar; 339 | PRODUCT_NAME = "$(TARGET_NAME)"; 340 | SKIP_INSTALL = YES; 341 | }; 342 | name = Debug; 343 | }; 344 | A21BFFAB1BFDCC8800F9FB54 /* Release */ = { 345 | isa = XCBuildConfiguration; 346 | buildSettings = { 347 | CURRENT_PROJECT_VERSION = 1.0.0; 348 | DEFINES_MODULE = YES; 349 | DYLIB_COMPATIBILITY_VERSION = 1; 350 | DYLIB_CURRENT_VERSION = 1; 351 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 352 | INFOPLIST_FILE = TLYShyNavBar/Info.plist; 353 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 354 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 355 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 356 | PRODUCT_BUNDLE_IDENTIFIER = com.telly.TLYShyNavBar; 357 | PRODUCT_NAME = "$(TARGET_NAME)"; 358 | SKIP_INSTALL = YES; 359 | }; 360 | name = Release; 361 | }; 362 | /* End XCBuildConfiguration section */ 363 | 364 | /* Begin XCConfigurationList section */ 365 | A21BFF751BFDCB3E00F9FB54 /* Build configuration list for PBXProject "TLYShyNavBar" */ = { 366 | isa = XCConfigurationList; 367 | buildConfigurations = ( 368 | A21BFF8D1BFDCB3E00F9FB54 /* Debug */, 369 | A21BFF8E1BFDCB3E00F9FB54 /* Release */, 370 | ); 371 | defaultConfigurationIsVisible = 0; 372 | defaultConfigurationName = Release; 373 | }; 374 | A21BFFA91BFDCC8800F9FB54 /* Build configuration list for PBXNativeTarget "TLYShyNavBar" */ = { 375 | isa = XCConfigurationList; 376 | buildConfigurations = ( 377 | A21BFFAA1BFDCC8800F9FB54 /* Debug */, 378 | A21BFFAB1BFDCC8800F9FB54 /* Release */, 379 | ); 380 | defaultConfigurationIsVisible = 0; 381 | defaultConfigurationName = Release; 382 | }; 383 | /* End XCConfigurationList section */ 384 | }; 385 | rootObject = A21BFF721BFDCB3E00F9FB54 /* Project object */; 386 | } 387 | -------------------------------------------------------------------------------- /TLYShyNavBar.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /TLYShyNavBar.xcodeproj/xcshareddata/xcschemes/TLYShyNavBar.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 33 | 39 | 40 | 41 | 42 | 43 | 49 | 50 | 51 | 52 | 53 | 54 | 64 | 65 | 71 | 72 | 73 | 74 | 75 | 76 | 82 | 83 | 89 | 90 | 91 | 92 | 94 | 95 | 98 | 99 | 100 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/NSObject+TLYSwizzlingHelpers.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+TLYSwizzlingHelpers.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/23/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface NSObject (TLYSwizzlingHelpers) 12 | 13 | + (void)tly_swizzleClassMethod:(SEL)originalSelector withReplacement:(SEL)replacementSelector; 14 | + (void)tly_swizzleInstanceMethod:(SEL)originalSelector withReplacement:(SEL)replacementSelector; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/NSObject+TLYSwizzlingHelpers.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSObject+TLYSwizzlingHelpers.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/23/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "NSObject+TLYSwizzlingHelpers.h" 10 | #import 11 | 12 | @implementation NSObject (TLYSwizzlingHelpers) 13 | 14 | + (void)tly_swizzleClassMethod:(SEL)originalSelector withReplacement:(SEL)replacementSelector 15 | { 16 | Method originalMethod = class_getClassMethod([self class], originalSelector); 17 | Method replacementMethod = class_getClassMethod([self class], replacementSelector); 18 | method_exchangeImplementations(replacementMethod, originalMethod); 19 | } 20 | 21 | + (void)tly_swizzleInstanceMethod:(SEL)originalSelector withReplacement:(SEL)replacementSelector 22 | { 23 | Method originalMethod = class_getInstanceMethod([self class], originalSelector); 24 | Method replacementMethod = class_getInstanceMethod([self class], replacementSelector); 25 | method_exchangeImplementations(replacementMethod, originalMethod); 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/TLYDelegateProxy.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYDelegateProxy.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/27/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | /* CLASS DESCRIPTION: 12 | * ================== 13 | * Delegate proxy is meant to be used as a proxy between and 14 | * object and its delegate. The DelegateProxy is initialized with a 15 | * target and middle man, where the target is the original delegate 16 | * and the middle-man is just an object we send identical messages to. 17 | */ 18 | 19 | @interface TLYDelegateProxy : NSProxy 20 | 21 | @property (nonatomic, weak) id originalDelegate; 22 | 23 | - (instancetype)initWithMiddleMan:(id)middleMan; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/TLYDelegateProxy.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYDelegateProxy.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/27/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYDelegateProxy.h" 10 | #import 11 | 12 | @interface TLYDelegateProxy () 13 | 14 | @property (nonatomic, weak) id middleMan; 15 | 16 | @end 17 | 18 | @implementation TLYDelegateProxy 19 | 20 | - (instancetype)initWithMiddleMan:(id)middleMan 21 | { 22 | if (self) 23 | { 24 | self.middleMan = middleMan; 25 | } 26 | return self; 27 | } 28 | 29 | - (id)forwardingTargetForSelector:(SEL)sel 30 | { 31 | BOOL originalDelegateResponds = [self.originalDelegate respondsToSelector:sel]; 32 | BOOL middleManResponds = [self.middleMan respondsToSelector:sel]; 33 | if (originalDelegateResponds && !middleManResponds) { 34 | return self.originalDelegate; 35 | } else if (!originalDelegateResponds && middleManResponds) { 36 | return self.middleMan; 37 | } else { 38 | // continue with "slow" forwarding 39 | return self; 40 | } 41 | } 42 | 43 | - (NSInvocation *)_copyInvocation:(NSInvocation *)invocation 44 | { 45 | NSInvocation *copy = [NSInvocation invocationWithMethodSignature:[invocation methodSignature]]; 46 | NSUInteger argCount = [[invocation methodSignature] numberOfArguments]; 47 | 48 | for (int i = 0; i < argCount; i++) 49 | { 50 | char buffer[sizeof(intmax_t)]; 51 | [invocation getArgument:(void *)&buffer atIndex:i]; 52 | [copy setArgument:(void *)&buffer atIndex:i]; 53 | } 54 | 55 | return copy; 56 | } 57 | 58 | - (void)forwardInvocation:(NSInvocation *)invocation 59 | { 60 | if ([self.middleMan respondsToSelector:invocation.selector]) 61 | { 62 | NSInvocation *invocationCopy = [self _copyInvocation:invocation]; 63 | [invocationCopy invokeWithTarget:self.middleMan]; 64 | } 65 | 66 | if ([self.originalDelegate respondsToSelector:invocation.selector]) 67 | { 68 | [invocation invokeWithTarget:self.originalDelegate]; 69 | } 70 | } 71 | 72 | - (NSMethodSignature *)methodSignatureForSelector:(SEL)sel 73 | { 74 | id result = [self.originalDelegate methodSignatureForSelector:sel]; 75 | if (!result) { 76 | result = [self.middleMan methodSignatureForSelector:sel]; 77 | } 78 | 79 | return result; 80 | } 81 | 82 | - (BOOL)respondsToSelector:(SEL)aSelector 83 | { 84 | return ([self.originalDelegate respondsToSelector:aSelector] 85 | || [self.middleMan respondsToSelector:aSelector]); 86 | } 87 | 88 | @end 89 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/UIScrollView+Helpers.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIScrollView+Helpers.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | 12 | @interface UIScrollView (Helpers) 13 | 14 | - (void)tly_setInsets:(UIEdgeInsets)contentInsets; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/UIScrollView+Helpers.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIScrollView+Helpers.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "UIScrollView+Helpers.h" 10 | 11 | @implementation UIScrollView (Helpers) 12 | 13 | // Modify contentInset and scrollIndicatorInsets 14 | - (void)tly_setInsets:(UIEdgeInsets)contentInsets 15 | { 16 | if (!self.isDragging && !self.isDecelerating && contentInsets.top != self.contentInset.top) 17 | { 18 | CGFloat offsetDelta = contentInsets.top - self.contentInset.top; 19 | 20 | CGRect bounds = self.bounds; 21 | bounds.origin.y -= offsetDelta; 22 | self.bounds = bounds; 23 | } 24 | 25 | self.contentInset = contentInsets; 26 | self.scrollIndicatorInsets = contentInsets; 27 | } 28 | 29 | @end 30 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/UIViewController+BetterLayoutGuides.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIViewController+BetterLayoutGuides.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/21/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | /* CATEGORY DESCRIPTION: 12 | * ===================== 13 | * Apparently, Apple messed up when they implemented autolayout 14 | * somehow, so when we have child view controllers, they get wrong 15 | * layout guides. This helps accomodate that problem. 16 | * 17 | * Courtesy of http://stackoverflow.com/questions/19140530/toplayoutguide-in-child-view-controller 18 | */ 19 | 20 | @interface UIViewController (BetterLayoutGuides) 21 | 22 | @property (nonatomic, readonly) id tly_topLayoutGuide; 23 | @property (nonatomic, readonly) id tly_bottomLayoutGuide; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /TLYShyNavBar/Categories/UIViewController+BetterLayoutGuides.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIViewController+BetterLayoutGuides.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/21/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "UIViewController+BetterLayoutGuides.h" 10 | 11 | @implementation UIViewController (BetterLayoutGuides) 12 | 13 | - (id)tly_topLayoutGuide 14 | { 15 | if (self.parentViewController && 16 | ![self.parentViewController isKindOfClass:UINavigationController.class]) 17 | { 18 | return self.parentViewController.tly_topLayoutGuide; 19 | } 20 | else { 21 | return self.topLayoutGuide; 22 | } 23 | } 24 | 25 | - (id)tly_bottomLayoutGuide 26 | { 27 | if (self.parentViewController && 28 | ![self.parentViewController isKindOfClass:UINavigationController.class]) 29 | { 30 | return self.parentViewController.tly_bottomLayoutGuide; 31 | } 32 | else { 33 | return self.bottomLayoutGuide; 34 | } 35 | } 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /TLYShyNavBar/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | $(CURRENT_PROJECT_VERSION) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(CURRENT_PROJECT_VERSION) 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyChild.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyChild.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #ifndef TLYShyChild_h 10 | #define TLYShyChild_h 11 | 12 | 13 | @protocol TLYShyChild 14 | 15 | - (void)offsetCenterBy:(CGPoint)deltaPoint; 16 | 17 | @end 18 | 19 | #endif /* TLYShyChild_h */ 20 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyParent.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyParent.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #ifndef TLYShyParent_h 10 | #define TLYShyParent_h 11 | 12 | #import 13 | 14 | /** A shy parent can be asked for its maxY and height so the 15 | * child can pin itself to the bottom and calculate the total 16 | * height. 17 | */ 18 | @protocol TLYShyParent 19 | 20 | - (CGFloat)maxYRelativeToView:(UIView *)superview; 21 | - (CGFloat)calculateTotalHeightRecursively; 22 | 23 | @end 24 | 25 | #endif /* TLYShyParent_h */ 26 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyScrollViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyScrollViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "TLYShyViewController.h" 11 | #import "TLYShyParent.h" 12 | #import "TLYShyChild.h" 13 | 14 | 15 | @interface TLYShyScrollViewController : NSObject 16 | 17 | @property (nonatomic, weak) UIScrollView *scrollView; 18 | @property (nonatomic, weak) UIRefreshControl *refreshControl; 19 | @property (nonatomic, weak) TLYShyViewController *parent; 20 | 21 | @property (nonatomic, assign) BOOL hasCustomRefreshControl; 22 | 23 | - (CGFloat)updateLayoutIfNeeded; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyScrollViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyScrollViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYShyScrollViewController.h" 10 | #import "../Categories/UIScrollView+Helpers.h" 11 | 12 | 13 | @implementation TLYShyScrollViewController 14 | 15 | - (void)offsetCenterBy:(CGPoint)deltaPoint 16 | { 17 | [self updateLayoutIfNeeded]; 18 | } 19 | 20 | - (CGFloat)updateLayoutIfNeeded 21 | { 22 | if (self.scrollView.contentSize.height < FLT_EPSILON 23 | && ([self.scrollView isKindOfClass:[UITableView class]] 24 | || [self.scrollView isKindOfClass:[UICollectionView class]]) 25 | ) 26 | { 27 | return 0.f; 28 | } 29 | 30 | CGFloat parentMaxY = [self.parent maxYRelativeToView:self.scrollView.superview]; 31 | CGFloat normalizedY = parentMaxY - self.scrollView.frame.origin.y; 32 | UIEdgeInsets insets = UIEdgeInsetsMake(self.scrollView.contentInset.top, 0, self.scrollView.contentInset.bottom, 0); 33 | insets.top = normalizedY; 34 | 35 | if (normalizedY > -FLT_EPSILON && !UIEdgeInsetsEqualToEdgeInsets(insets, self.scrollView.contentInset)) 36 | { 37 | CGFloat delta = insets.top - self.scrollView.contentInset.top; 38 | 39 | if (!self.hasCustomRefreshControl && (self.refreshControl == nil || [self.refreshControl isHidden])) { 40 | [self.scrollView tly_setInsets:insets]; 41 | } 42 | 43 | return delta; 44 | } 45 | 46 | if (normalizedY < -FLT_EPSILON) 47 | { 48 | CGRect frame = self.scrollView.frame; 49 | frame = UIEdgeInsetsInsetRect(frame, insets); 50 | 51 | self.scrollView.frame = frame; 52 | return [self updateLayoutIfNeeded]; 53 | } 54 | 55 | return 0.f; 56 | } 57 | 58 | @end 59 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyStatusBarController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyStatusBarController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "TLYShyParent.h" 11 | 12 | 13 | @interface TLYShyStatusBarController : NSObject 14 | 15 | @property (nonatomic, weak) UIViewController *viewController; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyStatusBarController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyStatusBarController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYShyStatusBarController.h" 10 | 11 | 12 | // Thanks to SO user, MattDiPasquale 13 | // http://stackoverflow.com/questions/12991935/how-to-programmatically-get-ios-status-bar-height/16598350#16598350 14 | 15 | static inline CGFloat AACStatusBarHeight(UIViewController *viewController) 16 | { 17 | if ([UIApplication sharedApplication].statusBarHidden) 18 | { 19 | return 0.f; 20 | } 21 | 22 | // Modal views do not overlap the status bar, so no allowance need be made for it 23 | if (viewController.presentingViewController != nil) 24 | { 25 | return 0.f; 26 | } 27 | 28 | CGSize statusBarSize = [UIApplication sharedApplication].statusBarFrame.size; 29 | CGFloat statusBarHeight = MIN(statusBarSize.width, statusBarSize.height); 30 | 31 | UIView *view = viewController.view; 32 | CGRect frame = [view.superview convertRect:view.frame toView:view.window]; 33 | 34 | BOOL viewOverlapsStatusBar = frame.origin.y < statusBarHeight; 35 | 36 | if (!viewOverlapsStatusBar) 37 | { 38 | return 0.f; 39 | } 40 | 41 | return statusBarHeight; 42 | } 43 | 44 | 45 | @implementation TLYShyStatusBarController 46 | 47 | - (CGFloat)_statusBarHeight 48 | { 49 | CGFloat statusBarHeight = AACStatusBarHeight(self.viewController); 50 | /* The standard status bar is 20 pixels. The navigation bar extends 20 pixels up so it is overlapped by the status bar. 51 | * When there is a larger than 20 pixel status bar (e.g. a phone call is in progress or GPS is active), the center needs 52 | * to shift up 20 pixels to avoid this 'dead space' being visible above the usual nav bar. 53 | */ 54 | if (statusBarHeight > 20) 55 | { 56 | statusBarHeight -= 20; 57 | } 58 | 59 | return statusBarHeight; 60 | } 61 | 62 | - (CGFloat)maxYRelativeToView:(UIView *)superview 63 | { 64 | return [self _statusBarHeight]; 65 | } 66 | 67 | - (CGFloat)calculateTotalHeightRecursively 68 | { 69 | return [self _statusBarHeight]; 70 | } 71 | 72 | @end 73 | 74 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/14/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | #import "TLYShyParent.h" 12 | #import "TLYShyChild.h" 13 | #import "../TLYShyNavBarFade.h" 14 | 15 | 16 | extern const CGFloat contractionVelocity; 17 | 18 | typedef CGPoint(^TLYShyViewControllerExpandedCenterBlock)(UIView *view); 19 | typedef CGFloat(^TLYShyViewControllerContractionAmountBlock)(UIView *view); 20 | 21 | 22 | /* CLASS DESCRIPTION: 23 | * ================== 24 | * A shy view is a view that contracts when a scrolling event is 25 | * triggered. We use this class to control the operations we perform on 26 | * the shy view. 27 | * 28 | * We are making some dangerous assumtions here!!! Most importantly, 29 | * the TLYShyViewController can only be a maximum depth of 2. Adding a 30 | * child to an already childified node is not supported. 31 | */ 32 | 33 | @interface TLYShyViewController : NSObject 34 | 35 | @property (nonatomic, weak) id child; 36 | @property (nonatomic, weak) id parent; 37 | @property (nonatomic, weak) TLYShyViewController *subShyController; 38 | @property (nonatomic, weak) UIView *view; 39 | 40 | @property (nonatomic) TLYShyNavBarFade fadeBehavior; 41 | 42 | /* Sticky means it will always stay in expanded state 43 | */ 44 | @property (nonatomic) BOOL sticky; 45 | 46 | - (void)offsetCenterBy:(CGPoint)deltaPoint; 47 | - (CGFloat)updateYOffset:(CGFloat)deltaY; 48 | 49 | - (CGFloat)snap:(BOOL)contract; 50 | - (CGFloat)snap:(BOOL)contract completion:(void (^)())completion; 51 | 52 | - (CGFloat)expand; 53 | - (CGFloat)contract; 54 | 55 | @end 56 | 57 | 58 | @interface TLYShyViewController (AsParent) 59 | @end 60 | -------------------------------------------------------------------------------- /TLYShyNavBar/ShyControllers/TLYShyViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/14/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYShyViewController.h" 10 | #import "TLYShyStatusBarController.h" 11 | 12 | 13 | @implementation TLYShyViewController (AsParent) 14 | 15 | - (CGFloat)maxYRelativeToView:(UIView *)superview 16 | { 17 | CGPoint maxEdge = CGPointMake(0, CGRectGetHeight(self.view.bounds)); 18 | CGPoint normalizedMaxEdge = [superview convertPoint:maxEdge fromView:self.view]; 19 | 20 | return normalizedMaxEdge.y; 21 | } 22 | 23 | - (CGFloat)calculateTotalHeightRecursively 24 | { 25 | float overlap = [self.parent maxYRelativeToView:self.view]; 26 | if ([self.parent isMemberOfClass:[TLYShyStatusBarController class]] && overlap - self.view.frame.origin.y > 0) { 27 | overlap += overlap - self.view.frame.origin.y; 28 | } 29 | return CGRectGetHeight(self.view.bounds) - overlap + [self.parent calculateTotalHeightRecursively]; 30 | } 31 | 32 | @end 33 | 34 | 35 | @interface TLYShyViewController () 36 | 37 | @property (nonatomic, assign) CGPoint expandedCenterValue; 38 | @property (nonatomic, assign) CGFloat contractionAmountValue; 39 | 40 | @property (nonatomic, assign) CGPoint contractedCenterValue; 41 | 42 | @property (nonatomic, assign) BOOL contracted; 43 | @property (nonatomic, assign) BOOL expanded; 44 | 45 | @end 46 | 47 | @implementation TLYShyViewController 48 | 49 | #pragma mark - Properties 50 | 51 | // convenience 52 | - (CGPoint)expandedCenterValue 53 | { 54 | CGPoint center = CGPointMake(CGRectGetMidX(self.view.bounds), 55 | CGRectGetMidY(self.view.bounds)); 56 | 57 | center.y += [self.parent maxYRelativeToView:self.view.superview]; 58 | 59 | return center; 60 | } 61 | 62 | - (CGFloat)contractionAmountValue 63 | { 64 | return self.sticky ? 0.f : CGRectGetHeight(self.view.bounds); 65 | } 66 | 67 | - (CGPoint)contractedCenterValue 68 | { 69 | return CGPointMake(self.expandedCenterValue.x, self.expandedCenterValue.y - self.contractionAmountValue); 70 | } 71 | 72 | - (BOOL)contracted 73 | { 74 | return fabs(self.view.center.y - self.contractedCenterValue.y) < FLT_EPSILON; 75 | } 76 | 77 | - (BOOL)expanded 78 | { 79 | return fabs(self.view.center.y - self.expandedCenterValue.y) < FLT_EPSILON; 80 | } 81 | 82 | #pragma mark - Private methods 83 | 84 | - (void)_onAlphaUpdate:(CGFloat)alpha 85 | { 86 | if (self.sticky) 87 | { 88 | self.view.alpha = 1.f; 89 | [self _updateSubviewsAlpha:1.f]; 90 | return; 91 | } 92 | 93 | switch (self.fadeBehavior) { 94 | 95 | case TLYShyNavBarFadeDisabled: 96 | self.view.alpha = 1.f; 97 | [self _updateSubviewsAlpha:1.f]; 98 | break; 99 | 100 | case TLYShyNavBarFadeSubviews: 101 | self.view.alpha = 1.f; 102 | [self _updateSubviewsAlpha:alpha]; 103 | break; 104 | 105 | case TLYShyNavBarFadeNavbar: 106 | self.view.alpha = alpha; 107 | [self _updateSubviewsAlpha:1.f]; 108 | break; 109 | } 110 | } 111 | 112 | // This method is courtesy of GTScrollNavigationBar 113 | // https://github.com/luugiathuy/GTScrollNavigationBar 114 | - (void)_updateSubviewsAlpha:(CGFloat)alpha 115 | { 116 | for (UIView* view in self.view.subviews) 117 | { 118 | bool isBackgroundView = view == self.view.subviews[0]; 119 | bool isViewHidden = view.hidden || view.alpha < FLT_EPSILON; 120 | 121 | if (!isBackgroundView && !isViewHidden) 122 | { 123 | view.alpha = alpha; 124 | } 125 | } 126 | } 127 | 128 | - (void)_updateCenter:(CGPoint)newCenter 129 | { 130 | CGPoint currentCenter = self.view.center; 131 | CGPoint deltaPoint = CGPointMake(newCenter.x - currentCenter.x, 132 | newCenter.y - currentCenter.y); 133 | 134 | [self offsetCenterBy:deltaPoint]; 135 | } 136 | 137 | #pragma mark - Public methods 138 | 139 | - (void)setFadeBehavior:(TLYShyNavBarFade)fadeBehavior 140 | { 141 | _fadeBehavior = fadeBehavior; 142 | 143 | if (fadeBehavior == TLYShyNavBarFadeDisabled) 144 | { 145 | [self _onAlphaUpdate:1.f]; 146 | } 147 | } 148 | 149 | - (void)offsetCenterBy:(CGPoint)deltaPoint 150 | { 151 | self.view.center = CGPointMake(self.view.center.x + deltaPoint.x, 152 | self.view.center.y + deltaPoint.y); 153 | 154 | [self.child offsetCenterBy:deltaPoint]; 155 | } 156 | 157 | - (CGFloat)updateYOffset:(CGFloat)deltaY 158 | { 159 | if (self.subShyController && deltaY < 0) 160 | { 161 | deltaY = [self.subShyController updateYOffset:deltaY]; 162 | } 163 | 164 | CGFloat residual = deltaY; 165 | 166 | if (!self.sticky) 167 | { 168 | CGFloat newYOffset = self.view.center.y + deltaY; 169 | CGFloat newYCenter = MAX(MIN(self.expandedCenterValue.y, newYOffset), self.contractedCenterValue.y); 170 | 171 | [self _updateCenter:CGPointMake(self.expandedCenterValue.x, newYCenter)]; 172 | 173 | CGFloat newAlpha = 1.f - (self.expandedCenterValue.y - self.view.center.y) / self.contractionAmountValue; 174 | newAlpha = MIN(MAX(FLT_EPSILON, newAlpha), 1.f); 175 | 176 | [self _onAlphaUpdate:newAlpha]; 177 | 178 | residual = newYOffset - newYCenter; 179 | 180 | // QUICK FIX: Only the extensionView is hidden 181 | if (!self.subShyController) 182 | { 183 | self.view.hidden = residual < 0; 184 | } 185 | } 186 | 187 | if (self.subShyController && deltaY > 0 && residual > 0) 188 | { 189 | residual = [self.subShyController updateYOffset:residual]; 190 | } 191 | 192 | return residual; 193 | } 194 | 195 | - (CGFloat)snap:(BOOL)contract 196 | { 197 | return [self snap:contract completion:nil]; 198 | } 199 | 200 | - (CGFloat)snap:(BOOL)contract completion:(void (^)())completion 201 | { 202 | /* "The Facebook" UX dictates that: 203 | * 204 | * 1 - When you contract: 205 | * A - contract beyond the extension view -> contract the whole thing 206 | * B - contract within the extension view -> expand the extension back 207 | * 208 | * 2 - When you expand: 209 | * A - expand beyond the navbar -> expand the whole thing 210 | * B - expand within the navbar -> contract the navbar back 211 | */ 212 | 213 | __block CGFloat deltaY; 214 | [UIView animateWithDuration:0.2 animations:^ 215 | { 216 | if ((contract && self.subShyController.contracted) || (!contract && !self.expanded)) 217 | { 218 | deltaY = [self contract]; 219 | } 220 | else 221 | { 222 | deltaY = [self.subShyController expand]; 223 | } 224 | } 225 | completion:^(BOOL finished) 226 | { 227 | if (completion && finished) { 228 | completion(); 229 | } 230 | }]; 231 | 232 | return deltaY; 233 | } 234 | 235 | - (CGFloat)expand 236 | { 237 | self.view.hidden = NO; 238 | 239 | [self _onAlphaUpdate:1.f]; 240 | 241 | CGFloat amountToMove = self.expandedCenterValue.y - self.view.center.y; 242 | 243 | [self _updateCenter:self.expandedCenterValue]; 244 | [self.subShyController expand]; 245 | 246 | return amountToMove; 247 | } 248 | 249 | - (CGFloat)contract 250 | { 251 | CGFloat amountToMove = self.contractedCenterValue.y - self.view.center.y; 252 | 253 | [self _onAlphaUpdate:FLT_EPSILON]; 254 | 255 | [self _updateCenter:self.contractedCenterValue]; 256 | [self.subShyController contract]; 257 | 258 | return amountToMove; 259 | } 260 | 261 | @end 262 | -------------------------------------------------------------------------------- /TLYShyNavBar/TLYShyNavBar.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBar.h 3 | // TLYShyNavBar 4 | // 5 | 6 | #import 7 | 8 | //! Project version number for TLYShyNavBar. 9 | FOUNDATION_EXPORT double TLYShyNavBarVersionNumber; 10 | 11 | //! Project version string for TLYShyNavBar. 12 | FOUNDATION_EXPORT const unsigned char TLYShyNavBarVersionString[]; 13 | 14 | // In this header, you should import all the public headers of your framework using statements like #import 15 | #import 16 | -------------------------------------------------------------------------------- /TLYShyNavBar/TLYShyNavBarFade.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBarFade.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #ifndef TLYShyNavBarFade_h 10 | #define TLYShyNavBarFade_h 11 | 12 | /** This enum helps control the navigation bar fade behavior. 13 | */ 14 | typedef NS_ENUM(NSInteger, TLYShyNavBarFade) { 15 | 16 | TLYShyNavBarFadeDisabled, 17 | TLYShyNavBarFadeSubviews, 18 | TLYShyNavBarFadeNavbar, 19 | }; 20 | 21 | #endif /* TLYShyNavBarFade_h */ 22 | -------------------------------------------------------------------------------- /TLYShyNavBar/TLYShyNavBarManager.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBarManager.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/13/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | #import "TLYShyNavBarFade.h" 12 | 13 | 14 | @protocol TLYShyNavBarManagerDelegate; 15 | 16 | /** CLASS DESCRIPTION: 17 | * ================== 18 | * Manages the relationship between a scrollView and a view 19 | * controller. Must be instantiated and assigned the scrollView 20 | * that drives the contraction/expansion, then assigned to the 21 | * viewController that needs the functionality. Must be assigned 22 | * throught the UIViewController category: 23 | * 24 | * viewController.shyNavManager = ...; 25 | * 26 | */ 27 | @interface TLYShyNavBarManager : NSObject 28 | 29 | /* The view controller that is part of the navigation stack 30 | * IMPORTANT: Must have access to navigationController 31 | */ 32 | @property (nonatomic, readonly, weak) UIViewController *viewController; 33 | 34 | /* The scrollView subclass that will drive the contraction/expansion 35 | * IMPORTANT: set this property AFTER assigning its delegate, if needed! 36 | */ 37 | @property (nonatomic, strong) UIScrollView *scrollView; 38 | 39 | /* The extension view to be shown beneath the navbar 40 | */ 41 | @property (nonatomic, strong) UIView *extensionView; 42 | 43 | /* The container contains the extension view, if any. Exposed to 44 | * allow the developer to adjust content offset as necessary. 45 | */ 46 | @property (nonatomic, readonly) CGRect extensionViewBounds; 47 | 48 | /* Make the navigation bar stick to the top without collapsing 49 | * Deatuls to NO 50 | */ 51 | @property (nonatomic) BOOL stickyNavigationBar; 52 | 53 | /* Make the extension view stick to the bottom of the navbar without 54 | * collapsing 55 | * Defaults to NO 56 | */ 57 | @property (nonatomic) BOOL stickyExtensionView; 58 | 59 | /* Control the resistance when scrolling up/down before the navbar 60 | * expands/contracts again. 61 | */ 62 | @property (nonatomic) CGFloat expansionResistance; // default 200 63 | @property (nonatomic) CGFloat contractionResistance; // default 0 64 | 65 | /* Choose how the navbar fades as it contracts/expands. 66 | * Defaults to FadeSubviews 67 | */ 68 | @property (nonatomic) TLYShyNavBarFade fadeBehavior; 69 | 70 | /* Use this to set if the controller have any kind of custom refresh control 71 | */ 72 | @property (nonatomic) BOOL hasCustomRefreshControl; 73 | 74 | /* Set NO to disable shyNavBar behavior temporarily. 75 | * Defaults to NO 76 | */ 77 | @property (nonatomic) BOOL disable; 78 | 79 | /* Use this to be notified about contraction and expansion events. 80 | */ 81 | @property (nonatomic, weak) id delegate; 82 | 83 | @end 84 | 85 | /* PROTOCOL DESCRIPTION: 86 | * ===================== 87 | * This protocol is used to notify an optional TLYShyNavBarManager's delegate 88 | * when a contraction or expansion finishes animating. 89 | */ 90 | @protocol TLYShyNavBarManagerDelegate 91 | 92 | @optional 93 | 94 | - (void)shyNavBarManagerDidBecomeFullyContracted:(TLYShyNavBarManager *) shyNavBarManager; 95 | - (void)shyNavBarManagerDidFinishContracting:(TLYShyNavBarManager *) shyNavBarManager; 96 | - (void)shyNavBarManagerDidFinishExpanding:(TLYShyNavBarManager *) shyNavBarManager; 97 | 98 | @end 99 | 100 | 101 | /** CATEGORY DESCRIPTION: 102 | * ===================== 103 | * The category described in the TLYShyNavBarManager usage, and it 104 | * simply uses associated objects to attatch a TLYShyNavBar to the 105 | * designated view controller. 106 | * 107 | * We also perform some swizzling to pass notifications to the 108 | * TLYShyNavBar. Things like, viewDidLayoutSubviews, viewWillAppear and 109 | * Disappear, ... etc. 110 | */ 111 | 112 | @interface UIViewController (ShyNavBar) 113 | 114 | /* Initially, this is nil, but created for you when you access it */ 115 | @property (nonatomic, strong) TLYShyNavBarManager *shyNavBarManager; 116 | 117 | /* 118 | * Set the TLYShyNavBarManager while also specifying a view controller 119 | */ 120 | - (void)setShyNavBarManager:(TLYShyNavBarManager *)shyNavBarManager 121 | viewController:(UIViewController *)viewController; 122 | 123 | /* Use this to find out if a TLYShyNavBarManager instance was associated 124 | * to this view controller, without triggering its creation and association. 125 | */ 126 | - (BOOL)isShyNavBarManagerPresent; 127 | 128 | @end 129 | -------------------------------------------------------------------------------- /TLYShyNavBar/TLYShyNavBarManager.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBarManager.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/13/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYShyNavBarManager.h" 10 | 11 | #import "ShyControllers/TLYShyViewController.h" 12 | #import "ShyControllers/TLYShyStatusBarController.h" 13 | #import "ShyControllers/TLYShyScrollViewController.h" 14 | 15 | #import "Categories/TLYDelegateProxy.h" 16 | #import "Categories/UIViewController+BetterLayoutGuides.h" 17 | #import "Categories/NSObject+TLYSwizzlingHelpers.h" 18 | #import "Categories/UIScrollView+Helpers.h" 19 | 20 | #import 21 | 22 | 23 | static void * const kTLYShyNavBarManagerKVOContext = (void*)&kTLYShyNavBarManagerKVOContext; 24 | 25 | 26 | #pragma mark - TLYShyNavBarManager class 27 | 28 | @interface TLYShyNavBarManager () 29 | 30 | @property (nonatomic, strong) TLYShyStatusBarController *statusBarController; 31 | @property (nonatomic, strong) TLYShyViewController *navBarController; 32 | @property (nonatomic, strong) TLYShyViewController *extensionController; 33 | @property (nonatomic, strong) TLYShyScrollViewController *scrollViewController; 34 | 35 | @property (nonatomic, strong) TLYDelegateProxy *delegateProxy; 36 | 37 | @property (nonatomic, strong) UIView *extensionViewContainer; 38 | 39 | @property (nonatomic, assign) CGFloat previousYOffset; 40 | @property (nonatomic, assign) CGFloat resistanceConsumed; 41 | 42 | @property (nonatomic, assign) BOOL contracting; 43 | @property (nonatomic, assign) BOOL previousContractionState; 44 | 45 | @property (nonatomic, readonly) BOOL isViewControllerVisible; 46 | 47 | @end 48 | 49 | @implementation TLYShyNavBarManager 50 | 51 | #pragma mark - Init & Dealloc 52 | 53 | - (instancetype)init 54 | { 55 | self = [super init]; 56 | if (self) 57 | { 58 | self.delegateProxy = [[TLYDelegateProxy alloc] initWithMiddleMan:self]; 59 | 60 | /* Initialize defaults */ 61 | self.contracting = NO; 62 | self.previousContractionState = YES; 63 | 64 | self.expansionResistance = 200.f; 65 | self.contractionResistance = 0.f; 66 | 67 | self.fadeBehavior = TLYShyNavBarFadeSubviews; 68 | self.previousYOffset = NAN; 69 | 70 | /* Initialize shy controllers */ 71 | self.statusBarController = [[TLYShyStatusBarController alloc] init]; 72 | self.scrollViewController = [[TLYShyScrollViewController alloc] init]; 73 | self.navBarController = [[TLYShyViewController alloc] init]; 74 | 75 | self.extensionViewContainer = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 100.f, 0.f)]; 76 | self.extensionViewContainer.backgroundColor = [UIColor clearColor]; 77 | self.extensionViewContainer.autoresizingMask = UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleBottomMargin; 78 | 79 | self.extensionController = [[TLYShyViewController alloc] init]; 80 | self.extensionController.view = self.extensionViewContainer; 81 | 82 | /* hierarchy setup */ 83 | /* StatusBar <-- navbar <-->> extension <--> scrollView 84 | */ 85 | self.navBarController.parent = self.statusBarController; 86 | self.navBarController.child = self.extensionController; 87 | self.navBarController.subShyController = self.extensionController; 88 | self.extensionController.parent = self.navBarController; 89 | self.extensionController.child = self.scrollViewController; 90 | self.scrollViewController.parent = self.extensionController; 91 | 92 | /* Notification helpers */ 93 | [[NSNotificationCenter defaultCenter] addObserver:self 94 | selector:@selector(applicationDidBecomeActive:) 95 | name:UIApplicationDidBecomeActiveNotification 96 | object:nil]; 97 | 98 | [[NSNotificationCenter defaultCenter] addObserver:self 99 | selector:@selector(applicationDidChangeStatusBarFrame:) 100 | name:UIApplicationDidChangeStatusBarFrameNotification 101 | object:nil]; 102 | } 103 | return self; 104 | } 105 | 106 | - (void)dealloc 107 | { 108 | // sanity check 109 | if (_scrollView.delegate == _delegateProxy) 110 | { 111 | _scrollView.delegate = _delegateProxy.originalDelegate; 112 | } 113 | 114 | [[NSNotificationCenter defaultCenter] removeObserver:self]; 115 | [_scrollView removeObserver:self forKeyPath:@"contentSize" context:kTLYShyNavBarManagerKVOContext]; 116 | } 117 | 118 | #pragma mark - Properties 119 | 120 | - (void)setViewController:(UIViewController *)viewController 121 | { 122 | _viewController = viewController; 123 | 124 | if ([viewController isKindOfClass:[UITableViewController class]] 125 | || [viewController.view isKindOfClass:[UITableViewController class]]) 126 | { 127 | NSLog(@"*** WARNING: Please consider using a UIViewController with a UITableView as a subview ***"); 128 | } 129 | 130 | UIView *navbar = viewController.navigationController.navigationBar; 131 | NSAssert(navbar != nil, @"Please make sure the viewController is already attached to a navigation controller."); 132 | 133 | viewController.extendedLayoutIncludesOpaqueBars = YES; 134 | 135 | [self.extensionViewContainer removeFromSuperview]; 136 | [self.viewController.view addSubview:self.extensionViewContainer]; 137 | 138 | self.navBarController.view = navbar; 139 | 140 | self.statusBarController.viewController = viewController; 141 | 142 | [self layoutViews]; 143 | } 144 | 145 | - (void)setScrollView:(UIScrollView *)scrollView 146 | { 147 | [_scrollView removeObserver:self forKeyPath:@"contentSize" context:kTLYShyNavBarManagerKVOContext]; 148 | 149 | if (_scrollView.delegate == self.delegateProxy) 150 | { 151 | _scrollView.delegate = self.delegateProxy.originalDelegate; 152 | } 153 | 154 | _scrollView = scrollView; 155 | self.scrollViewController.scrollView = scrollView; 156 | 157 | NSUInteger index = [scrollView.subviews indexOfObjectPassingTest:^BOOL (id obj, NSUInteger idx, BOOL *stop) { 158 | return [obj isKindOfClass:[UIRefreshControl class]]; 159 | }]; 160 | 161 | if (index != NSNotFound) { 162 | self.scrollViewController.refreshControl = [scrollView.subviews objectAtIndex:index]; 163 | } 164 | 165 | if (_scrollView.delegate != self.delegateProxy) 166 | { 167 | self.delegateProxy.originalDelegate = _scrollView.delegate; 168 | _scrollView.delegate = (id)self.delegateProxy; 169 | } 170 | 171 | [self cleanup]; 172 | [self layoutViews]; 173 | 174 | [_scrollView addObserver:self forKeyPath:@"contentSize" options:0 context:kTLYShyNavBarManagerKVOContext]; 175 | } 176 | 177 | - (CGRect)extensionViewBounds 178 | { 179 | return self.extensionViewContainer.bounds; 180 | } 181 | 182 | - (BOOL)isViewControllerVisible 183 | { 184 | return self.viewController.isViewLoaded && self.viewController.view.window; 185 | } 186 | 187 | - (void)setDisable:(BOOL)disable 188 | { 189 | if (disable == _disable) 190 | { 191 | return; 192 | } 193 | 194 | _disable = disable; 195 | 196 | if (!disable) { 197 | self.previousYOffset = self.scrollView.contentOffset.y; 198 | } 199 | } 200 | 201 | - (void)setHasCustomRefreshControl:(BOOL)hasCustomRefreshControl 202 | { 203 | if (_hasCustomRefreshControl == hasCustomRefreshControl) 204 | { 205 | return; 206 | } 207 | 208 | _hasCustomRefreshControl = hasCustomRefreshControl; 209 | 210 | self.scrollViewController.hasCustomRefreshControl = hasCustomRefreshControl; 211 | } 212 | 213 | - (BOOL)stickyNavigationBar 214 | { 215 | return self.navBarController.sticky; 216 | } 217 | 218 | - (void)setStickyNavigationBar:(BOOL)stickyNavigationBar 219 | { 220 | self.navBarController.sticky = stickyNavigationBar; 221 | } 222 | 223 | - (BOOL)stickyExtensionView 224 | { 225 | return self.extensionController.sticky; 226 | } 227 | 228 | - (void)setStickyExtensionView:(BOOL)stickyExtensionView 229 | { 230 | self.extensionController.sticky = stickyExtensionView; 231 | } 232 | 233 | 234 | #pragma mark - Private methods 235 | 236 | - (BOOL)_scrollViewIsSuffecientlyLong 237 | { 238 | CGRect scrollFrame = UIEdgeInsetsInsetRect(self.scrollView.bounds, self.scrollView.contentInset); 239 | CGFloat scrollableAmount = self.scrollView.contentSize.height - CGRectGetHeight(scrollFrame); 240 | return (scrollableAmount > [self.extensionController calculateTotalHeightRecursively]); 241 | } 242 | 243 | - (BOOL)_shouldHandleScrolling 244 | { 245 | if (self.disable) 246 | { 247 | return NO; 248 | } 249 | 250 | return (self.isViewControllerVisible && [self _scrollViewIsSuffecientlyLong]); 251 | } 252 | 253 | - (void)_handleScrolling 254 | { 255 | if (![self _shouldHandleScrolling]) 256 | { 257 | return; 258 | } 259 | 260 | if (!isnan(self.previousYOffset)) 261 | { 262 | // 1 - Calculate the delta 263 | CGFloat deltaY = (self.previousYOffset - self.scrollView.contentOffset.y); 264 | 265 | // 2 - Ignore any scrollOffset beyond the bounds 266 | CGFloat start = -self.scrollView.contentInset.top; 267 | if (self.previousYOffset < start) 268 | { 269 | deltaY = MIN(0, deltaY - (self.previousYOffset - start)); 270 | } 271 | 272 | /* rounding to resolve a dumb issue with the contentOffset value */ 273 | CGFloat end = floorf(self.scrollView.contentSize.height - CGRectGetHeight(self.scrollView.bounds) + self.scrollView.contentInset.bottom - 0.5f); 274 | if (self.previousYOffset > end && deltaY > 0) 275 | { 276 | deltaY = MAX(0, deltaY - self.previousYOffset + end); 277 | } 278 | 279 | // 3 - Update contracting variable 280 | if (fabs(deltaY) > FLT_EPSILON) 281 | { 282 | self.contracting = deltaY < 0; 283 | } 284 | 285 | // 4 - Check if contracting state changed, and do stuff if so 286 | if (self.contracting != self.previousContractionState) 287 | { 288 | self.previousContractionState = self.contracting; 289 | self.resistanceConsumed = 0; 290 | } 291 | 292 | // GTH: Calculate the exact point to avoid expansion resistance 293 | // CGFloat statusBarHeight = [self.statusBarController calculateTotalHeightRecursively]; 294 | 295 | // 5 - Apply resistance 296 | // 5.1 - Always apply resistance when contracting 297 | if (self.contracting) 298 | { 299 | CGFloat availableResistance = self.contractionResistance - self.resistanceConsumed; 300 | self.resistanceConsumed = MIN(self.contractionResistance, self.resistanceConsumed - deltaY); 301 | 302 | deltaY = MIN(0, availableResistance + deltaY); 303 | } 304 | // 5.2 - Only apply resistance if expanding above the status bar 305 | else if (self.scrollView.contentOffset.y > 0) 306 | { 307 | CGFloat availableResistance = self.expansionResistance - self.resistanceConsumed; 308 | self.resistanceConsumed = MIN(self.expansionResistance, self.resistanceConsumed + deltaY); 309 | 310 | deltaY = MAX(0, deltaY - availableResistance); 311 | } 312 | 313 | // 6 - Update the navigation bar shyViewController 314 | self.navBarController.fadeBehavior = self.fadeBehavior; 315 | 316 | // 7 - Inform the delegate if needed 317 | CGFloat maxNavY = CGRectGetMaxY(self.navBarController.view.frame); 318 | CGFloat maxExtensionY = CGRectGetMaxY(self.extensionViewContainer.frame); 319 | CGFloat visibleTop; 320 | if (self.extensionViewContainer.hidden) { 321 | visibleTop = maxNavY; 322 | } else { 323 | visibleTop = MAX(maxNavY, maxExtensionY); 324 | } 325 | if (visibleTop == self.statusBarController.calculateTotalHeightRecursively) { 326 | if ([self.delegate respondsToSelector:@selector(shyNavBarManagerDidBecomeFullyContracted:)]) { 327 | [self.delegate shyNavBarManagerDidBecomeFullyContracted:self]; 328 | } 329 | } 330 | 331 | [self.navBarController updateYOffset:deltaY]; 332 | } 333 | 334 | self.previousYOffset = self.scrollView.contentOffset.y; 335 | } 336 | 337 | - (void)_handleScrollingEnded 338 | { 339 | if (!self.isViewControllerVisible) 340 | { 341 | return; 342 | } 343 | 344 | __weak __typeof(self) weakSelf = self; 345 | void (^completion)() = ^ 346 | { 347 | __typeof(self) strongSelf = weakSelf; 348 | if (strongSelf) { 349 | if (strongSelf.contracting) { 350 | if ([strongSelf.delegate respondsToSelector:@selector(shyNavBarManagerDidFinishContracting:)]) { 351 | [strongSelf.delegate shyNavBarManagerDidFinishContracting:strongSelf]; 352 | } 353 | } else { 354 | if ([strongSelf.delegate respondsToSelector:@selector(shyNavBarManagerDidFinishExpanding:)]) { 355 | [strongSelf.delegate shyNavBarManagerDidFinishExpanding:strongSelf]; 356 | } 357 | } 358 | } 359 | }; 360 | 361 | self.resistanceConsumed = 0; 362 | [self.navBarController snap:self.contracting completion:completion]; 363 | } 364 | 365 | #pragma mark - KVO 366 | 367 | - (void)observeValueForKeyPath:(NSString *)keyPath 368 | ofObject:(id)object 369 | change:(NSDictionary *)change 370 | context:(void *)context 371 | { 372 | if (context == kTLYShyNavBarManagerKVOContext) 373 | { 374 | if (self.isViewControllerVisible && ![self _scrollViewIsSuffecientlyLong]) 375 | { 376 | [self.navBarController expand]; 377 | } 378 | } 379 | else 380 | { 381 | [super observeValueForKeyPath:keyPath ofObject:object change:change context:context]; 382 | } 383 | } 384 | 385 | #pragma mark - public methods 386 | 387 | - (void)setExtensionView:(UIView *)view 388 | { 389 | if (view != _extensionView) 390 | { 391 | [_extensionView removeFromSuperview]; 392 | _extensionView = view; 393 | 394 | CGRect bounds = view.frame; 395 | bounds.origin = CGPointZero; 396 | 397 | view.frame = bounds; 398 | 399 | self.extensionViewContainer.frame = bounds; 400 | [self.extensionViewContainer addSubview:view]; 401 | self.extensionViewContainer.userInteractionEnabled = view.userInteractionEnabled; 402 | 403 | /* Disable scroll handling temporarily while laying out views to avoid double-changing content 404 | * offsets in _handleScrolling. */ 405 | BOOL wasDisabled = self.disable; 406 | self.disable = YES; 407 | [self layoutViews]; 408 | self.disable = wasDisabled; 409 | } 410 | } 411 | 412 | - (void)prepareForDisplay 413 | { 414 | [self cleanup]; 415 | } 416 | 417 | - (void)layoutViews 418 | { 419 | if (fabs([self.scrollViewController updateLayoutIfNeeded]) > FLT_EPSILON) 420 | { 421 | [self.navBarController expand]; 422 | [self.extensionViewContainer.superview bringSubviewToFront:self.extensionViewContainer]; 423 | } 424 | } 425 | 426 | - (void)cleanup 427 | { 428 | [self.navBarController expand]; 429 | self.previousYOffset = NAN; 430 | } 431 | 432 | #pragma mark - UIScrollViewDelegate methods 433 | 434 | - (void)scrollViewDidScroll:(UIScrollView *)scrollView 435 | { 436 | [self _handleScrolling]; 437 | } 438 | 439 | - (void)scrollViewDidEndDragging:(UIScrollView *)scrollView willDecelerate:(BOOL)decelerate 440 | { 441 | if (!decelerate) 442 | { 443 | [self _handleScrollingEnded]; 444 | } 445 | } 446 | 447 | - (void)scrollViewDidScrollToTop:(UIScrollView *)scrollView 448 | { 449 | [self.scrollView scrollRectToVisible:CGRectMake(0,0,1,1) animated:YES]; 450 | [self.scrollView flashScrollIndicators]; 451 | } 452 | 453 | - (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView 454 | { 455 | [self _handleScrollingEnded]; 456 | } 457 | 458 | #pragma mark - NSNotificationCenter methods 459 | 460 | - (void)applicationDidBecomeActive:(NSNotification *)notification 461 | { 462 | if (self.scrollView.window) { 463 | [self.navBarController expand]; 464 | } 465 | } 466 | 467 | - (void)applicationDidChangeStatusBarFrame:(NSNotification *)notification 468 | { 469 | [self.navBarController expand]; 470 | } 471 | 472 | @end 473 | 474 | #pragma mark - UIViewController+TLYShyNavBar category 475 | 476 | static char shyNavBarManagerKey; 477 | 478 | @implementation UIViewController (ShyNavBar) 479 | 480 | #pragma mark - Static methods 481 | 482 | + (void)load 483 | { 484 | static dispatch_once_t onceToken; 485 | dispatch_once(&onceToken, ^{ 486 | [self tly_swizzleInstanceMethod:@selector(viewWillAppear:) withReplacement:@selector(tly_swizzledViewWillAppear:)]; 487 | [self tly_swizzleInstanceMethod:@selector(viewWillLayoutSubviews) withReplacement:@selector(tly_swizzledViewDidLayoutSubviews)]; 488 | [self tly_swizzleInstanceMethod:@selector(viewWillDisappear:) withReplacement:@selector(tly_swizzledViewWillDisappear:)]; 489 | }); 490 | } 491 | 492 | #pragma mark - Swizzled View Life Cycle 493 | 494 | - (void)tly_swizzledViewWillAppear:(BOOL)animated 495 | { 496 | [[self _internalShyNavBarManager] prepareForDisplay]; 497 | [self tly_swizzledViewWillAppear:animated]; 498 | } 499 | 500 | - (void)tly_swizzledViewDidLayoutSubviews 501 | { 502 | [[self _internalShyNavBarManager] layoutViews]; 503 | [self tly_swizzledViewDidLayoutSubviews]; 504 | } 505 | 506 | - (void)tly_swizzledViewWillDisappear:(BOOL)animated 507 | { 508 | [[self _internalShyNavBarManager] cleanup]; 509 | [self tly_swizzledViewWillDisappear:animated]; 510 | } 511 | 512 | #pragma mark - Public methods 513 | 514 | - (BOOL)isShyNavBarManagerPresent 515 | { 516 | return [self _internalShyNavBarManager] != nil; 517 | } 518 | 519 | - (void)setShyNavBarManager:(TLYShyNavBarManager *)shyNavBarManager 520 | viewController:(UIViewController *)viewController 521 | { 522 | NSAssert(viewController != nil, @"viewController must not be nil!"); 523 | shyNavBarManager.viewController = viewController; 524 | objc_setAssociatedObject(self, ­NavBarManagerKey, shyNavBarManager, OBJC_ASSOCIATION_RETAIN_NONATOMIC); 525 | } 526 | 527 | #pragma mark - Properties 528 | 529 | - (void)setShyNavBarManager:(TLYShyNavBarManager *)shyNavBarManager 530 | { 531 | [self setShyNavBarManager:shyNavBarManager viewController:self]; 532 | } 533 | 534 | - (TLYShyNavBarManager *)shyNavBarManager 535 | { 536 | id shyNavBarManager = objc_getAssociatedObject(self, ­NavBarManagerKey); 537 | if (!shyNavBarManager) 538 | { 539 | shyNavBarManager = [[TLYShyNavBarManager alloc] init]; 540 | self.shyNavBarManager = shyNavBarManager; 541 | } 542 | 543 | return shyNavBarManager; 544 | } 545 | 546 | #pragma mark - Private methods 547 | 548 | /* Internally, we need to access the variable without creating it */ 549 | - (TLYShyNavBarManager *)_internalShyNavBarManager 550 | { 551 | return objc_getAssociatedObject(self, ­NavBarManagerKey); 552 | } 553 | 554 | @end 555 | 556 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 34B750E11D6C92AA00093AC6 /* TLYPopoverSegue.m in Sources */ = {isa = PBXBuildFile; fileRef = 34B750E01D6C92AA00093AC6 /* TLYPopoverSegue.m */; }; 11 | 821A4D771BF6CCEC00E675DB /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 821A4D761BF6CCEC00E675DB /* LaunchScreen.storyboard */; }; 12 | 821A4D7B1BF6D01600E675DB /* TLYTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D7A1BF6D01600E675DB /* TLYTableViewController.m */; }; 13 | 821A4D7F1BF6D70100E675DB /* TLYShyStatusBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D7E1BF6D70100E675DB /* TLYShyStatusBarController.m */; }; 14 | 821A4D841BF6D89E00E675DB /* TLYShyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D831BF6D89E00E675DB /* TLYShyViewController.m */; }; 15 | 821A4D881BF6DA2700E675DB /* UIScrollView+Helpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D871BF6DA2700E675DB /* UIScrollView+Helpers.m */; }; 16 | 821A4D8B1BF6E5D400E675DB /* TLYDelegateProxy.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D8A1BF6E5D400E675DB /* TLYDelegateProxy.m */; }; 17 | 821A4D901BF6F3DF00E675DB /* TLYShyScrollViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 821A4D8F1BF6F3DF00E675DB /* TLYShyScrollViewController.m */; }; 18 | 8262C8551BD730DD00B610A0 /* TLYCollectionViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 8262C8541BD730DD00B610A0 /* TLYCollectionViewController.m */; }; 19 | 8268FA13194DBA58004EC0E4 /* TLYShyNavBarManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 8268FA12194DBA58004EC0E4 /* TLYShyNavBarManager.m */; }; 20 | 828F57201949C37B009EB8DD /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F571F1949C37B009EB8DD /* Foundation.framework */; }; 21 | 828F57221949C37B009EB8DD /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F57211949C37B009EB8DD /* CoreGraphics.framework */; }; 22 | 828F57241949C37B009EB8DD /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F57231949C37B009EB8DD /* UIKit.framework */; }; 23 | 828F572A1949C37B009EB8DD /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 828F57281949C37B009EB8DD /* InfoPlist.strings */; }; 24 | 828F572C1949C37B009EB8DD /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 828F572B1949C37B009EB8DD /* main.m */; }; 25 | 828F57301949C37B009EB8DD /* TLYAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 828F572F1949C37B009EB8DD /* TLYAppDelegate.m */; }; 26 | 828F57331949C37B009EB8DD /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 828F57311949C37B009EB8DD /* Main.storyboard */; }; 27 | 828F57361949C37B009EB8DD /* TLYViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 828F57351949C37B009EB8DD /* TLYViewController.m */; }; 28 | 828F57381949C37B009EB8DD /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 828F57371949C37B009EB8DD /* Images.xcassets */; }; 29 | 828F573F1949C37B009EB8DD /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F573E1949C37B009EB8DD /* XCTest.framework */; }; 30 | 828F57401949C37B009EB8DD /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F571F1949C37B009EB8DD /* Foundation.framework */; }; 31 | 828F57411949C37B009EB8DD /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 828F57231949C37B009EB8DD /* UIKit.framework */; }; 32 | 828F57491949C37B009EB8DD /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 828F57471949C37B009EB8DD /* InfoPlist.strings */; }; 33 | 828F574B1949C37B009EB8DD /* TLYShyNavBarDemoTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 828F574A1949C37B009EB8DD /* TLYShyNavBarDemoTests.m */; }; 34 | 829FEE001957DF620017E186 /* NSObject+TLYSwizzlingHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 829FEDFF1957DF620017E186 /* NSObject+TLYSwizzlingHelpers.m */; }; 35 | 82A893861BC6F939004C37E3 /* TLYMenuTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 82A893851BC6F939004C37E3 /* TLYMenuTableViewController.m */; }; 36 | 82C882091955FDA60046C49D /* UIViewController+BetterLayoutGuides.m in Sources */ = {isa = PBXBuildFile; fileRef = 82C882081955FDA60046C49D /* UIViewController+BetterLayoutGuides.m */; }; 37 | /* End PBXBuildFile section */ 38 | 39 | /* Begin PBXContainerItemProxy section */ 40 | 828F57421949C37B009EB8DD /* PBXContainerItemProxy */ = { 41 | isa = PBXContainerItemProxy; 42 | containerPortal = 828F57141949C37B009EB8DD /* Project object */; 43 | proxyType = 1; 44 | remoteGlobalIDString = 828F571B1949C37B009EB8DD; 45 | remoteInfo = TLYShyNavBarDemo; 46 | }; 47 | /* End PBXContainerItemProxy section */ 48 | 49 | /* Begin PBXFileReference section */ 50 | 34B750DF1D6C92AA00093AC6 /* TLYPopoverSegue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYPopoverSegue.h; sourceTree = ""; }; 51 | 34B750E01D6C92AA00093AC6 /* TLYPopoverSegue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYPopoverSegue.m; sourceTree = ""; }; 52 | 821A4D761BF6CCEC00E675DB /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = LaunchScreen.storyboard; sourceTree = ""; }; 53 | 821A4D791BF6D01600E675DB /* TLYTableViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYTableViewController.h; sourceTree = ""; }; 54 | 821A4D7A1BF6D01600E675DB /* TLYTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYTableViewController.m; sourceTree = ""; }; 55 | 821A4D7D1BF6D70100E675DB /* TLYShyStatusBarController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyStatusBarController.h; sourceTree = ""; }; 56 | 821A4D7E1BF6D70100E675DB /* TLYShyStatusBarController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyStatusBarController.m; sourceTree = ""; }; 57 | 821A4D801BF6D72900E675DB /* TLYShyParent.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYShyParent.h; sourceTree = ""; }; 58 | 821A4D821BF6D89E00E675DB /* TLYShyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyViewController.h; sourceTree = ""; }; 59 | 821A4D831BF6D89E00E675DB /* TLYShyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyViewController.m; sourceTree = ""; }; 60 | 821A4D861BF6DA2700E675DB /* UIScrollView+Helpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIScrollView+Helpers.h"; sourceTree = ""; }; 61 | 821A4D871BF6DA2700E675DB /* UIScrollView+Helpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIScrollView+Helpers.m"; sourceTree = ""; }; 62 | 821A4D891BF6E5D400E675DB /* TLYDelegateProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYDelegateProxy.h; sourceTree = ""; }; 63 | 821A4D8A1BF6E5D400E675DB /* TLYDelegateProxy.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYDelegateProxy.m; sourceTree = ""; }; 64 | 821A4D8C1BF6E5F300E675DB /* TLYShyNavBarFade.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarFade.h; sourceTree = ""; }; 65 | 821A4D8D1BF6EDE800E675DB /* TLYShyChild.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYShyChild.h; sourceTree = ""; }; 66 | 821A4D8E1BF6F3DF00E675DB /* TLYShyScrollViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyScrollViewController.h; sourceTree = ""; }; 67 | 821A4D8F1BF6F3DF00E675DB /* TLYShyScrollViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyScrollViewController.m; sourceTree = ""; }; 68 | 8262C8531BD730DD00B610A0 /* TLYCollectionViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYCollectionViewController.h; sourceTree = ""; }; 69 | 8262C8541BD730DD00B610A0 /* TLYCollectionViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYCollectionViewController.m; sourceTree = ""; }; 70 | 8268FA11194DBA58004EC0E4 /* TLYShyNavBarManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarManager.h; sourceTree = ""; }; 71 | 8268FA12194DBA58004EC0E4 /* TLYShyNavBarManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyNavBarManager.m; sourceTree = ""; }; 72 | 828F571C1949C37B009EB8DD /* TLYShyNavBarDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TLYShyNavBarDemo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 73 | 828F571F1949C37B009EB8DD /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 74 | 828F57211949C37B009EB8DD /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 75 | 828F57231949C37B009EB8DD /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 76 | 828F57271949C37B009EB8DD /* TLYShyNavBarDemo-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "TLYShyNavBarDemo-Info.plist"; sourceTree = ""; }; 77 | 828F57291949C37B009EB8DD /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 78 | 828F572B1949C37B009EB8DD /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 79 | 828F572D1949C37B009EB8DD /* TLYShyNavBarDemo-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "TLYShyNavBarDemo-Prefix.pch"; sourceTree = ""; }; 80 | 828F572E1949C37B009EB8DD /* TLYAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYAppDelegate.h; sourceTree = ""; }; 81 | 828F572F1949C37B009EB8DD /* TLYAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TLYAppDelegate.m; sourceTree = ""; }; 82 | 828F57321949C37B009EB8DD /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 83 | 828F57341949C37B009EB8DD /* TLYViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TLYViewController.h; sourceTree = ""; }; 84 | 828F57351949C37B009EB8DD /* TLYViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TLYViewController.m; sourceTree = ""; }; 85 | 828F57371949C37B009EB8DD /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 86 | 828F573D1949C37B009EB8DD /* TLYShyNavBarDemoTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TLYShyNavBarDemoTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 87 | 828F573E1949C37B009EB8DD /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; }; 88 | 828F57461949C37B009EB8DD /* TLYShyNavBarDemoTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "TLYShyNavBarDemoTests-Info.plist"; sourceTree = ""; }; 89 | 828F57481949C37B009EB8DD /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 90 | 828F574A1949C37B009EB8DD /* TLYShyNavBarDemoTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TLYShyNavBarDemoTests.m; sourceTree = ""; }; 91 | 829FEDFE1957DF620017E186 /* NSObject+TLYSwizzlingHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+TLYSwizzlingHelpers.h"; sourceTree = ""; }; 92 | 829FEDFF1957DF620017E186 /* NSObject+TLYSwizzlingHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+TLYSwizzlingHelpers.m"; sourceTree = ""; }; 93 | 82A893841BC6F939004C37E3 /* TLYMenuTableViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYMenuTableViewController.h; sourceTree = ""; }; 94 | 82A893851BC6F939004C37E3 /* TLYMenuTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYMenuTableViewController.m; sourceTree = ""; }; 95 | 82C882071955FDA60046C49D /* UIViewController+BetterLayoutGuides.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIViewController+BetterLayoutGuides.h"; sourceTree = ""; }; 96 | 82C882081955FDA60046C49D /* UIViewController+BetterLayoutGuides.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIViewController+BetterLayoutGuides.m"; sourceTree = ""; }; 97 | /* End PBXFileReference section */ 98 | 99 | /* Begin PBXFrameworksBuildPhase section */ 100 | 828F57191949C37B009EB8DD /* Frameworks */ = { 101 | isa = PBXFrameworksBuildPhase; 102 | buildActionMask = 2147483647; 103 | files = ( 104 | 828F57221949C37B009EB8DD /* CoreGraphics.framework in Frameworks */, 105 | 828F57241949C37B009EB8DD /* UIKit.framework in Frameworks */, 106 | 828F57201949C37B009EB8DD /* Foundation.framework in Frameworks */, 107 | ); 108 | runOnlyForDeploymentPostprocessing = 0; 109 | }; 110 | 828F573A1949C37B009EB8DD /* Frameworks */ = { 111 | isa = PBXFrameworksBuildPhase; 112 | buildActionMask = 2147483647; 113 | files = ( 114 | 828F573F1949C37B009EB8DD /* XCTest.framework in Frameworks */, 115 | 828F57411949C37B009EB8DD /* UIKit.framework in Frameworks */, 116 | 828F57401949C37B009EB8DD /* Foundation.framework in Frameworks */, 117 | ); 118 | runOnlyForDeploymentPostprocessing = 0; 119 | }; 120 | /* End PBXFrameworksBuildPhase section */ 121 | 122 | /* Begin PBXGroup section */ 123 | 821A4D781BF6CFF200E675DB /* TableView */ = { 124 | isa = PBXGroup; 125 | children = ( 126 | 821A4D791BF6D01600E675DB /* TLYTableViewController.h */, 127 | 821A4D7A1BF6D01600E675DB /* TLYTableViewController.m */, 128 | ); 129 | name = TableView; 130 | sourceTree = ""; 131 | }; 132 | 821A4D7C1BF6D6D200E675DB /* ShyControllers */ = { 133 | isa = PBXGroup; 134 | children = ( 135 | 821A4D801BF6D72900E675DB /* TLYShyParent.h */, 136 | 821A4D8D1BF6EDE800E675DB /* TLYShyChild.h */, 137 | 821A4D7D1BF6D70100E675DB /* TLYShyStatusBarController.h */, 138 | 821A4D7E1BF6D70100E675DB /* TLYShyStatusBarController.m */, 139 | 821A4D821BF6D89E00E675DB /* TLYShyViewController.h */, 140 | 821A4D831BF6D89E00E675DB /* TLYShyViewController.m */, 141 | 821A4D8E1BF6F3DF00E675DB /* TLYShyScrollViewController.h */, 142 | 821A4D8F1BF6F3DF00E675DB /* TLYShyScrollViewController.m */, 143 | ); 144 | path = ShyControllers; 145 | sourceTree = ""; 146 | }; 147 | 8262C8521BD730CB00B610A0 /* CollectionView */ = { 148 | isa = PBXGroup; 149 | children = ( 150 | 8262C8531BD730DD00B610A0 /* TLYCollectionViewController.h */, 151 | 8262C8541BD730DD00B610A0 /* TLYCollectionViewController.m */, 152 | ); 153 | name = CollectionView; 154 | sourceTree = ""; 155 | }; 156 | 828F57131949C37B009EB8DD = { 157 | isa = PBXGroup; 158 | children = ( 159 | 828F57541949C381009EB8DD /* TLYShyNavBar */, 160 | 828F57251949C37B009EB8DD /* TLYShyNavBarDemo */, 161 | 828F57441949C37B009EB8DD /* TLYShyNavBarDemoTests */, 162 | 828F571E1949C37B009EB8DD /* Frameworks */, 163 | 828F571D1949C37B009EB8DD /* Products */, 164 | ); 165 | sourceTree = ""; 166 | }; 167 | 828F571D1949C37B009EB8DD /* Products */ = { 168 | isa = PBXGroup; 169 | children = ( 170 | 828F571C1949C37B009EB8DD /* TLYShyNavBarDemo.app */, 171 | 828F573D1949C37B009EB8DD /* TLYShyNavBarDemoTests.xctest */, 172 | ); 173 | name = Products; 174 | sourceTree = ""; 175 | }; 176 | 828F571E1949C37B009EB8DD /* Frameworks */ = { 177 | isa = PBXGroup; 178 | children = ( 179 | 828F571F1949C37B009EB8DD /* Foundation.framework */, 180 | 828F57211949C37B009EB8DD /* CoreGraphics.framework */, 181 | 828F57231949C37B009EB8DD /* UIKit.framework */, 182 | 828F573E1949C37B009EB8DD /* XCTest.framework */, 183 | ); 184 | name = Frameworks; 185 | sourceTree = ""; 186 | }; 187 | 828F57251949C37B009EB8DD /* TLYShyNavBarDemo */ = { 188 | isa = PBXGroup; 189 | children = ( 190 | 821A4D781BF6CFF200E675DB /* TableView */, 191 | 8262C8521BD730CB00B610A0 /* CollectionView */, 192 | 828F572E1949C37B009EB8DD /* TLYAppDelegate.h */, 193 | 828F572F1949C37B009EB8DD /* TLYAppDelegate.m */, 194 | 828F57311949C37B009EB8DD /* Main.storyboard */, 195 | 34B750DF1D6C92AA00093AC6 /* TLYPopoverSegue.h */, 196 | 34B750E01D6C92AA00093AC6 /* TLYPopoverSegue.m */, 197 | 82A893841BC6F939004C37E3 /* TLYMenuTableViewController.h */, 198 | 82A893851BC6F939004C37E3 /* TLYMenuTableViewController.m */, 199 | 828F57341949C37B009EB8DD /* TLYViewController.h */, 200 | 828F57351949C37B009EB8DD /* TLYViewController.m */, 201 | 828F57371949C37B009EB8DD /* Images.xcassets */, 202 | 828F57261949C37B009EB8DD /* Supporting Files */, 203 | ); 204 | path = TLYShyNavBarDemo; 205 | sourceTree = ""; 206 | }; 207 | 828F57261949C37B009EB8DD /* Supporting Files */ = { 208 | isa = PBXGroup; 209 | children = ( 210 | 828F57271949C37B009EB8DD /* TLYShyNavBarDemo-Info.plist */, 211 | 821A4D761BF6CCEC00E675DB /* LaunchScreen.storyboard */, 212 | 828F57281949C37B009EB8DD /* InfoPlist.strings */, 213 | 828F572B1949C37B009EB8DD /* main.m */, 214 | 828F572D1949C37B009EB8DD /* TLYShyNavBarDemo-Prefix.pch */, 215 | ); 216 | name = "Supporting Files"; 217 | sourceTree = ""; 218 | }; 219 | 828F57441949C37B009EB8DD /* TLYShyNavBarDemoTests */ = { 220 | isa = PBXGroup; 221 | children = ( 222 | 828F574A1949C37B009EB8DD /* TLYShyNavBarDemoTests.m */, 223 | 828F57451949C37B009EB8DD /* Supporting Files */, 224 | ); 225 | path = TLYShyNavBarDemoTests; 226 | sourceTree = ""; 227 | }; 228 | 828F57451949C37B009EB8DD /* Supporting Files */ = { 229 | isa = PBXGroup; 230 | children = ( 231 | 828F57461949C37B009EB8DD /* TLYShyNavBarDemoTests-Info.plist */, 232 | 828F57471949C37B009EB8DD /* InfoPlist.strings */, 233 | ); 234 | name = "Supporting Files"; 235 | sourceTree = ""; 236 | }; 237 | 828F57541949C381009EB8DD /* TLYShyNavBar */ = { 238 | isa = PBXGroup; 239 | children = ( 240 | 821A4D7C1BF6D6D200E675DB /* ShyControllers */, 241 | 82B01EDB195D580000C3C10C /* Categories */, 242 | 821A4D8C1BF6E5F300E675DB /* TLYShyNavBarFade.h */, 243 | 8268FA11194DBA58004EC0E4 /* TLYShyNavBarManager.h */, 244 | 8268FA12194DBA58004EC0E4 /* TLYShyNavBarManager.m */, 245 | ); 246 | name = TLYShyNavBar; 247 | path = ../TLYShyNavBar; 248 | sourceTree = ""; 249 | }; 250 | 82B01EDB195D580000C3C10C /* Categories */ = { 251 | isa = PBXGroup; 252 | children = ( 253 | 821A4D891BF6E5D400E675DB /* TLYDelegateProxy.h */, 254 | 821A4D8A1BF6E5D400E675DB /* TLYDelegateProxy.m */, 255 | 82C882071955FDA60046C49D /* UIViewController+BetterLayoutGuides.h */, 256 | 82C882081955FDA60046C49D /* UIViewController+BetterLayoutGuides.m */, 257 | 829FEDFE1957DF620017E186 /* NSObject+TLYSwizzlingHelpers.h */, 258 | 829FEDFF1957DF620017E186 /* NSObject+TLYSwizzlingHelpers.m */, 259 | 821A4D861BF6DA2700E675DB /* UIScrollView+Helpers.h */, 260 | 821A4D871BF6DA2700E675DB /* UIScrollView+Helpers.m */, 261 | ); 262 | path = Categories; 263 | sourceTree = ""; 264 | }; 265 | /* End PBXGroup section */ 266 | 267 | /* Begin PBXNativeTarget section */ 268 | 828F571B1949C37B009EB8DD /* TLYShyNavBarDemo */ = { 269 | isa = PBXNativeTarget; 270 | buildConfigurationList = 828F574E1949C37B009EB8DD /* Build configuration list for PBXNativeTarget "TLYShyNavBarDemo" */; 271 | buildPhases = ( 272 | 828F57181949C37B009EB8DD /* Sources */, 273 | 828F57191949C37B009EB8DD /* Frameworks */, 274 | 828F571A1949C37B009EB8DD /* Resources */, 275 | ); 276 | buildRules = ( 277 | ); 278 | dependencies = ( 279 | ); 280 | name = TLYShyNavBarDemo; 281 | productName = TLYShyNavBarDemo; 282 | productReference = 828F571C1949C37B009EB8DD /* TLYShyNavBarDemo.app */; 283 | productType = "com.apple.product-type.application"; 284 | }; 285 | 828F573C1949C37B009EB8DD /* TLYShyNavBarDemoTests */ = { 286 | isa = PBXNativeTarget; 287 | buildConfigurationList = 828F57511949C37B009EB8DD /* Build configuration list for PBXNativeTarget "TLYShyNavBarDemoTests" */; 288 | buildPhases = ( 289 | 828F57391949C37B009EB8DD /* Sources */, 290 | 828F573A1949C37B009EB8DD /* Frameworks */, 291 | 828F573B1949C37B009EB8DD /* Resources */, 292 | ); 293 | buildRules = ( 294 | ); 295 | dependencies = ( 296 | 828F57431949C37B009EB8DD /* PBXTargetDependency */, 297 | ); 298 | name = TLYShyNavBarDemoTests; 299 | productName = TLYShyNavBarDemoTests; 300 | productReference = 828F573D1949C37B009EB8DD /* TLYShyNavBarDemoTests.xctest */; 301 | productType = "com.apple.product-type.bundle.unit-test"; 302 | }; 303 | /* End PBXNativeTarget section */ 304 | 305 | /* Begin PBXProject section */ 306 | 828F57141949C37B009EB8DD /* Project object */ = { 307 | isa = PBXProject; 308 | attributes = { 309 | CLASSPREFIX = TLY; 310 | LastUpgradeCheck = 0700; 311 | ORGANIZATIONNAME = "Telly, Inc."; 312 | TargetAttributes = { 313 | 828F573C1949C37B009EB8DD = { 314 | TestTargetID = 828F571B1949C37B009EB8DD; 315 | }; 316 | }; 317 | }; 318 | buildConfigurationList = 828F57171949C37B009EB8DD /* Build configuration list for PBXProject "TLYShyNavBarDemo" */; 319 | compatibilityVersion = "Xcode 3.2"; 320 | developmentRegion = English; 321 | hasScannedForEncodings = 0; 322 | knownRegions = ( 323 | en, 324 | Base, 325 | ); 326 | mainGroup = 828F57131949C37B009EB8DD; 327 | productRefGroup = 828F571D1949C37B009EB8DD /* Products */; 328 | projectDirPath = ""; 329 | projectRoot = ""; 330 | targets = ( 331 | 828F571B1949C37B009EB8DD /* TLYShyNavBarDemo */, 332 | 828F573C1949C37B009EB8DD /* TLYShyNavBarDemoTests */, 333 | ); 334 | }; 335 | /* End PBXProject section */ 336 | 337 | /* Begin PBXResourcesBuildPhase section */ 338 | 828F571A1949C37B009EB8DD /* Resources */ = { 339 | isa = PBXResourcesBuildPhase; 340 | buildActionMask = 2147483647; 341 | files = ( 342 | 828F57381949C37B009EB8DD /* Images.xcassets in Resources */, 343 | 821A4D771BF6CCEC00E675DB /* LaunchScreen.storyboard in Resources */, 344 | 828F572A1949C37B009EB8DD /* InfoPlist.strings in Resources */, 345 | 828F57331949C37B009EB8DD /* Main.storyboard in Resources */, 346 | ); 347 | runOnlyForDeploymentPostprocessing = 0; 348 | }; 349 | 828F573B1949C37B009EB8DD /* Resources */ = { 350 | isa = PBXResourcesBuildPhase; 351 | buildActionMask = 2147483647; 352 | files = ( 353 | 828F57491949C37B009EB8DD /* InfoPlist.strings in Resources */, 354 | ); 355 | runOnlyForDeploymentPostprocessing = 0; 356 | }; 357 | /* End PBXResourcesBuildPhase section */ 358 | 359 | /* Begin PBXSourcesBuildPhase section */ 360 | 828F57181949C37B009EB8DD /* Sources */ = { 361 | isa = PBXSourcesBuildPhase; 362 | buildActionMask = 2147483647; 363 | files = ( 364 | 82A893861BC6F939004C37E3 /* TLYMenuTableViewController.m in Sources */, 365 | 821A4D8B1BF6E5D400E675DB /* TLYDelegateProxy.m in Sources */, 366 | 821A4D7B1BF6D01600E675DB /* TLYTableViewController.m in Sources */, 367 | 8268FA13194DBA58004EC0E4 /* TLYShyNavBarManager.m in Sources */, 368 | 82C882091955FDA60046C49D /* UIViewController+BetterLayoutGuides.m in Sources */, 369 | 34B750E11D6C92AA00093AC6 /* TLYPopoverSegue.m in Sources */, 370 | 821A4D7F1BF6D70100E675DB /* TLYShyStatusBarController.m in Sources */, 371 | 828F57301949C37B009EB8DD /* TLYAppDelegate.m in Sources */, 372 | 829FEE001957DF620017E186 /* NSObject+TLYSwizzlingHelpers.m in Sources */, 373 | 821A4D901BF6F3DF00E675DB /* TLYShyScrollViewController.m in Sources */, 374 | 828F57361949C37B009EB8DD /* TLYViewController.m in Sources */, 375 | 821A4D841BF6D89E00E675DB /* TLYShyViewController.m in Sources */, 376 | 8262C8551BD730DD00B610A0 /* TLYCollectionViewController.m in Sources */, 377 | 828F572C1949C37B009EB8DD /* main.m in Sources */, 378 | 821A4D881BF6DA2700E675DB /* UIScrollView+Helpers.m in Sources */, 379 | ); 380 | runOnlyForDeploymentPostprocessing = 0; 381 | }; 382 | 828F57391949C37B009EB8DD /* Sources */ = { 383 | isa = PBXSourcesBuildPhase; 384 | buildActionMask = 2147483647; 385 | files = ( 386 | 828F574B1949C37B009EB8DD /* TLYShyNavBarDemoTests.m in Sources */, 387 | ); 388 | runOnlyForDeploymentPostprocessing = 0; 389 | }; 390 | /* End PBXSourcesBuildPhase section */ 391 | 392 | /* Begin PBXTargetDependency section */ 393 | 828F57431949C37B009EB8DD /* PBXTargetDependency */ = { 394 | isa = PBXTargetDependency; 395 | target = 828F571B1949C37B009EB8DD /* TLYShyNavBarDemo */; 396 | targetProxy = 828F57421949C37B009EB8DD /* PBXContainerItemProxy */; 397 | }; 398 | /* End PBXTargetDependency section */ 399 | 400 | /* Begin PBXVariantGroup section */ 401 | 828F57281949C37B009EB8DD /* InfoPlist.strings */ = { 402 | isa = PBXVariantGroup; 403 | children = ( 404 | 828F57291949C37B009EB8DD /* en */, 405 | ); 406 | name = InfoPlist.strings; 407 | sourceTree = ""; 408 | }; 409 | 828F57311949C37B009EB8DD /* Main.storyboard */ = { 410 | isa = PBXVariantGroup; 411 | children = ( 412 | 828F57321949C37B009EB8DD /* Base */, 413 | ); 414 | name = Main.storyboard; 415 | sourceTree = ""; 416 | }; 417 | 828F57471949C37B009EB8DD /* InfoPlist.strings */ = { 418 | isa = PBXVariantGroup; 419 | children = ( 420 | 828F57481949C37B009EB8DD /* en */, 421 | ); 422 | name = InfoPlist.strings; 423 | sourceTree = ""; 424 | }; 425 | /* End PBXVariantGroup section */ 426 | 427 | /* Begin XCBuildConfiguration section */ 428 | 828F574C1949C37B009EB8DD /* Debug */ = { 429 | isa = XCBuildConfiguration; 430 | buildSettings = { 431 | ALWAYS_SEARCH_USER_PATHS = NO; 432 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 433 | CLANG_CXX_LIBRARY = "libc++"; 434 | CLANG_ENABLE_MODULES = YES; 435 | CLANG_ENABLE_OBJC_ARC = YES; 436 | CLANG_WARN_BOOL_CONVERSION = YES; 437 | CLANG_WARN_CONSTANT_CONVERSION = YES; 438 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 439 | CLANG_WARN_EMPTY_BODY = YES; 440 | CLANG_WARN_ENUM_CONVERSION = YES; 441 | CLANG_WARN_INT_CONVERSION = YES; 442 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 443 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 444 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 445 | COPY_PHASE_STRIP = NO; 446 | ENABLE_TESTABILITY = YES; 447 | GCC_C_LANGUAGE_STANDARD = gnu99; 448 | GCC_DYNAMIC_NO_PIC = NO; 449 | GCC_OPTIMIZATION_LEVEL = 0; 450 | GCC_PREPROCESSOR_DEFINITIONS = ( 451 | "DEBUG=1", 452 | "$(inherited)", 453 | ); 454 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 455 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 456 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 457 | GCC_WARN_UNDECLARED_SELECTOR = YES; 458 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 459 | GCC_WARN_UNUSED_FUNCTION = YES; 460 | GCC_WARN_UNUSED_VARIABLE = YES; 461 | IPHONEOS_DEPLOYMENT_TARGET = 7.0; 462 | ONLY_ACTIVE_ARCH = YES; 463 | SDKROOT = iphoneos; 464 | }; 465 | name = Debug; 466 | }; 467 | 828F574D1949C37B009EB8DD /* Release */ = { 468 | isa = XCBuildConfiguration; 469 | buildSettings = { 470 | ALWAYS_SEARCH_USER_PATHS = NO; 471 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 472 | CLANG_CXX_LIBRARY = "libc++"; 473 | CLANG_ENABLE_MODULES = YES; 474 | CLANG_ENABLE_OBJC_ARC = YES; 475 | CLANG_WARN_BOOL_CONVERSION = YES; 476 | CLANG_WARN_CONSTANT_CONVERSION = YES; 477 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 478 | CLANG_WARN_EMPTY_BODY = YES; 479 | CLANG_WARN_ENUM_CONVERSION = YES; 480 | CLANG_WARN_INT_CONVERSION = YES; 481 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 482 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 483 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 484 | COPY_PHASE_STRIP = YES; 485 | ENABLE_NS_ASSERTIONS = NO; 486 | GCC_C_LANGUAGE_STANDARD = gnu99; 487 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 488 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 489 | GCC_WARN_UNDECLARED_SELECTOR = YES; 490 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 491 | GCC_WARN_UNUSED_FUNCTION = YES; 492 | GCC_WARN_UNUSED_VARIABLE = YES; 493 | IPHONEOS_DEPLOYMENT_TARGET = 7.0; 494 | SDKROOT = iphoneos; 495 | VALIDATE_PRODUCT = YES; 496 | }; 497 | name = Release; 498 | }; 499 | 828F574F1949C37B009EB8DD /* Debug */ = { 500 | isa = XCBuildConfiguration; 501 | buildSettings = { 502 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 503 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 504 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 505 | GCC_PREFIX_HEADER = "TLYShyNavBarDemo/TLYShyNavBarDemo-Prefix.pch"; 506 | INFOPLIST_FILE = "TLYShyNavBarDemo/TLYShyNavBarDemo-Info.plist"; 507 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.${PRODUCT_NAME:rfc1034identifier}"; 508 | PRODUCT_NAME = "$(TARGET_NAME)"; 509 | TARGETED_DEVICE_FAMILY = "1,2"; 510 | WRAPPER_EXTENSION = app; 511 | }; 512 | name = Debug; 513 | }; 514 | 828F57501949C37B009EB8DD /* Release */ = { 515 | isa = XCBuildConfiguration; 516 | buildSettings = { 517 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 518 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 519 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 520 | GCC_PREFIX_HEADER = "TLYShyNavBarDemo/TLYShyNavBarDemo-Prefix.pch"; 521 | INFOPLIST_FILE = "TLYShyNavBarDemo/TLYShyNavBarDemo-Info.plist"; 522 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.${PRODUCT_NAME:rfc1034identifier}"; 523 | PRODUCT_NAME = "$(TARGET_NAME)"; 524 | TARGETED_DEVICE_FAMILY = "1,2"; 525 | WRAPPER_EXTENSION = app; 526 | }; 527 | name = Release; 528 | }; 529 | 828F57521949C37B009EB8DD /* Debug */ = { 530 | isa = XCBuildConfiguration; 531 | buildSettings = { 532 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/TLYShyNavBarDemo.app/TLYShyNavBarDemo"; 533 | FRAMEWORK_SEARCH_PATHS = ( 534 | "$(SDKROOT)/Developer/Library/Frameworks", 535 | "$(inherited)", 536 | "$(DEVELOPER_FRAMEWORKS_DIR)", 537 | ); 538 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 539 | GCC_PREFIX_HEADER = "TLYShyNavBarDemo/TLYShyNavBarDemo-Prefix.pch"; 540 | GCC_PREPROCESSOR_DEFINITIONS = ( 541 | "DEBUG=1", 542 | "$(inherited)", 543 | ); 544 | INFOPLIST_FILE = "TLYShyNavBarDemoTests/TLYShyNavBarDemoTests-Info.plist"; 545 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.${PRODUCT_NAME:rfc1034identifier}"; 546 | PRODUCT_NAME = "$(TARGET_NAME)"; 547 | TEST_HOST = "$(BUNDLE_LOADER)"; 548 | WRAPPER_EXTENSION = xctest; 549 | }; 550 | name = Debug; 551 | }; 552 | 828F57531949C37B009EB8DD /* Release */ = { 553 | isa = XCBuildConfiguration; 554 | buildSettings = { 555 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/TLYShyNavBarDemo.app/TLYShyNavBarDemo"; 556 | FRAMEWORK_SEARCH_PATHS = ( 557 | "$(SDKROOT)/Developer/Library/Frameworks", 558 | "$(inherited)", 559 | "$(DEVELOPER_FRAMEWORKS_DIR)", 560 | ); 561 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 562 | GCC_PREFIX_HEADER = "TLYShyNavBarDemo/TLYShyNavBarDemo-Prefix.pch"; 563 | INFOPLIST_FILE = "TLYShyNavBarDemoTests/TLYShyNavBarDemoTests-Info.plist"; 564 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.${PRODUCT_NAME:rfc1034identifier}"; 565 | PRODUCT_NAME = "$(TARGET_NAME)"; 566 | TEST_HOST = "$(BUNDLE_LOADER)"; 567 | WRAPPER_EXTENSION = xctest; 568 | }; 569 | name = Release; 570 | }; 571 | /* End XCBuildConfiguration section */ 572 | 573 | /* Begin XCConfigurationList section */ 574 | 828F57171949C37B009EB8DD /* Build configuration list for PBXProject "TLYShyNavBarDemo" */ = { 575 | isa = XCConfigurationList; 576 | buildConfigurations = ( 577 | 828F574C1949C37B009EB8DD /* Debug */, 578 | 828F574D1949C37B009EB8DD /* Release */, 579 | ); 580 | defaultConfigurationIsVisible = 0; 581 | defaultConfigurationName = Release; 582 | }; 583 | 828F574E1949C37B009EB8DD /* Build configuration list for PBXNativeTarget "TLYShyNavBarDemo" */ = { 584 | isa = XCConfigurationList; 585 | buildConfigurations = ( 586 | 828F574F1949C37B009EB8DD /* Debug */, 587 | 828F57501949C37B009EB8DD /* Release */, 588 | ); 589 | defaultConfigurationIsVisible = 0; 590 | defaultConfigurationName = Release; 591 | }; 592 | 828F57511949C37B009EB8DD /* Build configuration list for PBXNativeTarget "TLYShyNavBarDemoTests" */ = { 593 | isa = XCConfigurationList; 594 | buildConfigurations = ( 595 | 828F57521949C37B009EB8DD /* Debug */, 596 | 828F57531949C37B009EB8DD /* Release */, 597 | ); 598 | defaultConfigurationIsVisible = 0; 599 | defaultConfigurationName = Release; 600 | }; 601 | /* End XCConfigurationList section */ 602 | }; 603 | rootObject = 828F57141949C37B009EB8DD /* Project object */; 604 | } 605 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo.xcodeproj/project.xcworkspace/xcshareddata/TLYShyNavBarDemo.xccheckout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDESourceControlProjectFavoriteDictionaryKey 6 | 7 | IDESourceControlProjectIdentifier 8 | DE065B61-6974-40CD-8DE2-36E0AE0323BB 9 | IDESourceControlProjectName 10 | TLYShyNavBarDemo 11 | IDESourceControlProjectOriginsDictionary 12 | 13 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 14 | github.com:telly/TLYShyNavBar.git 15 | 16 | IDESourceControlProjectPath 17 | TLYShyNavBarDemo/TLYShyNavBarDemo.xcodeproj 18 | IDESourceControlProjectRelativeInstallPathDictionary 19 | 20 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 21 | ../../.. 22 | 23 | IDESourceControlProjectURL 24 | github.com:telly/TLYShyNavBar.git 25 | IDESourceControlProjectVersion 26 | 111 27 | IDESourceControlProjectWCCIdentifier 28 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 29 | IDESourceControlProjectWCConfigurations 30 | 31 | 32 | IDESourceControlRepositoryExtensionIdentifierKey 33 | public.vcs.git 34 | IDESourceControlWCCIdentifierKey 35 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 36 | IDESourceControlWCCName 37 | TLYShyNavBar 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "40x40", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "60x60", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "60x60", 21 | "scale" : "3x" 22 | } 23 | ], 24 | "info" : { 25 | "version" : 1, 26 | "author" : "xcode" 27 | } 28 | } -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/Images.xcassets/LaunchImage.launchimage/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "orientation" : "portrait", 5 | "idiom" : "iphone", 6 | "extent" : "full-screen", 7 | "minimum-system-version" : "7.0", 8 | "scale" : "2x" 9 | }, 10 | { 11 | "orientation" : "portrait", 12 | "idiom" : "iphone", 13 | "subtype" : "retina4", 14 | "extent" : "full-screen", 15 | "minimum-system-version" : "7.0", 16 | "scale" : "2x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/Images.xcassets/sample.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "scale" : "1x" 6 | }, 7 | { 8 | "idiom" : "universal", 9 | "scale" : "2x", 10 | "filename" : "sample@2x.png" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/Images.xcassets/sample.imageset/sample@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/TLYShyNavBarDemo/TLYShyNavBarDemo/Images.xcassets/sample.imageset/sample@2x.png -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 27 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYAppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYAppDelegate.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYAppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYAppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYAppDelegate.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYAppDelegate.h" 10 | 11 | @implementation TLYAppDelegate 12 | 13 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 14 | { 15 | // Override point for customization after application launch. 16 | return YES; 17 | } 18 | 19 | @end 20 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYCollectionViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYCollectionViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 10/20/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYCollectionViewController : UICollectionViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYCollectionViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYCollectionViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 10/20/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYCollectionViewController.h" 10 | 11 | @interface TLYCollectionViewController () 12 | 13 | @property (nonatomic, strong) NSArray *data; 14 | 15 | @end 16 | 17 | @implementation TLYCollectionViewController 18 | 19 | static NSString * const reuseIdentifier = @"Cell"; 20 | 21 | - (void)viewDidLoad { 22 | [super viewDidLoad]; 23 | 24 | self.data = @[@"No Game No Life", 25 | @"Ookami Kodomo no Ame to Yuki", 26 | @"Owari no Seraph", 27 | @"Prince of Tennis", 28 | @"Psycho-Pass", 29 | @"Psycho-Pass 2", 30 | @"School Rumble", 31 | @"Sen to Chihiro no Kamikakushi", 32 | @"Shijou Saikyou no Deshi Kenichi", 33 | @"Shingeki no Kyojin", 34 | @"Soul Eater", 35 | @"Steins;Gate", 36 | @"Summer Wars", 37 | @"Sword Art Online", 38 | @"Sword Art Online II", 39 | @"Tenkuu no Shiro Laputa", 40 | @"Toki wo Kakeru Shoujo", 41 | @"Tokyo Ghoul", 42 | @"Tonari no Totoro", 43 | @"Uchuu Kyoudai", 44 | @"Yakitate!! Japan", 45 | @"Zankyou ", 46 | ]; 47 | 48 | UIView *view = view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth(self.view.bounds), 40.f)]; 49 | view.backgroundColor = [UIColor redColor]; 50 | 51 | 52 | /* Library code */ 53 | self.shyNavBarManager.scrollView = self.collectionView; 54 | /* Can then be remove by setting the ExtensionView to nil */ 55 | [self.shyNavBarManager setExtensionView:view]; 56 | } 57 | 58 | #pragma mark 59 | 60 | - (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section { 61 | return self.data.count; 62 | } 63 | 64 | - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath { 65 | 66 | UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:reuseIdentifier forIndexPath:indexPath]; 67 | 68 | UILabel *label = (id)[cell viewWithTag:777]; 69 | label.text = self.data[indexPath.item]; 70 | 71 | return cell; 72 | } 73 | 74 | @end 75 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYMenuTableViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYMenuTableViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 10/8/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYMenuTableViewController : UITableViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYMenuTableViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYMenuTableViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 10/8/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYMenuTableViewController.h" 10 | 11 | @interface TLYMenuTableViewController () 12 | 13 | @end 14 | 15 | @implementation TLYMenuTableViewController 16 | 17 | #pragma mark - Init & Dealloc 18 | 19 | - (instancetype)initWithCoder:(NSCoder *)coder 20 | { 21 | self = [super initWithCoder:coder]; 22 | if (self) { 23 | self.title = @"Features"; 24 | } 25 | return self; 26 | } 27 | 28 | #pragma mark - Table view data source 29 | 30 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section 31 | { 32 | return 11; 33 | } 34 | 35 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 36 | { 37 | NSString *cellId = [@(indexPath.row) stringValue]; 38 | return [tableView dequeueReusableCellWithIdentifier:cellId forIndexPath:indexPath]; 39 | } 40 | 41 | #pragma mark - Action methods 42 | 43 | - (IBAction)translucencyToggled:(id)sender 44 | { 45 | BOOL translucent = !self.navigationController.navigationBar.translucent; 46 | self.navigationController.navigationBar.translucent = translucent; 47 | 48 | [sender setTitle:translucent ? @"😏" : @"😎"]; 49 | } 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYPopoverSegue.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYPopoverSegue.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Evan Schoenberg on 8/23/16. 6 | // Copyright © 2016 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYPopoverSegue : UIStoryboardSegue 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYPopoverSegue.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYPopoverSegue.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Evan Schoenberg on 8/23/16. 6 | // Copyright © 2016 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYPopoverSegue.h" 10 | 11 | 12 | @implementation TLYPopoverSegue 13 | 14 | - (void)perform 15 | { 16 | UITableViewController *tvc = (UITableViewController *)self.sourceViewController; 17 | UIViewController *dest = self.destinationViewController; 18 | UITableViewCell *cell = [tvc.tableView cellForRowAtIndexPath:[tvc.tableView indexPathForSelectedRow]]; 19 | 20 | UIPopoverController *pop = [[UIPopoverController alloc] initWithContentViewController:dest]; 21 | CGSize size = CGSizeMake(640, 460); 22 | pop.popoverContentSize = size; 23 | 24 | 25 | [pop presentPopoverFromRect:cell.frame 26 | inView:tvc.tableView 27 | permittedArrowDirections:UIPopoverArrowDirectionUp | UIPopoverArrowDirectionDown 28 | animated:YES]; 29 | } 30 | @end 31 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYShyNavBarDemo-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 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UIRequiredDeviceCapabilities 32 | 33 | armv7 34 | 35 | UISupportedInterfaceOrientations 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationLandscapeLeft 39 | UIInterfaceOrientationLandscapeRight 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYShyNavBarDemo-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header 3 | // 4 | // The contents of this file are implicitly included at the beginning of every source file. 5 | // 6 | 7 | #import 8 | 9 | #ifndef __IPHONE_5_0 10 | #warning "This project uses features only available in iOS SDK 5.0 and later." 11 | #endif 12 | 13 | #ifdef __OBJC__ 14 | #import 15 | #import 16 | 17 | #import "TLYShyNavBarManager.h" 18 | #endif 19 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYTableViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYTableViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYTableViewController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYTableViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYTableViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 11/13/15. 6 | // Copyright © 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYTableViewController.h" 10 | 11 | @interface TLYTableViewController () 12 | 13 | @property (nonatomic, assign) IBInspectable int numberOfSections; 14 | @property (nonatomic, assign) IBInspectable int numberOfRowsPerSection; 15 | 16 | @property (nonatomic, weak) IBOutlet UITableView *tableView; 17 | 18 | @end 19 | 20 | @implementation TLYTableViewController 21 | 22 | #pragma mark - View Life Cycle 23 | 24 | - (void)viewDidLoad 25 | { 26 | [super viewDidLoad]; 27 | 28 | UIView *view = view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth(self.view.bounds), 40.f)]; 29 | view.backgroundColor = [UIColor redColor]; 30 | 31 | /* Library code */ 32 | self.shyNavBarManager.scrollView = self.tableView; 33 | /* Can then be remove by setting the ExtensionView to nil */ 34 | [self.shyNavBarManager setExtensionView:view]; 35 | } 36 | 37 | #pragma mark - UITableViewDataSource 38 | 39 | - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView 40 | { 41 | return self.numberOfSections; 42 | } 43 | 44 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section 45 | { 46 | return self.numberOfRowsPerSection; 47 | } 48 | 49 | - (NSString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section 50 | { 51 | return @"Section Header"; 52 | } 53 | 54 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 55 | { 56 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"Cell" 57 | forIndexPath:indexPath]; 58 | 59 | cell.textLabel.text = @"Sample Data"; 60 | 61 | return cell; 62 | } 63 | 64 | @end 65 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TLYViewController.h 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYViewController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/TLYViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYViewController.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import "TLYViewController.h" 10 | 11 | @interface TLYViewController () 12 | 13 | @property (nonatomic, assign) IBInspectable BOOL disableExtensionView; 14 | @property (nonatomic, assign) IBInspectable BOOL stickyNavigationBar; 15 | @property (nonatomic, assign) IBInspectable BOOL stickyExtensionView; 16 | @property (nonatomic, assign) IBInspectable NSInteger fadeBehavior; 17 | 18 | @property (weak, nonatomic) IBOutlet UIScrollView *scrollView; 19 | @property (weak, nonatomic) IBOutlet UIImageView *imageView; 20 | 21 | @end 22 | 23 | @implementation TLYViewController 24 | 25 | #pragma mark - Init & Dealloc 26 | 27 | - (id)initWithCoder:(NSCoder *)aDecoder 28 | { 29 | self = [super initWithCoder:aDecoder]; 30 | if (self) { 31 | 32 | self.disableExtensionView = NO; 33 | self.stickyNavigationBar = NO; 34 | self.stickyExtensionView = NO; 35 | self.fadeBehavior = TLYShyNavBarFadeSubviews; 36 | 37 | self.title = @"WTFox Say"; 38 | } 39 | return self; 40 | } 41 | 42 | #pragma mark - View Life Cycle 43 | 44 | - (void)viewDidLoad 45 | { 46 | [super viewDidLoad]; 47 | 48 | UIView *view = nil; 49 | 50 | if (!self.disableExtensionView) 51 | { 52 | view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth(self.view.bounds), 40.f)]; 53 | view.backgroundColor = [UIColor redColor]; 54 | 55 | UIButton *button = [UIButton buttonWithType:UIButtonTypeSystem]; 56 | button.frame = view.bounds; 57 | [button addTarget:self action:@selector(extensionViewTapped:) forControlEvents:UIControlEventTouchUpInside]; 58 | [button setTitle:@"Click Me!" forState:UIControlStateNormal]; 59 | 60 | [view addSubview:button]; 61 | } 62 | 63 | /* Library code */ 64 | self.shyNavBarManager.scrollView = self.scrollView; 65 | /* Can then be remove by setting the ExtensionView to nil */ 66 | [self.shyNavBarManager setExtensionView:view]; 67 | /* Make navbar stick to the top */ 68 | [self.shyNavBarManager setStickyNavigationBar:self.stickyNavigationBar]; 69 | /* Make the extension view stick to the top */ 70 | [self.shyNavBarManager setStickyExtensionView:self.stickyExtensionView]; 71 | /* Navigation bar fade behavior */ 72 | [self.shyNavBarManager setFadeBehavior:self.fadeBehavior]; 73 | } 74 | 75 | - (void)viewDidLayoutSubviews 76 | { 77 | [super viewDidLayoutSubviews]; 78 | self.scrollView.contentSize = self.imageView.bounds.size; 79 | } 80 | 81 | #pragma mark - Action methods 82 | 83 | - (void)extensionViewTapped:(id)sender 84 | { 85 | [[[UIAlertView alloc] initWithTitle:@"it works" message:nil delegate:nil cancelButtonTitle:@"OK!" otherButtonTitles:nil] show]; 86 | } 87 | 88 | @end 89 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemo/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // TLYShyNavBarDemo 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "TLYAppDelegate.h" 12 | 13 | int main(int argc, char * argv[]) 14 | { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([TLYAppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemoTests/TLYShyNavBarDemoTests-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 1.0 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemoTests/TLYShyNavBarDemoTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBarDemoTests.m 3 | // TLYShyNavBarDemoTests 4 | // 5 | // Created by Mazyad Alabduljaleel on 6/12/14. 6 | // Copyright (c) 2014 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TLYShyNavBarDemoTests : XCTestCase 12 | 13 | @end 14 | 15 | @implementation TLYShyNavBarDemoTests 16 | 17 | - (void)setUp 18 | { 19 | [super setUp]; 20 | // Put setup code here. This method is called before the invocation of each test method in the class. 21 | } 22 | 23 | - (void)tearDown 24 | { 25 | // Put teardown code here. This method is called after the invocation of each test method in the class. 26 | [super tearDown]; 27 | } 28 | 29 | - (void)testExample 30 | { 31 | XCTFail(@"No implementation for \"%s\"", __PRETTY_FUNCTION__); 32 | } 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /TLYShyNavBarDemo/TLYShyNavBarDemoTests/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/Bridging-Header.h: -------------------------------------------------------------------------------- 1 | // 2 | // Bridging-Header.h 3 | // TLYShyNavBarSwiftDemo 4 | // 5 | // Created by Tony Nuzzi on 2/22/15. 6 | // Copyright (c) 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | #ifndef TLYShyNavBarSwiftDemo_Bridging_Header_h 10 | #define TLYShyNavBarSwiftDemo_Bridging_Header_h 11 | 12 | #import "TLYShyNavBarManager.h" 13 | 14 | #endif 15 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 826F866D1BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F865A1BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.m */; }; 11 | 826F866E1BF8123D000F9216 /* TLYDelegateProxy.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F865C1BF8123D000F9216 /* TLYDelegateProxy.m */; }; 12 | 826F866F1BF8123D000F9216 /* UIScrollView+Helpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F865E1BF8123D000F9216 /* UIScrollView+Helpers.m */; }; 13 | 826F86701BF8123D000F9216 /* UIViewController+BetterLayoutGuides.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F86601BF8123D000F9216 /* UIViewController+BetterLayoutGuides.m */; }; 14 | 826F86711BF8123D000F9216 /* TLYShyScrollViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F86651BF8123D000F9216 /* TLYShyScrollViewController.m */; }; 15 | 826F86721BF8123D000F9216 /* TLYShyStatusBarController.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F86671BF8123D000F9216 /* TLYShyStatusBarController.m */; }; 16 | 826F86731BF8123D000F9216 /* TLYShyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F86691BF8123D000F9216 /* TLYShyViewController.m */; }; 17 | 826F86741BF8123D000F9216 /* TLYShyNavBarManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 826F866C1BF8123D000F9216 /* TLYShyNavBarManager.m */; }; 18 | E7ADE6101A99A83B00E8F95C /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = E7ADE60F1A99A83B00E8F95C /* AppDelegate.swift */; }; 19 | E7ADE6151A99A83B00E8F95C /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E7ADE6131A99A83B00E8F95C /* Main.storyboard */; }; 20 | E7ADE6171A99A83B00E8F95C /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = E7ADE6161A99A83B00E8F95C /* Images.xcassets */; }; 21 | E7ADE61A1A99A83B00E8F95C /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = E7ADE6181A99A83B00E8F95C /* LaunchScreen.xib */; }; 22 | E7ADE6261A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = E7ADE6251A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.swift */; }; 23 | E7ADE6421A99AB5800E8F95C /* TableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = E7ADE6411A99AB5800E8F95C /* TableViewController.swift */; }; 24 | /* End PBXBuildFile section */ 25 | 26 | /* Begin PBXContainerItemProxy section */ 27 | E7ADE6201A99A83B00E8F95C /* PBXContainerItemProxy */ = { 28 | isa = PBXContainerItemProxy; 29 | containerPortal = E7ADE6021A99A83B00E8F95C /* Project object */; 30 | proxyType = 1; 31 | remoteGlobalIDString = E7ADE6091A99A83B00E8F95C; 32 | remoteInfo = TLYShyNavBarSwiftDemo; 33 | }; 34 | /* End PBXContainerItemProxy section */ 35 | 36 | /* Begin PBXFileReference section */ 37 | 826F86591BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+TLYSwizzlingHelpers.h"; sourceTree = ""; }; 38 | 826F865A1BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+TLYSwizzlingHelpers.m"; sourceTree = ""; }; 39 | 826F865B1BF8123D000F9216 /* TLYDelegateProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYDelegateProxy.h; sourceTree = ""; }; 40 | 826F865C1BF8123D000F9216 /* TLYDelegateProxy.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYDelegateProxy.m; sourceTree = ""; }; 41 | 826F865D1BF8123D000F9216 /* UIScrollView+Helpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIScrollView+Helpers.h"; sourceTree = ""; }; 42 | 826F865E1BF8123D000F9216 /* UIScrollView+Helpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIScrollView+Helpers.m"; sourceTree = ""; }; 43 | 826F865F1BF8123D000F9216 /* UIViewController+BetterLayoutGuides.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIViewController+BetterLayoutGuides.h"; sourceTree = ""; }; 44 | 826F86601BF8123D000F9216 /* UIViewController+BetterLayoutGuides.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIViewController+BetterLayoutGuides.m"; sourceTree = ""; }; 45 | 826F86621BF8123D000F9216 /* TLYShyChild.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyChild.h; sourceTree = ""; }; 46 | 826F86631BF8123D000F9216 /* TLYShyParent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyParent.h; sourceTree = ""; }; 47 | 826F86641BF8123D000F9216 /* TLYShyScrollViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyScrollViewController.h; sourceTree = ""; }; 48 | 826F86651BF8123D000F9216 /* TLYShyScrollViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyScrollViewController.m; sourceTree = ""; }; 49 | 826F86661BF8123D000F9216 /* TLYShyStatusBarController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyStatusBarController.h; sourceTree = ""; }; 50 | 826F86671BF8123D000F9216 /* TLYShyStatusBarController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyStatusBarController.m; sourceTree = ""; }; 51 | 826F86681BF8123D000F9216 /* TLYShyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyViewController.h; sourceTree = ""; }; 52 | 826F86691BF8123D000F9216 /* TLYShyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyViewController.m; sourceTree = ""; }; 53 | 826F866A1BF8123D000F9216 /* TLYShyNavBarFade.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarFade.h; sourceTree = ""; }; 54 | 826F866B1BF8123D000F9216 /* TLYShyNavBarManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TLYShyNavBarManager.h; sourceTree = ""; }; 55 | 826F866C1BF8123D000F9216 /* TLYShyNavBarManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TLYShyNavBarManager.m; sourceTree = ""; }; 56 | E7ADE60A1A99A83B00E8F95C /* TLYShyNavBarSwiftDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TLYShyNavBarSwiftDemo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 57 | E7ADE60E1A99A83B00E8F95C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 58 | E7ADE60F1A99A83B00E8F95C /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 59 | E7ADE6141A99A83B00E8F95C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 60 | E7ADE6161A99A83B00E8F95C /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 61 | E7ADE6191A99A83B00E8F95C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 62 | E7ADE61F1A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TLYShyNavBarSwiftDemoTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 63 | E7ADE6241A99A83B00E8F95C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 64 | E7ADE6251A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TLYShyNavBarSwiftDemoTests.swift; sourceTree = ""; }; 65 | E7ADE6401A99A86600E8F95C /* Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Bridging-Header.h"; sourceTree = ""; }; 66 | E7ADE6411A99AB5800E8F95C /* TableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TableViewController.swift; sourceTree = ""; }; 67 | /* End PBXFileReference section */ 68 | 69 | /* Begin PBXFrameworksBuildPhase section */ 70 | E7ADE6071A99A83B00E8F95C /* Frameworks */ = { 71 | isa = PBXFrameworksBuildPhase; 72 | buildActionMask = 2147483647; 73 | files = ( 74 | ); 75 | runOnlyForDeploymentPostprocessing = 0; 76 | }; 77 | E7ADE61C1A99A83B00E8F95C /* Frameworks */ = { 78 | isa = PBXFrameworksBuildPhase; 79 | buildActionMask = 2147483647; 80 | files = ( 81 | ); 82 | runOnlyForDeploymentPostprocessing = 0; 83 | }; 84 | /* End PBXFrameworksBuildPhase section */ 85 | 86 | /* Begin PBXGroup section */ 87 | 826F86571BF8123D000F9216 /* TLYShyNavBar */ = { 88 | isa = PBXGroup; 89 | children = ( 90 | 826F86581BF8123D000F9216 /* Categories */, 91 | 826F86611BF8123D000F9216 /* ShyControllers */, 92 | 826F866A1BF8123D000F9216 /* TLYShyNavBarFade.h */, 93 | 826F866B1BF8123D000F9216 /* TLYShyNavBarManager.h */, 94 | 826F866C1BF8123D000F9216 /* TLYShyNavBarManager.m */, 95 | ); 96 | name = TLYShyNavBar; 97 | path = ../TLYShyNavBar; 98 | sourceTree = ""; 99 | }; 100 | 826F86581BF8123D000F9216 /* Categories */ = { 101 | isa = PBXGroup; 102 | children = ( 103 | 826F86591BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.h */, 104 | 826F865A1BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.m */, 105 | 826F865B1BF8123D000F9216 /* TLYDelegateProxy.h */, 106 | 826F865C1BF8123D000F9216 /* TLYDelegateProxy.m */, 107 | 826F865D1BF8123D000F9216 /* UIScrollView+Helpers.h */, 108 | 826F865E1BF8123D000F9216 /* UIScrollView+Helpers.m */, 109 | 826F865F1BF8123D000F9216 /* UIViewController+BetterLayoutGuides.h */, 110 | 826F86601BF8123D000F9216 /* UIViewController+BetterLayoutGuides.m */, 111 | ); 112 | path = Categories; 113 | sourceTree = ""; 114 | }; 115 | 826F86611BF8123D000F9216 /* ShyControllers */ = { 116 | isa = PBXGroup; 117 | children = ( 118 | 826F86621BF8123D000F9216 /* TLYShyChild.h */, 119 | 826F86631BF8123D000F9216 /* TLYShyParent.h */, 120 | 826F86641BF8123D000F9216 /* TLYShyScrollViewController.h */, 121 | 826F86651BF8123D000F9216 /* TLYShyScrollViewController.m */, 122 | 826F86661BF8123D000F9216 /* TLYShyStatusBarController.h */, 123 | 826F86671BF8123D000F9216 /* TLYShyStatusBarController.m */, 124 | 826F86681BF8123D000F9216 /* TLYShyViewController.h */, 125 | 826F86691BF8123D000F9216 /* TLYShyViewController.m */, 126 | ); 127 | path = ShyControllers; 128 | sourceTree = ""; 129 | }; 130 | E7ADE6011A99A83B00E8F95C = { 131 | isa = PBXGroup; 132 | children = ( 133 | E7ADE6401A99A86600E8F95C /* Bridging-Header.h */, 134 | 826F86571BF8123D000F9216 /* TLYShyNavBar */, 135 | E7ADE60C1A99A83B00E8F95C /* TLYShyNavBarSwiftDemo */, 136 | E7ADE6221A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests */, 137 | E7ADE60B1A99A83B00E8F95C /* Products */, 138 | ); 139 | sourceTree = ""; 140 | }; 141 | E7ADE60B1A99A83B00E8F95C /* Products */ = { 142 | isa = PBXGroup; 143 | children = ( 144 | E7ADE60A1A99A83B00E8F95C /* TLYShyNavBarSwiftDemo.app */, 145 | E7ADE61F1A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.xctest */, 146 | ); 147 | name = Products; 148 | sourceTree = ""; 149 | }; 150 | E7ADE60C1A99A83B00E8F95C /* TLYShyNavBarSwiftDemo */ = { 151 | isa = PBXGroup; 152 | children = ( 153 | E7ADE60F1A99A83B00E8F95C /* AppDelegate.swift */, 154 | E7ADE6131A99A83B00E8F95C /* Main.storyboard */, 155 | E7ADE6411A99AB5800E8F95C /* TableViewController.swift */, 156 | E7ADE6161A99A83B00E8F95C /* Images.xcassets */, 157 | E7ADE6181A99A83B00E8F95C /* LaunchScreen.xib */, 158 | E7ADE60D1A99A83B00E8F95C /* Supporting Files */, 159 | ); 160 | path = TLYShyNavBarSwiftDemo; 161 | sourceTree = ""; 162 | }; 163 | E7ADE60D1A99A83B00E8F95C /* Supporting Files */ = { 164 | isa = PBXGroup; 165 | children = ( 166 | E7ADE60E1A99A83B00E8F95C /* Info.plist */, 167 | ); 168 | name = "Supporting Files"; 169 | sourceTree = ""; 170 | }; 171 | E7ADE6221A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests */ = { 172 | isa = PBXGroup; 173 | children = ( 174 | E7ADE6251A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.swift */, 175 | E7ADE6231A99A83B00E8F95C /* Supporting Files */, 176 | ); 177 | path = TLYShyNavBarSwiftDemoTests; 178 | sourceTree = ""; 179 | }; 180 | E7ADE6231A99A83B00E8F95C /* Supporting Files */ = { 181 | isa = PBXGroup; 182 | children = ( 183 | E7ADE6241A99A83B00E8F95C /* Info.plist */, 184 | ); 185 | name = "Supporting Files"; 186 | sourceTree = ""; 187 | }; 188 | /* End PBXGroup section */ 189 | 190 | /* Begin PBXNativeTarget section */ 191 | E7ADE6091A99A83B00E8F95C /* TLYShyNavBarSwiftDemo */ = { 192 | isa = PBXNativeTarget; 193 | buildConfigurationList = E7ADE6291A99A83B00E8F95C /* Build configuration list for PBXNativeTarget "TLYShyNavBarSwiftDemo" */; 194 | buildPhases = ( 195 | E7ADE6061A99A83B00E8F95C /* Sources */, 196 | E7ADE6071A99A83B00E8F95C /* Frameworks */, 197 | E7ADE6081A99A83B00E8F95C /* Resources */, 198 | ); 199 | buildRules = ( 200 | ); 201 | dependencies = ( 202 | ); 203 | name = TLYShyNavBarSwiftDemo; 204 | productName = TLYShyNavBarSwiftDemo; 205 | productReference = E7ADE60A1A99A83B00E8F95C /* TLYShyNavBarSwiftDemo.app */; 206 | productType = "com.apple.product-type.application"; 207 | }; 208 | E7ADE61E1A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests */ = { 209 | isa = PBXNativeTarget; 210 | buildConfigurationList = E7ADE62C1A99A83B00E8F95C /* Build configuration list for PBXNativeTarget "TLYShyNavBarSwiftDemoTests" */; 211 | buildPhases = ( 212 | E7ADE61B1A99A83B00E8F95C /* Sources */, 213 | E7ADE61C1A99A83B00E8F95C /* Frameworks */, 214 | E7ADE61D1A99A83B00E8F95C /* Resources */, 215 | ); 216 | buildRules = ( 217 | ); 218 | dependencies = ( 219 | E7ADE6211A99A83B00E8F95C /* PBXTargetDependency */, 220 | ); 221 | name = TLYShyNavBarSwiftDemoTests; 222 | productName = TLYShyNavBarSwiftDemoTests; 223 | productReference = E7ADE61F1A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.xctest */; 224 | productType = "com.apple.product-type.bundle.unit-test"; 225 | }; 226 | /* End PBXNativeTarget section */ 227 | 228 | /* Begin PBXProject section */ 229 | E7ADE6021A99A83B00E8F95C /* Project object */ = { 230 | isa = PBXProject; 231 | attributes = { 232 | LastSwiftUpdateCheck = 0710; 233 | LastUpgradeCheck = 0710; 234 | ORGANIZATIONNAME = "Acktie, LLC"; 235 | TargetAttributes = { 236 | E7ADE6091A99A83B00E8F95C = { 237 | CreatedOnToolsVersion = 6.1.1; 238 | }; 239 | E7ADE61E1A99A83B00E8F95C = { 240 | CreatedOnToolsVersion = 6.1.1; 241 | TestTargetID = E7ADE6091A99A83B00E8F95C; 242 | }; 243 | }; 244 | }; 245 | buildConfigurationList = E7ADE6051A99A83B00E8F95C /* Build configuration list for PBXProject "TLYShyNavBarSwiftDemo" */; 246 | compatibilityVersion = "Xcode 3.2"; 247 | developmentRegion = English; 248 | hasScannedForEncodings = 0; 249 | knownRegions = ( 250 | en, 251 | Base, 252 | ); 253 | mainGroup = E7ADE6011A99A83B00E8F95C; 254 | productRefGroup = E7ADE60B1A99A83B00E8F95C /* Products */; 255 | projectDirPath = ""; 256 | projectRoot = ""; 257 | targets = ( 258 | E7ADE6091A99A83B00E8F95C /* TLYShyNavBarSwiftDemo */, 259 | E7ADE61E1A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests */, 260 | ); 261 | }; 262 | /* End PBXProject section */ 263 | 264 | /* Begin PBXResourcesBuildPhase section */ 265 | E7ADE6081A99A83B00E8F95C /* Resources */ = { 266 | isa = PBXResourcesBuildPhase; 267 | buildActionMask = 2147483647; 268 | files = ( 269 | E7ADE6151A99A83B00E8F95C /* Main.storyboard in Resources */, 270 | E7ADE61A1A99A83B00E8F95C /* LaunchScreen.xib in Resources */, 271 | E7ADE6171A99A83B00E8F95C /* Images.xcassets in Resources */, 272 | ); 273 | runOnlyForDeploymentPostprocessing = 0; 274 | }; 275 | E7ADE61D1A99A83B00E8F95C /* Resources */ = { 276 | isa = PBXResourcesBuildPhase; 277 | buildActionMask = 2147483647; 278 | files = ( 279 | ); 280 | runOnlyForDeploymentPostprocessing = 0; 281 | }; 282 | /* End PBXResourcesBuildPhase section */ 283 | 284 | /* Begin PBXSourcesBuildPhase section */ 285 | E7ADE6061A99A83B00E8F95C /* Sources */ = { 286 | isa = PBXSourcesBuildPhase; 287 | buildActionMask = 2147483647; 288 | files = ( 289 | 826F86741BF8123D000F9216 /* TLYShyNavBarManager.m in Sources */, 290 | 826F86731BF8123D000F9216 /* TLYShyViewController.m in Sources */, 291 | 826F86721BF8123D000F9216 /* TLYShyStatusBarController.m in Sources */, 292 | E7ADE6421A99AB5800E8F95C /* TableViewController.swift in Sources */, 293 | 826F86711BF8123D000F9216 /* TLYShyScrollViewController.m in Sources */, 294 | 826F86701BF8123D000F9216 /* UIViewController+BetterLayoutGuides.m in Sources */, 295 | E7ADE6101A99A83B00E8F95C /* AppDelegate.swift in Sources */, 296 | 826F866D1BF8123D000F9216 /* NSObject+TLYSwizzlingHelpers.m in Sources */, 297 | 826F866E1BF8123D000F9216 /* TLYDelegateProxy.m in Sources */, 298 | 826F866F1BF8123D000F9216 /* UIScrollView+Helpers.m in Sources */, 299 | ); 300 | runOnlyForDeploymentPostprocessing = 0; 301 | }; 302 | E7ADE61B1A99A83B00E8F95C /* Sources */ = { 303 | isa = PBXSourcesBuildPhase; 304 | buildActionMask = 2147483647; 305 | files = ( 306 | E7ADE6261A99A83B00E8F95C /* TLYShyNavBarSwiftDemoTests.swift in Sources */, 307 | ); 308 | runOnlyForDeploymentPostprocessing = 0; 309 | }; 310 | /* End PBXSourcesBuildPhase section */ 311 | 312 | /* Begin PBXTargetDependency section */ 313 | E7ADE6211A99A83B00E8F95C /* PBXTargetDependency */ = { 314 | isa = PBXTargetDependency; 315 | target = E7ADE6091A99A83B00E8F95C /* TLYShyNavBarSwiftDemo */; 316 | targetProxy = E7ADE6201A99A83B00E8F95C /* PBXContainerItemProxy */; 317 | }; 318 | /* End PBXTargetDependency section */ 319 | 320 | /* Begin PBXVariantGroup section */ 321 | E7ADE6131A99A83B00E8F95C /* Main.storyboard */ = { 322 | isa = PBXVariantGroup; 323 | children = ( 324 | E7ADE6141A99A83B00E8F95C /* Base */, 325 | ); 326 | name = Main.storyboard; 327 | sourceTree = ""; 328 | }; 329 | E7ADE6181A99A83B00E8F95C /* LaunchScreen.xib */ = { 330 | isa = PBXVariantGroup; 331 | children = ( 332 | E7ADE6191A99A83B00E8F95C /* Base */, 333 | ); 334 | name = LaunchScreen.xib; 335 | sourceTree = ""; 336 | }; 337 | /* End PBXVariantGroup section */ 338 | 339 | /* Begin XCBuildConfiguration section */ 340 | E7ADE6271A99A83B00E8F95C /* Debug */ = { 341 | isa = XCBuildConfiguration; 342 | buildSettings = { 343 | ALWAYS_SEARCH_USER_PATHS = NO; 344 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 345 | CLANG_CXX_LIBRARY = "libc++"; 346 | CLANG_ENABLE_MODULES = YES; 347 | CLANG_ENABLE_OBJC_ARC = YES; 348 | CLANG_WARN_BOOL_CONVERSION = YES; 349 | CLANG_WARN_CONSTANT_CONVERSION = YES; 350 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 351 | CLANG_WARN_EMPTY_BODY = YES; 352 | CLANG_WARN_ENUM_CONVERSION = YES; 353 | CLANG_WARN_INT_CONVERSION = YES; 354 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 355 | CLANG_WARN_UNREACHABLE_CODE = YES; 356 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 357 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 358 | COPY_PHASE_STRIP = NO; 359 | ENABLE_STRICT_OBJC_MSGSEND = YES; 360 | ENABLE_TESTABILITY = YES; 361 | GCC_C_LANGUAGE_STANDARD = gnu99; 362 | GCC_DYNAMIC_NO_PIC = NO; 363 | GCC_OPTIMIZATION_LEVEL = 0; 364 | GCC_PREPROCESSOR_DEFINITIONS = ( 365 | "DEBUG=1", 366 | "$(inherited)", 367 | ); 368 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 369 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 370 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 371 | GCC_WARN_UNDECLARED_SELECTOR = YES; 372 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 373 | GCC_WARN_UNUSED_FUNCTION = YES; 374 | GCC_WARN_UNUSED_VARIABLE = YES; 375 | IPHONEOS_DEPLOYMENT_TARGET = 8.1; 376 | MTL_ENABLE_DEBUG_INFO = YES; 377 | ONLY_ACTIVE_ARCH = YES; 378 | SDKROOT = iphoneos; 379 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 380 | }; 381 | name = Debug; 382 | }; 383 | E7ADE6281A99A83B00E8F95C /* Release */ = { 384 | isa = XCBuildConfiguration; 385 | buildSettings = { 386 | ALWAYS_SEARCH_USER_PATHS = NO; 387 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 388 | CLANG_CXX_LIBRARY = "libc++"; 389 | CLANG_ENABLE_MODULES = YES; 390 | CLANG_ENABLE_OBJC_ARC = YES; 391 | CLANG_WARN_BOOL_CONVERSION = YES; 392 | CLANG_WARN_CONSTANT_CONVERSION = YES; 393 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 394 | CLANG_WARN_EMPTY_BODY = YES; 395 | CLANG_WARN_ENUM_CONVERSION = YES; 396 | CLANG_WARN_INT_CONVERSION = YES; 397 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 398 | CLANG_WARN_UNREACHABLE_CODE = YES; 399 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 400 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 401 | COPY_PHASE_STRIP = YES; 402 | ENABLE_NS_ASSERTIONS = NO; 403 | ENABLE_STRICT_OBJC_MSGSEND = YES; 404 | GCC_C_LANGUAGE_STANDARD = gnu99; 405 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 406 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 407 | GCC_WARN_UNDECLARED_SELECTOR = YES; 408 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 409 | GCC_WARN_UNUSED_FUNCTION = YES; 410 | GCC_WARN_UNUSED_VARIABLE = YES; 411 | IPHONEOS_DEPLOYMENT_TARGET = 8.1; 412 | MTL_ENABLE_DEBUG_INFO = NO; 413 | SDKROOT = iphoneos; 414 | VALIDATE_PRODUCT = YES; 415 | }; 416 | name = Release; 417 | }; 418 | E7ADE62A1A99A83B00E8F95C /* Debug */ = { 419 | isa = XCBuildConfiguration; 420 | buildSettings = { 421 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 422 | INFOPLIST_FILE = TLYShyNavBarSwiftDemo/Info.plist; 423 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 424 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.$(PRODUCT_NAME:rfc1034identifier)"; 425 | PRODUCT_NAME = "$(TARGET_NAME)"; 426 | SWIFT_OBJC_BRIDGING_HEADER = "Bridging-Header.h"; 427 | }; 428 | name = Debug; 429 | }; 430 | E7ADE62B1A99A83B00E8F95C /* Release */ = { 431 | isa = XCBuildConfiguration; 432 | buildSettings = { 433 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 434 | INFOPLIST_FILE = TLYShyNavBarSwiftDemo/Info.plist; 435 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 436 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.$(PRODUCT_NAME:rfc1034identifier)"; 437 | PRODUCT_NAME = "$(TARGET_NAME)"; 438 | SWIFT_OBJC_BRIDGING_HEADER = "Bridging-Header.h"; 439 | }; 440 | name = Release; 441 | }; 442 | E7ADE62D1A99A83B00E8F95C /* Debug */ = { 443 | isa = XCBuildConfiguration; 444 | buildSettings = { 445 | BUNDLE_LOADER = "$(TEST_HOST)"; 446 | FRAMEWORK_SEARCH_PATHS = ( 447 | "$(SDKROOT)/Developer/Library/Frameworks", 448 | "$(inherited)", 449 | ); 450 | GCC_PREPROCESSOR_DEFINITIONS = ( 451 | "DEBUG=1", 452 | "$(inherited)", 453 | ); 454 | INFOPLIST_FILE = TLYShyNavBarSwiftDemoTests/Info.plist; 455 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 456 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.$(PRODUCT_NAME:rfc1034identifier)"; 457 | PRODUCT_NAME = "$(TARGET_NAME)"; 458 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TLYShyNavBarSwiftDemo.app/TLYShyNavBarSwiftDemo"; 459 | }; 460 | name = Debug; 461 | }; 462 | E7ADE62E1A99A83B00E8F95C /* Release */ = { 463 | isa = XCBuildConfiguration; 464 | buildSettings = { 465 | BUNDLE_LOADER = "$(TEST_HOST)"; 466 | FRAMEWORK_SEARCH_PATHS = ( 467 | "$(SDKROOT)/Developer/Library/Frameworks", 468 | "$(inherited)", 469 | ); 470 | INFOPLIST_FILE = TLYShyNavBarSwiftDemoTests/Info.plist; 471 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 472 | PRODUCT_BUNDLE_IDENTIFIER = "com.telly.$(PRODUCT_NAME:rfc1034identifier)"; 473 | PRODUCT_NAME = "$(TARGET_NAME)"; 474 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TLYShyNavBarSwiftDemo.app/TLYShyNavBarSwiftDemo"; 475 | }; 476 | name = Release; 477 | }; 478 | /* End XCBuildConfiguration section */ 479 | 480 | /* Begin XCConfigurationList section */ 481 | E7ADE6051A99A83B00E8F95C /* Build configuration list for PBXProject "TLYShyNavBarSwiftDemo" */ = { 482 | isa = XCConfigurationList; 483 | buildConfigurations = ( 484 | E7ADE6271A99A83B00E8F95C /* Debug */, 485 | E7ADE6281A99A83B00E8F95C /* Release */, 486 | ); 487 | defaultConfigurationIsVisible = 0; 488 | defaultConfigurationName = Release; 489 | }; 490 | E7ADE6291A99A83B00E8F95C /* Build configuration list for PBXNativeTarget "TLYShyNavBarSwiftDemo" */ = { 491 | isa = XCConfigurationList; 492 | buildConfigurations = ( 493 | E7ADE62A1A99A83B00E8F95C /* Debug */, 494 | E7ADE62B1A99A83B00E8F95C /* Release */, 495 | ); 496 | defaultConfigurationIsVisible = 0; 497 | defaultConfigurationName = Release; 498 | }; 499 | E7ADE62C1A99A83B00E8F95C /* Build configuration list for PBXNativeTarget "TLYShyNavBarSwiftDemoTests" */ = { 500 | isa = XCConfigurationList; 501 | buildConfigurations = ( 502 | E7ADE62D1A99A83B00E8F95C /* Debug */, 503 | E7ADE62E1A99A83B00E8F95C /* Release */, 504 | ); 505 | defaultConfigurationIsVisible = 0; 506 | defaultConfigurationName = Release; 507 | }; 508 | /* End XCConfigurationList section */ 509 | }; 510 | rootObject = E7ADE6021A99A83B00E8F95C /* Project object */; 511 | } 512 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo.xcodeproj/project.xcworkspace/xcshareddata/TLYShyNavBarSwiftDemo.xccheckout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDESourceControlProjectFavoriteDictionaryKey 6 | 7 | IDESourceControlProjectIdentifier 8 | 72C64448-CAFE-4F5D-8307-0D51A162F41F 9 | IDESourceControlProjectName 10 | TLYShyNavBarSwiftDemo 11 | IDESourceControlProjectOriginsDictionary 12 | 13 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 14 | github.com:TNuzzi/TLYShyNavBar.git 15 | 16 | IDESourceControlProjectPath 17 | TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo.xcodeproj 18 | IDESourceControlProjectRelativeInstallPathDictionary 19 | 20 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 21 | ../../.. 22 | 23 | IDESourceControlProjectURL 24 | github.com:TNuzzi/TLYShyNavBar.git 25 | IDESourceControlProjectVersion 26 | 111 27 | IDESourceControlProjectWCCIdentifier 28 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 29 | IDESourceControlProjectWCConfigurations 30 | 31 | 32 | IDESourceControlRepositoryExtensionIdentifierKey 33 | public.vcs.git 34 | IDESourceControlWCCIdentifierKey 35 | 58D55ECABAD5AAEB583BB3898420091CC2A418B2 36 | IDESourceControlWCCName 37 | TLYShyNavBar 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // TLYShyNavBarSwiftDemo 4 | // 5 | // Created by Tony Nuzzi on 2/22/15. 6 | // Copyright (c) 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | @UIApplicationMain 12 | class AppDelegate: UIResponder, UIApplicationDelegate { 13 | 14 | var window: UIWindow? 15 | 16 | 17 | func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { 18 | return true 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "29x29", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "40x40", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "40x40", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "60x60", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "60x60", 31 | "scale" : "3x" 32 | } 33 | ], 34 | "info" : { 35 | "version" : 1, 36 | "author" : "xcode" 37 | } 38 | } -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | UIInterfaceOrientationLandscapeRight 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemo/TableViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // TableViewController.swift 3 | // TLYShyNavBarSwiftDemo 4 | // 5 | // Created by Tony Nuzzi on 2/22/15. 6 | // Copyright (c) 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class TableViewController: UIViewController { 12 | 13 | @IBOutlet weak var tableView: UITableView! 14 | 15 | override func viewDidLoad() { 16 | super.viewDidLoad() 17 | 18 | let view = UIView(frame: CGRectMake(0, 0, CGRectGetWidth(self.view.bounds), 40)) 19 | view.backgroundColor = UIColor.redColor() 20 | 21 | 22 | /* Library code */ 23 | self.shyNavBarManager.scrollView = self.tableView; 24 | self.shyNavBarManager.extensionView = view 25 | } 26 | } 27 | 28 | extension TableViewController: UITableViewDataSource { 29 | 30 | func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 31 | return 50 32 | } 33 | 34 | 35 | func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { 36 | let cell = tableView.dequeueReusableCellWithIdentifier("Cell", forIndexPath: indexPath) as UITableViewCell 37 | cell.textLabel?.text = "Content" 38 | 39 | return cell 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemoTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /TLYShyNavBarSwiftDemo/TLYShyNavBarSwiftDemoTests/TLYShyNavBarSwiftDemoTests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // TLYShyNavBarSwiftDemoTests.swift 3 | // TLYShyNavBarSwiftDemoTests 4 | // 5 | // Created by Tony Nuzzi on 2/22/15. 6 | // Copyright (c) 2015 Telly, Inc. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import XCTest 11 | 12 | class TLYShyNavBarSwiftDemoTests: XCTestCase { 13 | 14 | override func setUp() { 15 | super.setUp() 16 | // Put setup code here. This method is called before the invocation of each test method in the class. 17 | } 18 | 19 | override func tearDown() { 20 | // Put teardown code here. This method is called after the invocation of each test method in the class. 21 | super.tearDown() 22 | } 23 | 24 | func testExample() { 25 | // This is an example of a functional test case. 26 | XCTAssert(true, "Pass") 27 | } 28 | 29 | func testPerformanceExample() { 30 | // This is an example of a performance test case. 31 | self.measureBlock() { 32 | // Put the code you want to measure the time of here. 33 | } 34 | } 35 | 36 | } 37 | -------------------------------------------------------------------------------- /TODO.md: -------------------------------------------------------------------------------- 1 | 2 | # TODO 3 | 4 | + Explore setting ViewController.view as a child, somehow 5 | + UITableView demo 6 | + Hidden status bar demo 7 | + expanded status bar demo 8 | + Fix contentInset calculation once and for all 9 | + Figure out a workaround to NSProxy 10 | -------------------------------------------------------------------------------- /resources/basic-feature.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/basic-feature.gif -------------------------------------------------------------------------------- /resources/battle-tested-demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/battle-tested-demo.gif -------------------------------------------------------------------------------- /resources/collectionView.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/collectionView.gif -------------------------------------------------------------------------------- /resources/fade-navbar.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/fade-navbar.gif -------------------------------------------------------------------------------- /resources/features-testing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/features-testing.png -------------------------------------------------------------------------------- /resources/fully-featured.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/fully-featured.gif -------------------------------------------------------------------------------- /resources/in-app-call.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/in-app-call.gif -------------------------------------------------------------------------------- /resources/no-extension.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/no-extension.gif -------------------------------------------------------------------------------- /resources/opaque-supported.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/opaque-supported.gif -------------------------------------------------------------------------------- /resources/robust.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/robust.gif -------------------------------------------------------------------------------- /resources/sticky-extension.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/sticky-extension.gif -------------------------------------------------------------------------------- /resources/sticky-navbar.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/sticky-navbar.gif -------------------------------------------------------------------------------- /resources/tableview.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/telly/TLYShyNavBar/1af462a34b82ee7b6da4694eeba184b49109e2d5/resources/tableview.gif --------------------------------------------------------------------------------