Giter Club home page Giter Club logo

flipboardnavigationcontroller's Introduction

FlipBoardNavigationController

This is a new navigation controller inspired by Flipboard.

Usage

Creating your controller

Somewhere, for example in your app delegate, alloc and init the controller :

_flipboardNavigationController = [[FlipBoardNavigationController alloc]initWithRootViewController:rootViewController];

Then, add it to the window

self.window.rootViewController = _flipboardNavigationController;

or to a view

[self.view addSubview:_flipboardNavigationController.view];

You can add a navigation controller on top, for example :

MainViewController *main = [[MainViewController alloc] initWithNibName:@"MainViewController" bundle:nil];
_flipboardNavigationController = [[FlipBoardNavigationController alloc]initWithRootViewController:rootViewController];
self.window.rootViewController = _flipboardNavigationController;

Pushing a controller

You have several options to push a controller The easiest way is :

[self.flipboardNavigationController pushViewController:anotherViewController];

or you can also use the completion block if ever you need it.

[self.flipboardNavigationController pushViewController:anotherViewController completion:^{
    NSLog(@"Complete");
}];

Popping

To go back to your parent view controller, you can pop :

 [self.flipboardNavigationController popViewController];

or

[self.flipboardNavigationController popViewControllerWithCompletion:^{
    <#code#>
}].

Screenshots

Preview

Preview

Please let me know if you have any questions.

Cheers,
Michael Henry Pantaleon

http://www.iamkel.net

Licensing

Copyright (c) 2013 Michael Henry Pantaleon (http://www.iamkel.net). All rights reserved.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

flipboardnavigationcontroller's People

Contributors

dimillian avatar michaelhenry avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flipboardnavigationcontroller's Issues

Hides Navigation bar.

How can I apply the style of the original navigation bar without creating new ones?

leftPan -> Push ViewController

would be nice to have the possibility to push a ViewController with a leftPan gesture like it is actually done in the Flipboard App ...instead of the rollBackViewController method.

Remove arbitrary view controller from the stack

I think an ability to remove a view controller form the stack is needed. For instance like this:
UIViewController* page = [self.storyboard instantiateViewControllerWithIdentifier: @"another_vc"];
[self.flipboardNavigationController pushViewController: page completion: ^
{
self.flipboardNavigationController.viewControllers = @[page];
}];

No explicit license.

Cocoa controls lists this as being under the MIT license. But the project itself doesn’t seem to state that anywhere.

viewWillAppear / viewDidAppear

Hello,

viewWillAppear / viewDidAppear
These methodes are not called when you pop the current viewcontroller:
[self.flipboardNavigationController popViewController];

life cycle problems

When pushing a new controller A from controller B, B's viewWillDisappear & viewDidDisappear will not be called.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.