2012-09-11 51 views
3

我已经通过继承UIAlertView中 创建Custome AlertView类和i。在 加入的UITableView - (无效)制备方向不工作的UITableView内部AlertView

方法

This is Image of TableView inside UIAlertView with Potrait Orientation

This is when i Changed Orientation

可以任何一个建议我摆脱这个问题的方式... 在此先感谢。

我这样做是为了保持方向变化

[[UIDevice currentDevice] beginGeneratingDeviceOrientationNotifications]; 
    NSNotificationCenter* notifCenter = [NSNotificationCenter defaultCenter]; 
    [notifCenter addObserver:self 
        selector:@selector(orientationChanged) 
         name:UIDeviceOrientationDidChangeNotification 
         object:nil]; 
+0

你给Tableview的任何Autoresizing属性? – Sandy

回答

2

这对于控制一个不错的主意的轨道,我发现Git仓库有准备一个:https://github.com/blommegard/SBTableAlert/blob/master/SBTableAlert.m

它的方位变化逻辑调度用零间隔定向改变的方法。该代码是在无版权的MIT许可证下分发的,因此您可以使用它或只是采取一些有用的提示。

+0

感谢您的关注,我会尽快回复。 – Anand