summaryrefslogtreecommitdiff
path: root/src/x11/events.c
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2023-03-01 17:43:24 +0100
committerMarge Bot <marge-bot@gnome.org>2023-05-16 15:34:25 +0000
commit3218626d7e1c1c9466ad5c64558cf9ace5b68926 (patch)
tree9c1043cc371a651ecf2d7704add34503e00bda13 /src/x11/events.c
parentb9a6891910c2c07226d66738aca488160585e726 (diff)
downloadmutter-3218626d7e1c1c9466ad5c64558cf9ace5b68926.tar.gz
x11: Do not unminimize windows with initial IconicState
This is a revert of commit be5c2ebc, adapted to this day and age. While this worked around issues in wine/proton, it did contravene icccm in the interpretation of initially iconic windows. Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/2043 Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3001>
Diffstat (limited to 'src/x11/events.c')
-rw-r--r--src/x11/events.c34
1 files changed, 12 insertions, 22 deletions
diff --git a/src/x11/events.c b/src/x11/events.c
index 90d07cb5e..00f34e221 100644
--- a/src/x11/events.c
+++ b/src/x11/events.c
@@ -1528,32 +1528,22 @@ handle_other_xevent (MetaX11Display *x11_display,
window = meta_window_x11_new (display, event->xmaprequest.window,
FALSE, META_COMP_EFFECT_CREATE);
- /* The window might have initial iconic state, but this is a
- * MapRequest, fall through to ensure it is unminimized in
- * that case.
- */
}
- else if (frame_was_receiver)
+ else
{
- break;
- }
+ meta_verbose ("MapRequest on %s mapped = %d minimized = %d",
+ window->desc, window->mapped, window->minimized);
- /* Double check that creating the MetaWindow succeeded */
- if (window == NULL)
- break;
-
- meta_verbose ("MapRequest on %s mapped = %d minimized = %d",
- window->desc, window->mapped, window->minimized);
-
- if (window->minimized)
- {
- meta_window_unminimize (window);
- if (window->workspace != workspace_manager->active_workspace)
+ if (window->minimized && !frame_was_receiver)
{
- meta_verbose ("Changing workspace due to MapRequest mapped = %d minimized = %d",
- window->mapped, window->minimized);
- meta_window_change_workspace (window,
- workspace_manager->active_workspace);
+ meta_window_unminimize (window);
+ if (window->workspace != workspace_manager->active_workspace)
+ {
+ meta_verbose ("Changing workspace due to MapRequest mapped = %d minimized = %d",
+ window->mapped, window->minimized);
+ meta_window_change_workspace (window,
+ workspace_manager->active_workspace);
+ }
}
}
break;