mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1161215 - Don't fire spurious resize events to content when the size didn't actually change. r=smaug
This commit is contained in:
parent
8b49142b57
commit
09504ce74e
@ -2029,8 +2029,11 @@ TabChild::RecvUpdateDimensions(const nsIntRect& rect, const ScreenIntSize& size,
|
||||
|
||||
bool initialSizing = !HasValidInnerSize()
|
||||
&& (size.width != 0 && size.height != 0);
|
||||
bool sizeChanged = true;
|
||||
if (initialSizing) {
|
||||
mHasValidInnerSize = true;
|
||||
} else if (mInnerSize == size) {
|
||||
sizeChanged = false;
|
||||
}
|
||||
|
||||
mOrientation = orientation;
|
||||
@ -2051,7 +2054,9 @@ TabChild::RecvUpdateDimensions(const nsIntRect& rect, const ScreenIntSize& size,
|
||||
InitializeRootMetrics();
|
||||
}
|
||||
|
||||
HandlePossibleViewportChange(oldScreenSize);
|
||||
if (sizeChanged) {
|
||||
HandlePossibleViewportChange(oldScreenSize);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user