使用JASidePanel屏幕黑屏问题

时间:2016-04-14 10:13:49

标签: ios objective-c jasidepanels

我尝试在我的应用中集成JASidePanel。下面是我初始化JSSidePanel控制器的代码。

- (void)viewDidLoad {
    [super viewDidLoad];
    UIStoryboard *mainStoryboard = [UIStoryboard storyboardWithName:@"Main"
                                                         bundle: nil];
    UIWindow *window= [UIApplication sharedApplication].keyWindow;

    self.viewController = [[JASidePanelController alloc] init];
    self.viewController.shouldDelegateAutorotateToVisiblePanel = NO;
    self.viewController.leftPanel = [mainStoryboard instantiateViewControllerWithIdentifier:@"BBWSideMenuViewController"];
    self.viewController.centerPanel = [self.navigationController.viewControllers lastObject];

    window.rootViewController = self.navigationController;
    [window makeKeyAndVisible];

}

按钮操作方法,

- (IBAction)openSideMenu:(id)sender {
     [self.viewController showLeftPanelAnimated:YES];
}

当我按下按钮打开侧面菜单时,整个屏幕变黑。我怎么能解决这个问题?任何帮助将不胜感激。

0 个答案:

没有答案