问题
my iphone application supports portrait mode earlier, now i want to support land scape mode also.
everything is working fine in my application except the navigation controller back button. i have used tableviews in navigaton conroller, when i click back button in landscape mode view is getting poped and its loading its previous view but animation is strange.
i have given default animation but, in landscape mode view is is animating upside down instead of default left to rite when i click back button.
does anyone faced this kind of problem??? thanks in advance.
回答1:
i understood the problem and below is the solution... each viewcontroller which i am pushing into navigation controllers should have the following delegate method.
each view controller should confirm that it is supporting the orientation change
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { self.orientation = interfaceOrientation; return YES; }
来源:https://stackoverflow.com/questions/3045925/uinavigationcontroller-back-button-problem-in-landscape-mode