emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs-26 4e58ca8: Document internal use of 'above-suspende


From: Martin Rudalics
Subject: [Emacs-diffs] emacs-26 4e58ca8: Document internal use of 'above-suspended' z-group frame parameter
Date: Sun, 1 Jul 2018 04:23:41 -0400 (EDT)

branch: emacs-26
commit 4e58ca87f99d08a91d37a41c2d18f7a1f23fa8c6
Author: Martin Rudalics <address@hidden>
Commit: Martin Rudalics <address@hidden>

    Document internal use of 'above-suspended' z-group frame parameter
    
    * src/w32fns.c (w32_dialog_in_progress, x_set_z_group):
    * src/xterm.c (x_set_z_group): Clarify the internal use of
    'above-suspended' when setting a frame's 'z-group' parameter.
---
 src/w32fns.c | 22 +++++++++++++++++++++-
 src/xterm.c  |  4 ++++
 2 files changed, 25 insertions(+), 1 deletion(-)

diff --git a/src/w32fns.c b/src/w32fns.c
index e50b7d5..1b199bf 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -2192,6 +2192,11 @@ x_set_no_accept_focus (struct frame *f, Lisp_Object 
new_value, Lisp_Object old_v
  *
  * Some window managers may not honor this parameter.  The value `below'
  * is not supported on Windows.
+ *
+ * Internally, this function also handles a value 'above-suspended'.
+ * That value is used to temporarily remove F from the 'above' group
+ * to make sure that it does not obscure the window of a dialog in
+ * progress.
  */
 static void
 x_set_z_group (struct frame *f, Lisp_Object new_value, Lisp_Object old_value)
@@ -7726,12 +7731,27 @@ file_dialog_callback (HWND hwnd, UINT msg, WPARAM 
wParam, LPARAM lParam)
   return 0;
 }
 
+/**
+ * w32_dialog_in_progress:
+ *
+ * This function is called by Fx_file_dialog and Fx_select_font and
+ * serves to temporarily remove any Emacs frame currently in the
+ * 'above' z-group from that group to assure that such a frame does
+ * not hide the dialog window.  Frames that are temporarily removed
+ * from the 'above' group have their z_group bit-field set to
+ * z_group_above_suspended.  Any such frame is moved back to the
+ * 'above' group as soon as the dialog finishes and has its z_group
+ * bit-field reset to z_group_above.
+ *
+ * This function does not affect the z-order or the z-group state of
+ * the dialog window itself.
+ */
 void
 w32_dialog_in_progress (Lisp_Object in_progress)
 {
   Lisp_Object frames, frame;
 
-  /* Don't let frames in `above' z-group obscure popups.  */
+  /* Don't let frames in `above' z-group obscure dialog windows.  */
   FOR_EACH_FRAME (frames, frame)
     {
       struct frame *f = XFRAME (frame);
diff --git a/src/xterm.c b/src/xterm.c
index 496effa..a564691 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -10560,6 +10560,10 @@ x_set_skip_taskbar (struct frame *f, Lisp_Object 
new_value, Lisp_Object old_valu
  * windows that do not have the `below' property set.
  *
  * Some window managers may not honor this parameter.
+ *
+ * Internally, this function also handles a value 'above-suspended'.
+ * That value is used to temporarily remove F from the 'above' group
+ * to make sure that it does not obscure a menu currently popped up.
  */
 void
 x_set_z_group (struct frame *f, Lisp_Object new_value, Lisp_Object old_value)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]