假设我有一个包含10个文件的评论请求 从差异1和2,我只改变了1个文件
func targetContentOffsetForProposedContentOffset(proposedContentOffset:CGPoint, velocity: CGPoint) -> CGPoint
{
let collectionViewSize:CGSize = self.collectionView.bounds.size
let proposedContentOffsetCenterX:CGFloat = proposedContentOffset.x + self.collectionView.bounds.size.width * 0.5
let proposedRect:CGRect = self.collectionView.bounds
//let candidateAttributes:UICollectionViewLayoutAttributes
var candidateAttributes:[UICollectionViewLayoutAttributes]
/* get stuck here in for loop*/
for (attributes: [UICollectionViewLayoutAttributes] in layoutAttributesForElementsInRect:proposedRect)
{
}
上面的代码显示了相同数量的文件client = RBClient()
root = client.get_root()
files = root.get_files(review_request_id=1, diff_revision=1)
files2 = root.get_files(review_request_id=1, diff_revision=2)
如何才能获取在diff 2中修改过的文件?