CocoaPods trunk is moving to be read-only. Read more on the blog, there are 14 months to go.
| TestsTested | ✗ |
| LangLanguage | Obj-CObjective C |
| License | WTFPL |
| ReleasedLast Release | Dec 2014 |
Maintained by Nacho Soto.
| Depends on: | |
| TransitionKit | ~> 2.0.0 |
| libextobjc | ~> 0.3 |
Sidebar controller with customizable animations, implemented using a state machine.
You must instantiate the controller with the menu, and the currently active view controller:
[[MSSidebarController alloc] initWithMenuViewController:menuVC
activeViewController:activeVC
animatorFactory:animatorFactory];You must also implement all three animation protocols:
@protocol MSSidebarDisplayViewControllerAnimator <NSObject>
- (void)sidebarController:(MSSidebarController *)sidebarController
willDisplayViewController:(UIViewController *)newViewController
completionBlock:(void (^)(void))completionBlock;
@end
@protocol MSSidebarDisplayMenuAnimator <NSObject>
- (void)sidebarController:(MSSidebarController *)sidebarController
willDismissViewController:(UIViewController *)currentViewController
andDisplayMenu:(UIViewController *)menuController
completionBlock:(void (^)(void))completionBlock;
@end
@protocol MSSidebarHideViewControllerAnimator <NSObject>
- (void)sidebarController:(MSSidebarController *)sidebarController
willHideViewController:(UIViewController *)currentViewController
toShowNewViewController:(UIViewController *)newViewController
completionBlock:(void (^)(void))completionBlock;
@endView controllers inside of MSSidebarController will have a sidebarController property set,
which you can use to change the state of the controller. Example:
[self.sidebarController showMenu];
[self.sidebarController restoreLastViewController];
[self.sidebarController showViewController:SomeOtherController.new];Just add this line to your Podfile:
pod 'MSSidebarController', '~> 1.0.0'
Simply add the files under Classes to your project.
MSSidebarController is available under the WTFPL license. See the LICENSE file for more info.