Closed Bug 1738265 Opened 3 years ago Closed 3 years ago

Context menu and other popups open 4px to the right

Categories

(Core :: Widget: Gtk, defect)

defect

Tracking

()

VERIFIED FIXED
96 Branch
Tracking Status
firefox-esr78 --- unaffected
firefox-esr91 --- unaffected
firefox93 --- unaffected
firefox94 --- unaffected
firefox95 + verified
firefox96 --- verified

People

(Reporter: emilio, Assigned: emilio)

References

(Regressed 1 open bug, Regression)

Details

(Keywords: regression)

Attachments

(5 files)

After bug 1738084, the context menu opens a bit too much to the right, because we don't offset the menupopup position by the box shadow.

This doesn't change behavior but I did it while debugging and I think it's
probably worth landing, as it shows the expected values rather than just the
fail message.

Depends on D129817

For tests that actually test margin handling I've just removed the default
margin by adding:

<?xml-stylesheet href="data:text/css,menupopup{margin: 0}" type="text/css"?>

The other tests I've just fixed by accounting for the margins.

Depends on D129865

With the negative margin, some context menus that remain open start
getting events that would otherwise go to the content underneath
(and which the affected tests need to pass).

Close the context menus explicitly in the affected tests (this is
what would usually happen if a user clicked a context menu item
anyways).

Depends on D129866

Set release status flags based on info from the regressing bug 1738084

Keywords: leave-open
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/102ff2b893ea Improve some popup tests. r=NeilDeakin https://hg.mozilla.org/integration/autoland/rev/a2c91530a996 Teach some popup tests to deal with popups having margins by default. r=NeilDeakin
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0cc74dde6707 Trivially fix other two popup tests that I had missed. r=stransky

[Tracking Requested - why for this release]: Popups are off on Linux without this fix. We could also consider backing out bug 1738084, but given we're early on the beta cycle uplifting this would be ideal.

Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/8be1706fa428 Explicitly close some devtools menus in some tests. r=nchevobbe,devtools-reviewers
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e8a05519f047 Add a negative margin to popups to account for the shadow added in bug 1738084. r=stransky

Backed out for causing mochitest failures on test_largemenu.html.

Push with failures

Failure log for c3
Failure log for c1

Backout link

This happened only on Linux 18.04 x64 WebRender debug.

Flags: needinfo?(emilio)
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/02a2d91ce5d2 Add a negative margin to popups to account for the shadow added in bug 1738084. r=stransky
Flags: needinfo?(emilio)
Keywords: leave-open
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch

Emilio, do you want to request uplift to beta? Thanks

Flags: needinfo?(emilio)

Comment on attachment 9248499 [details]
Bug 1738265 - Trivially fix other two popup tests that I had missed. r=NeilDeakin,stransky

Beta/Release Uplift Approval Request

  • User impact if declined: Popups open too much to the right on Linux
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: comment 0
  • List of other uplifts needed: none
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): It's really just one-line CSS fix, but it needed a ton of test changes.
  • String changes made/needed: none
Flags: needinfo?(emilio)
Attachment #9248499 - Flags: approval-mozilla-beta?
Attachment #9248246 - Flags: approval-mozilla-beta?
Attachment #9248314 - Flags: approval-mozilla-beta?
Attachment #9248315 - Flags: approval-mozilla-beta?
Attachment #9248316 - Flags: approval-mozilla-beta?
Flags: qe-verify+
Blocks: 1739383

Comment on attachment 9248499 [details]
Bug 1738265 - Trivially fix other two popup tests that I had missed. r=NeilDeakin,stransky

Approved for 95 beta 3, thanks.

Attachment #9248499 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9248246 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9248314 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9248315 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9248316 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

The first patches had landed on 95 nightly before the merge, I only uplifted the remaining patches that landed in 96 after the merge.

Verified as fixed on Ubuntu 20.04 x64 on Firefox Nightly 96.0a1 and on Firefox 95.0b2.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Regressions: 1750102
Has Regression Range: --- → yes
Regressions: 1875996
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: