firefox/D147266.diff

32 lines
1.3 KiB
Diff
Raw Normal View History

2022-05-25 09:52:47 +00:00
diff --git a/widget/gtk/nsWindow.cpp b/widget/gtk/nsWindow.cpp
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -1430,20 +1430,20 @@
}
#endif
if (popup->mPopupContextMenu && !popup->mPopupAnchored) {
LOG(" popup [%p] is first context menu", popup);
popup->mRelativePopupPosition = popup->mPopupPosition;
- } else if (popup->mPopupAnchored) {
- LOG(" popup [%p] is anchored", popup);
- if (!popup->mPopupMatchesLayout) {
- NS_WARNING("Anchored popup does not match layout!");
- }
- popup->mRelativePopupPosition = popup->mPopupPosition;
} else if (popup->mWaylandPopupPrev->mWaylandToplevel == nullptr) {
LOG(" popup [%p] has toplevel as parent", popup);
popup->mRelativePopupPosition = popup->mPopupPosition;
} else {
+ if (popup->mPopupAnchored) {
+ LOG(" popup [%p] is anchored", popup);
+ if (!popup->mPopupMatchesLayout) {
+ NS_WARNING("Anchored popup does not match layout!");
+ }
+ }
GdkPoint parent = WaylandGetParentPosition();
LOG(" popup [%p] uses transformed coordinates\n", popup);
LOG(" parent position [%d, %d]\n", parent.x, parent.y);
LOG(" popup position [%d, %d]\n", popup->mPopupPosition.x,