diff options
| author | Tino Calancha | 2020-08-15 16:18:03 +0200 |
|---|---|---|
| committer | Tino Calancha | 2020-08-15 16:18:03 +0200 |
| commit | 3c4edfd85ee8f49e40715a400a1fc65950e07482 (patch) | |
| tree | b652c0f105b76d4abc1c3765febb647fb25144d0 /src/xterm.c | |
| parent | 98e824199263d4f47200bb3cf60226c5125d700b (diff) | |
| download | emacs-3c4edfd85ee8f49e40715a400a1fc65950e07482.tar.gz emacs-3c4edfd85ee8f49e40715a400a1fc65950e07482.zip | |
Prevent from frozen frame after `C-z' in Lucid builds
Some WMs (e.g. mutter in Gnome Shell) don't unmap iconized windows,
thus we won't get a MapNotify when deconifying them.
Check if we are deconifying a window elsewhere (Bug#42655).
- src/xterm.c (handle_one_xevent):
Check for window deconify when receiving a FocusIn signal.
Diffstat (limited to 'src/xterm.c')
| -rw-r--r-- | src/xterm.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/xterm.c b/src/xterm.c index 44396955ed0..a567ab163af 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -8762,6 +8762,20 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 8762 | goto OTHER; | 8762 | goto OTHER; |
| 8763 | 8763 | ||
| 8764 | case FocusIn: | 8764 | case FocusIn: |
| 8765 | /* Some WMs (e.g. Mutter in Gnome Shell), don't unmap | ||
| 8766 | minimized/iconified windows; thus, for those WMs we won't get | ||
| 8767 | a MapNotify when unminimizing/deconifying. Check here if we | ||
| 8768 | are deconizing a window (Bug42655). */ | ||
| 8769 | f = any; | ||
| 8770 | if (f && FRAME_ICONIFIED_P (f)) | ||
| 8771 | { | ||
| 8772 | SET_FRAME_VISIBLE (f, 1); | ||
| 8773 | SET_FRAME_ICONIFIED (f, false); | ||
| 8774 | f->output_data.x->has_been_visible = true; | ||
| 8775 | inev.ie.kind = DEICONIFY_EVENT; | ||
| 8776 | XSETFRAME (inev.ie.frame_or_window, f); | ||
| 8777 | } | ||
| 8778 | |||
| 8765 | x_detect_focus_change (dpyinfo, any, event, &inev.ie); | 8779 | x_detect_focus_change (dpyinfo, any, event, &inev.ie); |
| 8766 | goto OTHER; | 8780 | goto OTHER; |
| 8767 | 8781 | ||