[Xfce4-commits] [xfce/xfwm4] 16/32: Remove black_gc and white_gc

noreply at xfce.org noreply at xfce.org
Tue Dec 5 09:22:02 CET 2017


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

o   l   i   v   i   e   r       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/xfwm4.

commit b4e3a24409bad27683c563c6b3fc188e2d43d9d0
Author: Viktor Odintsev <zakhams at gmail.com>
Date:   Mon Jul 3 06:58:04 2017 +0300

    Remove black_gc and white_gc
---
 src/screen.c    |  2 --
 src/screen.h    |  2 --
 src/settings.c  | 14 --------------
 src/wireframe.c |  6 +++---
 4 files changed, 3 insertions(+), 21 deletions(-)

diff --git a/src/screen.c b/src/screen.c
index 74342f2..e0252d5 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -306,8 +306,6 @@ myScreenInit (DisplayInfo *display_info, GdkScreen *gscr, unsigned long event_ma
 
     screen_info->font_height = 0;
     screen_info->box_gc = None;
-    screen_info->black_gc = NULL;
-    screen_info->white_gc = NULL;
     screen_info->title_colors[ACTIVE].gc = NULL;
     screen_info->title_colors[ACTIVE].allocated = FALSE;
     screen_info->title_colors[INACTIVE].gc = NULL;
diff --git a/src/screen.h b/src/screen.h
index e29f4e9..e35cc0f 100644
--- a/src/screen.h
+++ b/src/screen.h
@@ -96,8 +96,6 @@ struct _ScreenInfo
 
     /* Per screen graphic contexts */
     GC box_gc;
-    GdkGC *black_gc;
-    GdkGC *white_gc;
 
     /* Title font height */
     gint font_height;
diff --git a/src/settings.c b/src/settings.c
index a0dbb4a..3d7065b 100644
--- a/src/settings.c
+++ b/src/settings.c
@@ -509,20 +509,6 @@ loadTheme (ScreenInfo *screen_info, Settings *rc)
     setXfwmColor (screen_info, &screen_info->title_shadow_colors[ACTIVE], rc, 2, "dark", "selected");
     setXfwmColor (screen_info, &screen_info->title_shadow_colors[INACTIVE], rc, 3, "dark", "insensitive");
 
-    if (screen_info->black_gc)
-    {
-        g_object_unref (G_OBJECT (screen_info->black_gc));
-    }
-    screen_info->black_gc = widget->style->black_gc;
-    g_object_ref (G_OBJECT (widget->style->black_gc));
-
-    if (screen_info->white_gc)
-    {
-        g_object_unref (G_OBJECT (screen_info->white_gc));
-    }
-    screen_info->white_gc = widget->style->white_gc;
-    g_object_ref (G_OBJECT (widget->style->white_gc));
-
     for (i = 0; i < SIDE_COUNT; i++)
     {
         if (i == SIDE_TOP)
diff --git a/src/wireframe.c b/src/wireframe.c
index 44790e1..9ac4e17 100644
--- a/src/wireframe.c
+++ b/src/wireframe.c
@@ -94,11 +94,11 @@ wireframeDrawXlib (WireFrame *wireframe, int width, int height)
         wireframe->mapped = TRUE;
 
         XDrawRectangle (myScreenGetXDisplay (screen_info), wireframe->xwindow,
-                        gdk_x11_gc_get_xgc (screen_info->white_gc),
+                        screen_info->box_gc,
                         0, 0, wireframe->width - 1, wireframe->height - 1);
 
         XDrawRectangle (myScreenGetXDisplay (screen_info), wireframe->xwindow,
-                        gdk_x11_gc_get_xgc (screen_info->white_gc),
+                        screen_info->box_gc,
                         OUTLINE_WIDTH - 1, OUTLINE_WIDTH - 1,
                         wireframe->width - 2 * (OUTLINE_WIDTH - 1) - 1,
                         wireframe->height- 2 * (OUTLINE_WIDTH - 1) - 1);
@@ -112,7 +112,7 @@ wireframeDrawXlib (WireFrame *wireframe, int width, int height)
         wireframe->mapped = TRUE;
 
         XDrawRectangle (myScreenGetXDisplay (screen_info), wireframe->xwindow,
-                        gdk_x11_gc_get_xgc (screen_info->white_gc),
+                        screen_info->box_gc,
                         0, 0, wireframe->width - 1, wireframe->height - 1);
     }
 }

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


More information about the Xfce4-commits mailing list