Closed Bug 1994918 Opened 5 months ago Closed 3 months ago

Double clicking over top or bottom border of a window to vertical maximize stopped working

Categories

(Core :: Widget: Win32, defect)

Firefox 145
Desktop
Windows 11
defect

Tracking

()

RESOLVED FIXED
148 Branch
Tracking Status
firefox-esr115 --- unaffected
firefox-esr140 --- unaffected
firefox145 --- wontfix
firefox146 --- wontfix
firefox147 --- fixed
firefox148 --- fixed

People

(Reporter: coluf, Assigned: gstoll)

References

(Regression)

Details

(Keywords: regression)

Attachments

(4 files, 1 obsolete file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:145.0) Gecko/20100101 Firefox/145.0

Steps to reproduce:

Move the mouse pointer to the top or bottom border of a window until the pointer turns into a double arrow, and double click/tap.

Actual results:

No change to window size

Expected results:

Window should have maximized vertically to screen but no change to horizontal width. Useful for very wide monitors.
This feature worked with previous versions of Firefox.

Tested on MS-Windows 11 only.

The Bugbug bot thinks this bug should belong to the 'Firefox for Android::General' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → General
Product: Firefox → Firefox for Android

This is a Firefox regression on Windows. Not Android.
Windows keyboard shortcut still works (Windows + Shift + Up-Arrow) to vertically maximize a window
(Windows + Shift + Down-Arrow) to restore original window size and position

I confirm the issue on Windows 11.

Bisection result:
Bug 1947324 part 6 - avoid using Windows App SDK on opt-talos-xperf runs r=bobowen,perftest-reviewers,kshampur

On opt-talos-xperf, the Windows App SDK fails
calling DCompositionCreateDevice3() with ERROR_ACCESS_DENIED,
and the code assumes it is going to succeed so it proceeds to crash
deferencing null.

We haven't seen this crash anywhere else, and so I suspect this has
something to do with the way Firefox is being run there. So add a pref
to turn off using the Windows App SDK for just this test.

If this turns out to cause crashes in other situations, we should figure
out what the situation is and try to fix it.

Differential Revision: https://phabricator.services.mozilla.com/D267040

OS: Unspecified → Windows 11
Product: Firefox for Android → Firefox Build System
Hardware: Unspecified → Desktop
Component: General → Widget: Win32
Product: Firefox Build System → Core

Could someone edit the "Regressed by" field and add there bug 1947324?
I don't have permissions for that.

Keywords: regression
Regressed by: 1947324

:gstoll, since you are the author of the regressor, bug 1947324, could you take a look? Also, could you set the severity field?

For more information, please visit BugBot documentation.

Flags: needinfo?(gstoll)
Severity: -- → S4
Flags: needinfo?(gstoll)

Note that this double-clicking does work on Chrome and Edge, but it doesn't work on Notepad or Windows Explorer.

That's interesting, maybe it's also a bug? :)
I always thought this is an OS feature.
It definitely works with all 3rd party apps I can currently find on my PC, including alternatives to the mentioned ones: "Notepad++" and "Q-Dir the Quad Explorer" :).

The bug says this, but just a note to myself: this does not work for the left/right sides of the window (nor does it in Chrome, etc.)

My potential fix for bug 1993474 seems to fix this too. (removing WS_BORDER)

Duplicate of this bug: 2000408
Duplicate of this bug: 2002325

Does the fix for the bug 1993474 fix this issue?
I'm trying in the current Nightly but it doesn't seem to help, only the cursor now changes during double-click.
Also, maybe unrelated, the toolbar in the about:firefox modal is now totally broken - the close button is stretched over the whole bar. Can you see that too?

Note that on the latest Nightly this works when the native titlebar is being shown (perhaps because of bug 2002986?), but it's still broken when tabs are in the titlebar. :emilio had an idea on how to fix this that I'm going to try.

(the about:firefox titlebar now looks fine to me on the latest nightly)

Assignee: nobody → gstoll
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

Something in the Windows App SDK's WNDPROC is causing the
double-clicking on the top/bottom border to not expand the window
vertically. (I suspect this is a bug, as this also happens in Notepad
with tabs in the titlebar)

So, similar to what we did in bug 1993474, don't even use the Windows
App SDK's WNDPROC as the previous WNDPROC to fall back to; instead, get
the previous WNDPROC before we call into the Windows App SDK and use
that.

See Also: → 2004018

If we just redirect the WM_NCLBUTTONDBLCLK message, we can fix this in a less intrusive way.

Attachment #9530458 - Attachment is obsolete: true
Status: ASSIGNED → RESOLVED
Closed: 3 months ago
Resolution: --- → FIXED
Target Milestone: --- → 148 Branch

The patch landed in nightly and beta is affected.
:gstoll, is this bug important enough to require an uplift?

For more information, please visit BugBot documentation.

Flags: needinfo?(gstoll)
Attachment #9532046 - Flags: approval-mozilla-beta?

firefox-beta Uplift Approval Request

  • User impact if declined: Restores double-click functionality on Windows that has been broken since Fx 145.
  • Code covered by automated testing: no
  • Fix verified in Nightly: yes
  • Needs manual QE test: no
  • Steps to reproduce for manual QE testing: n/a
  • Risk associated with taking this patch: low
  • Explanation of risk level: Only affects the WM_NCLBUTTONDBLCLK message.
  • String changes made/needed: no
  • Is Android affected?: no
Flags: needinfo?(gstoll)
Attachment #9532046 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Pushed by gstoll@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/2ef746250dc8 https://hg.mozilla.org/integration/autoland/rev/3c5b868a606b part 2 - improve windows message debug output for WM_NCHITTEST r=win-reviewers,handyman
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: