如何用代码调整CollectionViewCell的宽度

2025-04-07 16:09:54
推荐回答(1个)
回答1:

这是swift的
func collectionView(collectionView: UICollectionView!, layout collectionViewLayout: UICollectionViewLayout!, sizeForItemAtIndexPath indexPath: NSIndexPath!) -> CGSize{

return CGSizeMake(90, 40)
}