RESideMenu
RESideMenu copied to clipboard
viewWillAppear and viewDidAppear should be called on the menu view controller
When I call presentLeftMenuViewController
I expect viewWillAppear:
and viewDidAppear:
to be called on the leftMenuViewController
. Similarly with rightMenuViewContoller
and on disappear. Currently the view appear methods are only called once when the app launches.
:+1: Any news on that?
@x2on: i just tested this on my install and it works properly. i dropped a last line in awakeFromNib: [self presentLeftMenuViewController]; and viewDidAppear was fired off on my left menu: 2014-10-16 17:22:14.466 myApp[3367:1675662] -[MyAppLeftMenuVC viewDidAppear:]
When i call presentLeftMenuViewController
from another view controller, only the first time viewDidAppear
is called on my tests.
I agree that viewDidAppear:
and viewWillAppear:
should be called when revealing the menus. In my testing, they are called once, and the one time they are called is not even a time where the menu is coming into view.
Actually #227 doesn't cover all situations. If the menu is in front and you close it with gesture viewDidAppear
from the contentViewController
ist not called.
@x2on: If you're referring to events not being called on the content view controller when the menu opens or closes, that was a conscious decision. My current understanding is that the content view controller never fully leaves the screen when the menus are activated, so in my opinion it doesn't actually "disappear" or "appear". That interpretation is certainly up for debate/correction :)
As an alternative, you can use the RESideMenuDelegate
methods such as sideMenu:didHideMenuViewController:
to track when the content view controller is shifted away or restored to the center.
Ok now i get your purpose.
For me if the menu is shown the contentViewController
is then disappeared, because you are focused on the menu and not you see only a small part of the contentViewController
and can't interact with it.
I created the #236 to track if the contentViewController
is changed for implementing the transition in the delegate.