mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-08 09:58:02 +00:00
Throw an exception when trying to set a null minimum item size for a collection view.
This commit is contained in:
1 parent
3a8ad56d4b
commit
4b764dc8b4
1 file changed
+3
-1
@@ -475,7 +475,7 @@
|
||||
}
|
||||
|
||||
var superview = [self superview],
|
||||
proposedHeight = y + itemSize.height + _verticalMargin;
|
||||
proposedHeight = y + itemSize.height + _verticalMargin;
|
||||
|
||||
if ([superview isKindOfClass:[CPClipView class]])
|
||||
{
|
||||
@@ -561,6 +561,8 @@
|
||||
*/
|
||||
- (void)setMinItemSize:(CGSize)aSize
|
||||
{
|
||||
if (aSize === nil || aSize === undefined)
|
||||
[CPException raise:CPInvalidArgumentException reason:"Invalid value provided for minimum size"];
|
||||
if (CGSizeEqualToSize(_minItemSize, aSize))
|
||||
return;
|
||||
|
||||
|
||||
Reference in new issue
Block a user