[Xfce4-commits] [xfce/xfce4-panel] 02/05: tasklist: Remove xfce_tasklist_gdk_screen_changed

noreply at xfce.org noreply at xfce.org
Sat Dec 22 23:18:44 CET 2018


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

a   j   b       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository xfce/xfce4-panel.

commit a5622dd2998ae2a8e9b935ff3099d9d43925a2fc
Author: Alistair Buxton <a.j.buxton at gmail.com>
Date:   Tue Dec 4 01:09:54 2018 +0000

    tasklist: Remove xfce_tasklist_gdk_screen_changed
    
    This does nothing useful any more since the panel doesn't receive
    these events. Other code is calling it, but it can just call the
    inner function directly and get the same result.
---
 plugins/tasklist/tasklist-widget.c | 41 +++++++++-----------------------------
 1 file changed, 9 insertions(+), 32 deletions(-)

diff --git a/plugins/tasklist/tasklist-widget.c b/plugins/tasklist/tasklist-widget.c
index d5d6d06..6f635c4 100644
--- a/plugins/tasklist/tasklist-widget.c
+++ b/plugins/tasklist/tasklist-widget.c
@@ -290,8 +290,6 @@ static void               xfce_tasklist_arrow_button_toggled             (GtkWid
                                                                           XfceTasklist         *tasklist);
 static void               xfce_tasklist_connect_screen                   (XfceTasklist         *tasklist);
 static void               xfce_tasklist_disconnect_screen                (XfceTasklist         *tasklist);
-static void               xfce_tasklist_gdk_screen_changed               (GdkScreen            *gdk_screen,
-                                                                          XfceTasklist         *tasklist);
 static gboolean           xfce_tasklist_configure_event                  (GtkWidget            *widget,
                                                                           GdkEvent             *event,
                                                                           XfceTasklist         *tasklist);
@@ -1562,7 +1560,11 @@ xfce_tasklist_connect_screen (XfceTasklist *tasklist)
       G_CALLBACK (xfce_tasklist_viewports_changed), tasklist);
 
   /* update the viewport if not all monitors are shown */
-  xfce_tasklist_gdk_screen_changed (tasklist->gdk_screen, tasklist);
+  if (!tasklist->all_monitors)
+  {
+    /* update the monitor geometry */
+    xfce_tasklist_update_monitor_geometry (tasklist);
+  }
 }
 
 
@@ -1620,23 +1622,6 @@ xfce_tasklist_disconnect_screen (XfceTasklist *tasklist)
 
 
 
-static void
-xfce_tasklist_gdk_screen_changed (GdkScreen    *gdk_screen,
-                                  XfceTasklist *tasklist)
-{
-  panel_return_if_fail (XFCE_IS_TASKLIST (tasklist));
-  panel_return_if_fail (GDK_IS_SCREEN (gdk_screen));
-  panel_return_if_fail (tasklist->gdk_screen == gdk_screen);
-
-  if (!tasklist->all_monitors)
-    {
-      /* update the monitor geometry */
-      xfce_tasklist_update_monitor_geometry (tasklist);
-    }
-}
-
-
-
 static gboolean
 xfce_tasklist_configure_event (GtkWidget    *widget,
                                GdkEvent     *event,
@@ -4022,18 +4007,10 @@ xfce_tasklist_set_include_all_monitors (XfceTasklist *tasklist,
     {
       tasklist->all_monitors = all_monitors;
 
-      /* set the geometry to invalid or update the geometry and
-       * update the visibility of the buttons */
-      if (all_monitors)
-        {
-          /* update visibility of buttons */
-          xfce_tasklist_active_workspace_changed (tasklist->screen,
-                                                  NULL, tasklist);
-        }
-      else if (tasklist->gdk_screen != NULL)
-        {
-          xfce_tasklist_gdk_screen_changed (tasklist->gdk_screen, tasklist);
-        }
+      /* update all windows */
+      if (tasklist->screen != NULL)
+        xfce_tasklist_active_workspace_changed (tasklist->screen,
+                                                NULL, tasklist);
     }
 }
 

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


More information about the Xfce4-commits mailing list