简体   繁体   English

侧面导航栏(菜单)(iOS 6),如Facebook应用程序+故事板

[英]Side navigation bar (menu) (iOS 6) like in Facebook app + storyboards

I want to create side menu like in Facebook iPhone app in iOS 6 using Xcode and Storyboards. 我想使用Xcode和Storyboard在iOS 6中创建Facebook iPhone应用程序中的侧边菜单。 How can I make it? 我该怎么做?

Thanks. 谢谢。

We wrote MMDrawerController to solve this problem, but I havent thought about using it in a storyboard (simply because storyboards aren't maintainable for large teams). 我们写了MMDrawerController来解决这个问题,但我还没有想过在故事板中使用它(仅仅因为故事板不能为大型团队维护)。

https://github.com/mutualmobile/MMDrawerController https://github.com/mutualmobile/MMDrawerController

Get custom component like Inferis/ViewDeck and implement containment programmatically: 获取像Inferis / ViewDeck这样的自定义组件并以编程方式实现包含:

@interface YourViewController : IIViewDeckController

@end

implementation: 执行:

@implementation YourViewController

-(void)awakeFromNib
{
  UIStoryboard* storyboard = [UIStoryboard storyboardWithName:@"Storyboard" bundle:nil];
  self.centerController = [storyboard instantiateViewControllerWithIdentifier:@"CenterViewController"];
  self.leftController = [storyboard instantiateViewControllerWithIdentifier:@"LeftViewController"];
}

@end

In case someone else would like to do something similar.. I've succeeded using ECSlidingView. 如果其他人想要做类似的事情..我已成功使用ECSlidingView。 It is already done using storyboards. 它已经使用故事板完成。 There's also an example included. 还有一个例子。

https://github.com/edgecase/ECSlidingViewController.git https://github.com/edgecase/ECSlidingViewController.git

EDIT: 编辑:

Well after implementing this ECSlidingViewController i see that the navigation is slow, and strange. 好了,在实现这个ECSlidingViewController后,我看到导航很慢,很奇怪。 Switched to IIViewDeckController after all. 毕竟切换到IIViewDeckController。 Fast and easy, super! 快速,简单,超级!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM