mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-09 10:20:07 +00:00
macos: only invalidate tiles when size changes
If the size changes, we need to relayout the tiles. Otherwise we can keep using what we had before. Generally, that shouldn't happen, but the previous check was failing in a number of ways.
This commit is contained in:
parent
42164fa8bb
commit
df8e2bc0a0
@ -317,13 +317,14 @@ fromCGRect (const CGRect rect)
|
||||
|
||||
-(void)setFrame:(NSRect)frame
|
||||
{
|
||||
if (CGRectEqualToRect (frame, self.frame))
|
||||
return;
|
||||
|
||||
self->_layoutInvalid = TRUE;
|
||||
if (frame.size.width != self.bounds.size.width ||
|
||||
frame.size.height != self.bounds.size.height)
|
||||
{
|
||||
self->_layoutInvalid = TRUE;
|
||||
[self setNeedsLayout];
|
||||
}
|
||||
|
||||
[super setFrame:frame];
|
||||
[self setNeedsLayout];
|
||||
}
|
||||
|
||||
-(void)setOpaqueRegion:(const cairo_region_t *)opaqueRegion
|
||||
|
Loading…
Reference in New Issue
Block a user