[Xfce4-commits] <xfdesktop:master> Fix some compiler warnings.

Nick Schermer noreply at xfce.org
Fri Apr 22 18:36:01 CEST 2011


Updating branch refs/heads/master
         to a2ad6f5eddb8d3532256dc04d1823650fb5df8f3 (commit)
       from 85ec0bc3192058fbe5abe93653c5ab823620850a (commit)

commit a2ad6f5eddb8d3532256dc04d1823650fb5df8f3
Author: Nick Schermer <nick at xfce.org>
Date:   Fri Apr 22 17:42:57 2011 +0200

    Fix some compiler warnings.

 src/windowlist.c                  |    6 ------
 src/xfce-desktop.c                |    7 +------
 src/xfdesktop-file-icon-manager.c |    8 ++++----
 src/xfdesktop-icon-view.c         |    7 +++----
 4 files changed, 8 insertions(+), 20 deletions(-)

diff --git a/src/windowlist.c b/src/windowlist.c
index 3692615..32343d6 100644
--- a/src/windowlist.c
+++ b/src/windowlist.c
@@ -137,8 +137,6 @@ menu_item_from_wnck_window(WnckWindow *wnck_window, gint icon_width,
 {
     GtkWidget *mi, *img = NULL;
     gchar *title;
-    WnckScreen *wnck_screen;
-    WnckWorkspace *wnck_workspace, *active_workspace;
     GString *label;
     GdkPixbuf *icon, *tmp;
     gint w, h;
@@ -151,10 +149,6 @@ menu_item_from_wnck_window(WnckWindow *wnck_window, gint icon_width,
     label = g_string_new(title);
     g_free(title);
 
-    wnck_screen = wnck_window_get_screen(wnck_window);
-    active_workspace = wnck_screen_get_active_workspace(wnck_screen);
-    wnck_workspace = wnck_window_get_workspace(wnck_window);
-
     if(wnck_window_is_active(wnck_window)) {
         g_string_prepend(label, "<i>");
         g_string_append(label, "</i>");
diff --git a/src/xfce-desktop.c b/src/xfce-desktop.c
index f507132..70d65f1 100644
--- a/src/xfce-desktop.c
+++ b/src/xfce-desktop.c
@@ -714,7 +714,6 @@ xfce_desktop_realize(GtkWidget *widget)
     GdkAtom atom;
     gint sw, sh;
     Window xid;
-    GdkDisplay *gdpy;
     GdkWindow *groot;
     
     TRACE("entering");
@@ -744,8 +743,7 @@ xfce_desktop_realize(GtkWidget *widget)
             gdk_atom_intern("_NET_WM_WINDOW_TYPE", FALSE),
             gdk_atom_intern("ATOM", FALSE), 32,
             GDK_PROP_MODE_REPLACE, (guchar *)&atom, 1);
-    
-    gdpy = gdk_screen_get_display(desktop->priv->gscreen);
+
     xid = GDK_WINDOW_XID(GTK_WIDGET(desktop)->window);
     groot = gdk_screen_get_root_window(desktop->priv->gscreen);
     
@@ -888,7 +886,6 @@ static gboolean
 xfce_desktop_expose(GtkWidget *w,
                     GdkEventExpose *evt)
 {
-    XfceDesktop *desktop;
     GList *children, *l;
     
     /*TRACE("entering");*/
@@ -896,8 +893,6 @@ xfce_desktop_expose(GtkWidget *w,
     if(evt->count != 0)
         return FALSE;
     
-    desktop = XFCE_DESKTOP(w);
-    
     gdk_window_clear_area(w->window, evt->area.x, evt->area.y,
                           evt->area.width, evt->area.height);
     
diff --git a/src/xfdesktop-file-icon-manager.c b/src/xfdesktop-file-icon-manager.c
index 126301b..2711646 100644
--- a/src/xfdesktop-file-icon-manager.c
+++ b/src/xfdesktop-file-icon-manager.c
@@ -1318,7 +1318,7 @@ xfdesktop_file_icon_manager_populate_context_menu(XfceDesktop *desktop,
     GFileInfo *info = NULL;
     GList *selected, *app_infos, *l;
     GtkWidget *mi, *img, *tmpl_menu;
-    gboolean multi_sel, have_templates = FALSE, got_custom_menu = FALSE;
+    gboolean multi_sel, got_custom_menu = FALSE;
     GFile *templates_dir = NULL, *home_dir;
     const gchar *templates_dir_path = NULL;
 #ifdef HAVE_THUNARX
@@ -1454,9 +1454,9 @@ xfdesktop_file_icon_manager_populate_context_menu(XfceDesktop *desktop,
 
                     if(templates_dir && !g_file_equal(home_dir, templates_dir))
                     {
-                        have_templates = xfdesktop_file_icon_menu_fill_template_menu(tmpl_menu,
-                                                                                     templates_dir,
-                                                                                     fmanager);
+                        xfdesktop_file_icon_menu_fill_template_menu(tmpl_menu,
+                                                                    templates_dir,
+                                                                    fmanager);
                     }
 
                     if(templates_dir)
diff --git a/src/xfdesktop-icon-view.c b/src/xfdesktop-icon-view.c
index 0633d88..0736006 100644
--- a/src/xfdesktop-icon-view.c
+++ b/src/xfdesktop-icon-view.c
@@ -881,7 +881,6 @@ static gboolean
 xfdesktop_icon_view_maybe_begin_drag(XfdesktopIconView *icon_view,
                                      GdkEventMotion *evt)
 {
-    GdkDragContext *context;
     GdkDragAction actions;
     
     /* sanity check */
@@ -898,9 +897,9 @@ xfdesktop_icon_view_maybe_begin_drag(XfdesktopIconView *icon_view,
     actions = GDK_ACTION_MOVE | (icon_view->priv->drag_source_set ?
                                  icon_view->priv->foreign_source_actions : 0);
     
-    context = gtk_drag_begin(GTK_WIDGET(icon_view),
-                             icon_view->priv->source_targets,
-                             actions, 1, (GdkEvent *)evt);
+    gtk_drag_begin(GTK_WIDGET(icon_view),
+                   icon_view->priv->source_targets,
+                   actions, 1, (GdkEvent *)evt);
     
     DBG("DRAG BEGIN!");
     



More information about the Xfce4-commits mailing list