diff options
author | Daniel Drake <drake@endlessm.com> | 2014-01-02 09:49:10 -0600 |
---|---|---|
committer | Daniel Drake <drake@endlessm.com> | 2014-01-06 16:16:07 -0600 |
commit | d654c93ed2a804642d5eda9f4dce7ecc62442609 (patch) | |
tree | 50a661bd28ee9dd341e70378d1c45d51f6dae7f9 | |
parent | 7d1611f666355fd784042b91996815f8c6bdade1 (diff) |
frame: remove unnecessary server grab
meta_window_ensure_frame() creates its own grab and has a comment
claiming that it must be called under a grab too.
But the reasoning given in the comment does not seem relevant here.
We only frame non-override-redirect windows, so we are creating
the frame in response to MapRequest. There is no way that the child
could receive a MapNotify at this point, since that only happens
much later, once we go through the CALC_SHOWING queue and call
XMapWindow() from meta_window_show().
Remove the unnecessary grab.
https://bugzilla.gnome.org/show_bug.cgi?id=721345
-rw-r--r-- | src/core/frame.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/core/frame.c b/src/core/frame.c index 2c48bb16..7e1a30f9 100644 --- a/src/core/frame.c +++ b/src/core/frame.c @@ -51,9 +51,6 @@ meta_window_ensure_frame (MetaWindow *window) if (window->frame) return; - /* See comment below for why this is required. */ - meta_display_grab (window->display); - frame = g_new (MetaFrame, 1); frame->window = window; @@ -116,14 +113,6 @@ meta_window_ensure_frame (MetaWindow *window) meta_display_register_x_window (window->display, &frame->xwindow, window); - /* Reparent the client window; it may be destroyed, - * thus the error trap. We'll get a destroy notify later - * and free everything. Comment in FVWM source code says - * we need a server grab or the child can get its MapNotify - * before we've finished reparenting and getting the decoration - * window onscreen, so ensure_frame must be called with - * a grab. - */ meta_error_trap_push (window->display); if (window->mapped) { @@ -165,8 +154,6 @@ meta_window_ensure_frame (MetaWindow *window) /* Move keybindings to frame instead of window */ meta_window_grab_keys (window); - - meta_display_ungrab (window->display); } void |