2014-11-04 79 views
0

我在我的應用中使用UITableViewController,UICollectionViewController。在ViewDidLoad視圖看起來很像下面。 enter image description hereUIView,UITableView幀未對齊iOS 8

但是,如果我接受了相應的詳細視圖,並返回到UITableViewUICollectionView後對準像下面enter image description here

我甚至嘗試上viewDidAppear,但沒有運氣設置self.tableView.frame = CGRectMake(0,0,width,height);

這是我的tableView屬性:(我也試過檢查/取消選中這些屬性)。在這裏任何人都親切地建議可能的解決方案或原因這個問題..

注意:自動佈局的故事板是不使用 ..

enter image description here

回答

0

將這個代碼在你的UITableViewController viewDidLoad中

self.navigationController.navigationBar.translucent = NO; 
+0

現在的問題在加載時自動加載像這樣(http://i.stack.imgur.com/XYNWM.png)加載 – 2014-11-06 13:43:58

+0

self.edgesForExtendedLayout = UIRectEdgeNone; //在你的cellforindexpath中使用它 – 2014-11-07 05:11:20