firefox/mozilla-1661192.patch
Petr Šabata 268ae0028c RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/firefox#c8daf71be4963daab37d810024e0a6e7f04cf2dd
2020-10-15 00:23:49 +02:00

26 lines
908 B
Diff

diff --git a/widget/gtk/nsWindow.cpp b/widget/gtk/nsWindow.cpp
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -1600,9 +1600,11 @@
#endif
}
+ bool hasAnchorRect = true;
if (anchorRect.width == 0) {
LOG((" No anchor rect given, use aPosition for anchor"));
anchorRect.SetRect(aPosition->x, aPosition->y, 1, 1);
+ hasAnchorRect = false;
}
LOG((" anchor x %d y %d width %d height %d (absolute coords)\n",
anchorRect.x, anchorRect.y, anchorRect.width, anchorRect.height));
@@ -1704,7 +1706,7 @@
nsPoint cursorOffset(0, 0);
#ifdef MOZ_WAYLAND
// Offset is already computed to the tooltips
- if (popupFrame && mPopupType != ePopupTypeTooltip) {
+ if (hasAnchorRect && popupFrame && mPopupType != ePopupTypeTooltip) {
nsMargin margin(0, 0, 0, 0);
popupFrame->StyleMargin()->GetMargin(margin);
switch (popupFrame->GetPopupAlignment()) {