Skip to content
This repository has been archived by the owner on Sep 11, 2022. It is now read-only.

UIScrollview inside frontViewController problem #65

Closed
javsmo opened this issue Sep 30, 2012 · 1 comment
Closed

UIScrollview inside frontViewController problem #65

javsmo opened this issue Sep 30, 2012 · 1 comment

Comments

@javsmo
Copy link

javsmo commented Sep 30, 2012

My rearViewController is a simple TableViewController and my frontViewController has a UINavigationBar and a UIScrollview with several views inside it (pages of a book).

When I revealToggle, the frontViewController goes to right, but the hidden page on UIScrollView appears in front of rearViewController as the image below:

http://db.tt/ZLpQVBSu

Am I doing something wrong?

This is the code I'm using to toggle the rearViewController:

UINavigationItem *item = [[UINavigationItem alloc] initWithTitle:@"Title"];
item.leftBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Menu"
                                                         style:UIBarButtonItemStylePlain
                                                         target:self.parentViewController.parentViewController
                                                         action:@selector(revealToggle:)];
item.hidesBackButton = YES;
[self.navigationBar pushNavigationItem:item animated:NO];

And this is the code to create the ZUUIRevealController:

BSMainMenuViewController *mainMenu = [[BSMainMenuViewController alloc] initWithStyle:UITableViewStylePlain];
mainMenu.title = @"Menu";
mainMenu.navigationController.navigationBarHidden = NO;

ZUUIRevealController *revealController = [[ZUUIRevealController alloc] initWithFrontViewController:self.viewController
                                                                                rearViewController:mainMenu];

self.window.rootViewController = revealController;
@javsmo
Copy link
Author

javsmo commented Oct 1, 2012

I just realized what was the problem. I set self.view.clipsToBounds = YES; on frontViewController and everything worked fine.

@javsmo javsmo closed this as completed Oct 1, 2012
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant