2016-05-29 5 views
7

私のコードに「デバッガでこれをキャッチするには、シンボリックブレークポイントをUICollectionViewFlowLayoutBreakForInvalidSizesにする」と言うエラーが表示されます。私は実際にここで尋ねていることは、私がどこにどこにいらっしゃるのか分からないと思っているコードだと混乱していますか?UICollectionViewFlowLayoutBreakForInvalidSizesでシンボリックブレークポイントを作成する

import UIKit 

// MARK: - CUSTOM SOCIAL CELL 
class SocialCell:UICollectionViewCell { 

    /* Views */ 
    @IBOutlet weak var socialIcon: UIImageView! 
    @IBOutlet weak var socialLabel: UILabel! 
} 

class SocialList: UIViewController, UICollectionViewDataSource, UICollectionViewDelegate, UICollectionViewDelegateFlowLayout { 

    /* Views */ 
    @IBOutlet weak var socialCollView: UICollectionView! 

    override func viewDidLoad() { 
     super.viewDidLoad() 

    } 

    // MARK: - COLLECTION VIEW DELEGATES 
    func numberOfSectionsInCollectionView(collectionView: UICollectionView) -> Int { 
     return 1 
    } 

    func collectionView(collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { 
     return socials.count //socialNames.count 
    } 

    func collectionView(collectionView: UICollectionView, cellForItemAtIndexPath indexPath: NSIndexPath) -> UICollectionViewCell { 
     let cell = collectionView.dequeueReusableCellWithReuseIdentifier("SocialCell", forIndexPath: indexPath) as! SocialCell 

     cell.socialLabel.text = "\(socials[indexPath.row]["name"]!)" 
     cell.socialIcon.image = UIImage(named: "\(socials[indexPath.row]["name"]!)") 

     return cell 
    } 

    func collectionView(collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAtIndexPath indexPath: NSIndexPath) -> CGSize { 
     return CGSizeMake(view.frame.size.width/3.8, view.frame.size.width/3.8) 
    } 

    func collectionView(collectionView: UICollectionView, didSelectItemAtIndexPath indexPath: NSIndexPath) { 
     selectedSocial = "\(socials[indexPath.row]["link"]!)" 
     selectedName = "\(socials[indexPath.row]["name"]!)" 
     selectedColor = socialColors[indexPath.row] 

     navigationController?.popViewControllerAnimated(true) 
    } 
} 

答えて

26

あなたは体系的にこれを行うことによってこの問題を解決することができます:私はより具体的な問題にあなたを導くことができるように

また、あなたは、あなたの完全な誤りを共有する必要があります。私の考えは下部にプラスボタンの上に次のクリックブレークポイントナビゲーターに

enter image description here

をクリックして、あなたのプロジェクトの左側にあなたのUICollectionView

中にautolayout問題のいくつかの並べ替えを持っていることを残され、クリック追加シンボリック中断点

enter image description here

が続いてポップアップが表示されます。このプロジェクトは、私はことをやった完璧な

+0

[OK]を停止しているだけで(キーボードで)エンターキーを押し、この後ので

enter image description here

ようにそこにUICollectionViewFlowLayoutBreakForInvalidSizesを追加し、どこでも

をクリックしてコードを実行し、参照アプリをもう一度起動してFacebookのページをロードしたが、写真を追加するときにクリックすると、ページを更新してからXcodeでこれをプルするだけだ。 –

+2

UIKit'UICollectionViewFlowLayoutBreakForInvalidSizes: - > 0x1123ebabc <+0>:pushq%のRBP 0x1123ebabd <+1>:MOVQの%のRSPは、%RBP <+4> 0x1123ebac0:testq%RDI、%のRDI 0x1123ebac3 <+7>:JE 0x1123ebac7。 <+11> 0x1123ebac5 <+9>:popq%のRBP 0x1123ebac6 <+10>:retq 0x1123ebac7 <+11>:leaq 0x4a1042(%のRIP)、%のRDI。 @ "」「」 0x1123ebace <+18>:xorl%eaxに、%eaxに 0x1123ebad0 <+20>:popq%のRBP 0x1123ebad1 <+21>:JMP 0x1125b3e90。 NSLog –

+1

@ThreeSuitStudiosLLCあなたはメモリハンドルの意味を理解する方法を見つけましたか? – Jobs

関連する問題