Change information
Commit message:
[M145] Fix crash when exiting fullscreen on Linux with Metacity WM
Original change's description:
> Fix crash when exiting fullscreen on Linux with Metacity WM
>
> This commit fixes a problem with segmentation fault when exiting
> fullscreen on X11 Linux with Metacity window manager.
>
> In the SetFullscreen(bool), function there's a workaround for a problem
> with Metacity window manager. Along with the changed introduced in
> https://crrev.com/c/7095963, exiting fullscreen causes an infinite call
> loop. The SetFullscreen(false) calls Restore(), which then calls
> SetFullscreen(false) if the window was in fullscreen mode.
>
> This commit fixes the problem by changing the Restore() and Maximize()
> functions used in the workaround to a function doing just unmaximizing
> and maximizing with the SetWMSpecState. The Restore() and Maximize()
> functions work on a higher level and decide what to do based on the
> current state. Looking at the workaround code, the intention was to just
> trigger unmaximizing and maximizing again.
>
> Bug: 476835800
> Change-Id: I77f355d30907e5343429527b9964508a4ab59be2
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7493579
> Commit-Queue: Patryk Chodur <pch...@google.com>
> Reviewed-by: Kyle Charbonneau <kyle...@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#1571323}
(cherry picked from commit 3c577742667aa686cb0f15b31654118b6d4e158e)
Bug: 477052978,476835800
Change-Id: I77f355d30907e5343429527b9964508a4ab59be2
Cr-Commit-Position: refs/branch-heads/7632@{#587}
Cr-Branched-From: 0bbdf2913883391365383b0a5dfe7bf9fd1a5213-refs/heads/main@{#1568190}
Files:
- M ui/ozone/platform/x11/x11_window.cc
- M ui/ozone/platform/x11/x11_window.h
Change size: S
Delta: 2 files changed, 16 insertions(+), 9 deletions(-)
Branch: refs/branch-heads/7632
Submit Requirements:
Code-Review: Bot-Commit+1 by Rubber Stamper