2011-09-27 64 views
7

添加Three20TTPhotoViewController在一个空的UIWindow旋转工作像一个魅力。旋转Three20 TTPhotoViewController里面TabBarController

但是当我移动TTPhotoViewControllerUINavigationController创建一个UITabBarController里面根本不会转动。

我确信我回到YES为每shouldAutorotateToInterfaceOrientation功能。

与旋转侧的UITabBarController不Three20照相馆工作?


我该怎么做?

[[TTURLRequestQueue mainQueue] setMaxContentLength:0]; 

TTNavigator *navigator = [TTNavigator navigator]; 
navigator.persistenceMode = TTNavigatorPersistenceModeAll; 

navigator.window = [UIApplication sharedApplication].keyWindow; 
TTURLMap *map = navigator.URLMap; 
[map from:@"tt://appPhotos" toSharedViewController:[PhotoViewController class]]; 
[navigator openURLAction:[TTURLAction actionWithURLPath:@"tt://appPhotos"]]; 


更新1: 阅读一些帖子后,我现在只能内部 TTScrollView旋转图像,但导航栏不旋转。

更新2: 我有子类-ED都UITabBarControllerUINavigationController覆盖shouldAutorotateToInterfaceOrientation,但它并没有帮助。

回答

3

我已经古怪从Window对象中删除TabBarController,并打算回来时,我的TabBarControllerwindow再次添加解决了我的问题。

0

你可以只旋转滚动视图。不管怎么样,如果你旋转navController它看起来奇怪,当你弹出photoviewcontroller(如果您的画廊是不是RootViewController的)。我旋转和滚动视图墙根导航栏和底部工具栏进入横向模式时,它看起来不错。

+0

非常伟大的想法,我达到了这个解决方案,而隐藏导航栏的思考,就像你说的,它看起来奇怪,如果你不隐藏导航栏,但我的解决方案是非常完美的,我还没有触及的Three20库所有。 –