[Xfce4-commits] [xfce/xfce4-panel] 01/01: Fixing problems with intelligent panel hiding, bug #11331

noreply at xfce.org noreply at xfce.org
Wed Nov 26 21:18:17 CET 2014


This is an automated email from the git hooks/post-receive script.

andrzejr pushed a commit to branch master
in repository xfce/xfce4-panel.

commit 57502718bfbbc4bc6806bef5f0f675c82d2effa4
Author: Andrzej <ndrwrdck at gmail.com>
Date:   Wed Nov 26 20:18:04 2014 +0000

    Fixing problems with intelligent panel hiding, bug #11331
    
    ochosi:
    "Just to document the findings I made during a quick debug session
    with the panel from git master (4.11.x). Intelligent hiding
    generally works, but the mouse-pointer behavior is buggy.
    Steps to reproduce the bug:
    1) set panel to intelligent hiding
    2) give a window focus that doesn't overlap with the panel
    3) hover the panel with the mouse
    4) upon leaving the panel hides again, even though there
       is no window overlapping
    
    What it should do instead: if intelligent hiding is in use
    it should check (possibly in panel_window_leave_notify_event
    or _enter_ in panel-window.c) whether there are windows
    overlapping with the panel and if not, the panel shouldn't
    hide on leave_notify."
---
 panel/panel-window.c |   10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/panel/panel-window.c b/panel/panel-window.c
index 4d7924c..e7d670c 100644
--- a/panel/panel-window.c
+++ b/panel/panel-window.c
@@ -916,8 +916,14 @@ panel_window_leave_notify_event (GtkWidget        *widget,
    /* queue an autohide timeout if needed */
   if (event->detail != GDK_NOTIFY_INFERIOR
       && window->autohide_state != AUTOHIDE_DISABLED
-      && window->autohide_state != AUTOHIDE_BLOCKED)
-    panel_window_autohide_queue (window, AUTOHIDE_POPDOWN);
+      && window->autohide_state != AUTOHIDE_BLOCKED) {
+    /* simulate a geometry change to check for overlapping windows with intelligent hiding */
+    if (window->autohide_behavior == AUTOHIDE_BEHAVIOR_INTELLIGENTLY)
+      panel_window_active_window_geometry_changed (window->wnck_active_window, window);
+    /* otherwise just hide the panel */
+    else
+      panel_window_autohide_queue (window, AUTOHIDE_POPDOWN);
+  }
 
   return (*GTK_WIDGET_CLASS (panel_window_parent_class)->leave_notify_event) (widget, event);
 }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list