Don't unnecessarily MoveResize windows if they haven't moved or resized.
Categories
(Core :: Widget: Gtk, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox106 | --- | fixed |
People
(Reporter: emilio, Assigned: emilio)
References
Details
Attachments
(1 file)
Assignee | ||
Comment 1•3 years ago
|
||
I was looking into bug 1786525 and this caused some useless
notifications which we can avoid.
Comment 3•3 years ago
|
||
bugherder |
This patch broke window.resizeTo()
for me on Plasma Wayland. Confirmed with mozregression.
STR:
- Open Firefox. If its window is maximized, restore it to a smaller size.
- Manually resize it a bit (move mouse to border until cursor turns to bidirectional arrow, then drag a bit to the side).
- Maximize the window.
- Open Browser Console and run
window.resizeTo(500, 500)
- you can change values if you wish.
Expected:
Window should resize to 500px width and 500px height.
Actual result:
Window revert to previous size before it was maximized, the size after the resizing you did in step 2.
Important:
Do not run window.resizeTo
or similar in step 2. Step 2 must be a manual resize, don't ask me why.
Assignee | ||
Comment 6•3 years ago
|
||
I'm surprised that ResizeTo on wayland used to work at all? IIRC we can't control the width of the window on Wayland, so just unmaximizing and restoring seems reasonable. But yeah if it used to work please file a bug and I can look.
I switched from X11 to Plasma like 3 months ago and it always worked like that. What programs can't control is window position, not size. mpv for example, I have it configured to resize its window by itself according to video aspect ratio, but regarding position it can't do anthing on Wayland, so I had to create a KWin Window Rule (compositor). The same applies to Firefox, it restores window size from previous session but can't restore position.
So resizeTo
works on Firefox Wayland, what doesn't work is moveTo
. Even with this patch, resizeTo
still works most of the time, the bug is only in a specific circumstance.
I'll fill the bug now.
Description
•