mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 20:01:11 +00:00
Fix warnings and errors, apply attributes from NSCollectionViewLayoutAttributes to view
This commit is contained in:
parent
68f1444de3
commit
b7eb68b67c
2 changed files with 10 additions and 6 deletions
|
@ -1393,10 +1393,16 @@ static NSString *placeholderItem = nil;
|
|||
NSView *v = [item view];
|
||||
NSCollectionViewLayoutAttributes *attrs =
|
||||
[_collectionViewLayout layoutAttributesForItemAtIndexPath: p];
|
||||
NSRect f = [attrs frame];
|
||||
|
||||
// set position of item based on currently selected layout...
|
||||
[v setFrame: f];
|
||||
NSRect frame = [attrs frame];
|
||||
BOOL hidden = [attrs isHidden];
|
||||
CGFloat alpha = [attrs alpha];
|
||||
NSSize sz = [attrs size];
|
||||
|
||||
// set attributes of item based on currently selected layout...
|
||||
frame.size = sz;
|
||||
[v setFrame: frame];
|
||||
[v setHidden: hidden];
|
||||
[v setAlphaValue: alpha];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -178,8 +178,6 @@
|
|||
- (void) prepareLayout
|
||||
{
|
||||
[super prepareLayout];
|
||||
_invalidateFlowLayoutAttributes = NO;
|
||||
_invalidateFlowLayoutDelegateMetrics = NO;
|
||||
}
|
||||
|
||||
- (NSArray *) layoutAttributesForElementsInRect: (NSRect)rect
|
||||
|
|
Loading…
Reference in a new issue