From f82e52b7a2b880b82214b3124f9fb390631dc94b Mon Sep 17 00:00:00 2001 From: daboe01 Date: Thu, 26 Jun 2014 18:06:50 +0200 Subject: [PATCH] correction of height calculation --- AppKit/CPCollectionView.j | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AppKit/CPCollectionView.j b/AppKit/CPCollectionView.j index 2b6505682..0bd92dc1c 100644 --- a/AppKit/CPCollectionView.j +++ b/AppKit/CPCollectionView.j @@ -623,7 +623,7 @@ var HORIZONTAL_MARGIN = 2; height = MAX(height, numberOfRows * (_minItemSize.height + _verticalMargin)); - var itemSizeHeight = itemSize.height; + var itemSizeHeight = FLOOR(height / numberOfRows) - _verticalMargin; if (maxItemSizeHeight > 0) itemSizeHeight = MIN(itemSizeHeight, maxItemSizeHeight);