[Xfce4-commits] <ristretto:master> Fix compile-issues with --enable-debug=full

Stephan Arts noreply at xfce.org
Wed Nov 23 07:12:01 CET 2011


Updating branch refs/heads/master
         to 0a4ceb399322dc7872e93a712cdb471a02384119 (commit)
       from 816b0753513bfd61d26e9936d4c99829c3a0ffb9 (commit)

commit 0a4ceb399322dc7872e93a712cdb471a02384119
Author: Stephan Arts <stephan at xfce.org>
Date:   Wed Nov 23 07:10:04 2011 +0100

    Fix compile-issues with --enable-debug=full

 src/monitor_chooser.c        |   34 +++++++++++-----------------------
 src/properties_dialog.c      |    2 +-
 src/xfce_wallpaper_manager.c |    9 ---------
 3 files changed, 12 insertions(+), 33 deletions(-)

diff --git a/src/monitor_chooser.c b/src/monitor_chooser.c
index 05832a9..8a784c8 100644
--- a/src/monitor_chooser.c
+++ b/src/monitor_chooser.c
@@ -74,10 +74,6 @@ static void
 cb_rstto_button_press_event (GtkWidget *, GdkEventButton *event);
 
 static void
-calculate_monitor_positions (
-        RsttoMonitorChooser *chooser );
-
-static void
 paint_monitor ( cairo_t *cr,
                 gdouble x,
                 gdouble y,
@@ -244,7 +240,6 @@ rstto_monitor_chooser_paint(GtkWidget *widget)
     RsttoMonitorChooser *chooser = RSTTO_MONITOR_CHOOSER (widget);
     cairo_t *ctx = gdk_cairo_create (widget->window);
     Monitor *monitor;
-    gint index = 0;
 
     gdouble width, height;
     gchar *label = NULL;
@@ -264,12 +259,12 @@ rstto_monitor_chooser_paint(GtkWidget *widget)
 
     if (chooser->priv->n_monitors > 1)
     {
-        for (; chooser->priv->monitors[index]; ++index)
+        for (; chooser->priv->monitors[id]; ++id)
         {
-            monitor = chooser->priv->monitors[index];
+            monitor = chooser->priv->monitors[id];
 
             /* Render the selected monitor a little bigger */
-            if (index == chooser->priv->selected)
+            if (id == chooser->priv->selected)
             {
                 if (monitor->width > monitor->height)
                 {
@@ -281,7 +276,7 @@ rstto_monitor_chooser_paint(GtkWidget *widget)
                     height = widget->allocation.width*0.4;
                     width = height;
                 }
-                label = g_strdup_printf("%d", index+1);
+                label = g_strdup_printf("%d", id+1);
                 cairo_save (ctx);
                 paint_monitor (ctx,
                         ((gdouble)widget->allocation.width/4) - (width/2.0),
@@ -310,7 +305,7 @@ rstto_monitor_chooser_paint(GtkWidget *widget)
                 }
             
 
-                label = g_strdup_printf("%d", index+1);
+                label = g_strdup_printf("%d", id+1);
                 cairo_save (ctx);
                 paint_monitor (ctx,
                         ((gdouble)widget->allocation.width/2)+
@@ -620,7 +615,7 @@ rstto_monitor_chooser_add (
         gint height)
 {
     Monitor **monitors = g_new0 (Monitor *, chooser->priv->n_monitors+1);
-    gint index = 0;
+    gint id = 0;
 
     Monitor *monitor = g_new0 (Monitor, 1);
     monitor->width = width;
@@ -634,19 +629,19 @@ rstto_monitor_chooser_add (
     {
         chooser->priv->selected = 0;
 
-        for (index = 0; chooser->priv->monitors[index]; ++index)
+        for (id = 0; chooser->priv->monitors[id]; ++id)
         {
-            monitors[index] = chooser->priv->monitors[index];
+            monitors[id] = chooser->priv->monitors[id];
         }
         g_free (chooser->priv->monitors);
     }
     
-    monitors[index] = monitor;
+    monitors[id] = monitor;
 
     chooser->priv->monitors = monitors;
     chooser->priv->n_monitors++;
 
-    return index;
+    return id;
 }
 
 gint
@@ -659,7 +654,7 @@ rstto_monitor_chooser_set_pixbuf (
     Monitor *monitor;
     gint retval = -1;
 
-    g_return_if_fail (monitor_id < chooser->priv->n_monitors);
+    g_return_val_if_fail (monitor_id < chooser->priv->n_monitors, retval);
 
     monitor = chooser->priv->monitors[monitor_id];
 
@@ -748,13 +743,6 @@ rstto_monitor_chooser_get_selected (
     return chooser->priv->selected;
 }
 
-static void
-calculate_monitor_positions (
-        RsttoMonitorChooser *chooser )
-{
-
-}
-
 void
 rstto_monitor_chooser_get_dimensions (
         RsttoMonitorChooser *chooser,
diff --git a/src/properties_dialog.c b/src/properties_dialog.c
index dec05f6..3b79cc5 100644
--- a/src/properties_dialog.c
+++ b/src/properties_dialog.c
@@ -476,7 +476,7 @@ properties_dialog_set_file (
         g_snprintf (
                 buf,
                 20,
-                "%llu bytes",
+                "%"G_GUINT64_FORMAT" bytes",
                 size);
         gtk_label_set_text (
                 GTK_LABEL (dialog->priv->size_content_label),
diff --git a/src/xfce_wallpaper_manager.c b/src/xfce_wallpaper_manager.c
index 1e42d0c..d7887cd 100644
--- a/src/xfce_wallpaper_manager.c
+++ b/src/xfce_wallpaper_manager.c
@@ -134,13 +134,9 @@ rstto_xfce_wallpaper_manager_configure_dialog_run (
         RsttoWallpaperManager *self,
         RsttoFile *file)
 {
-    gdouble saturation;
-    gdouble brightness;
     RsttoXfceWallpaperManager *manager = RSTTO_XFCE_WALLPAPER_MANAGER (self);
     gint response = 0;
     manager->priv->file = file;
-    saturation = gtk_adjustment_get_value (GTK_ADJUSTMENT(manager->priv->saturation_adjustment));
-    brightness = gtk_adjustment_get_value (GTK_ADJUSTMENT(manager->priv->brightness_adjustment));
 
     if (manager->priv->pixbuf)
     {
@@ -639,11 +635,6 @@ cb_monitor_chooser_changed (
         RsttoMonitorChooser *monitor_chooser,
         RsttoXfceWallpaperManager *manager)
 {
-    enum MonitorStyle style = MONITOR_STYLE_AUTOMATIC;
-
-    style = gtk_combo_box_get_active (
-            GTK_COMBO_BOX(manager->priv->style_combo));
-
     rstto_monitor_chooser_set_pixbuf (
             monitor_chooser,
             manager->priv->monitor,


More information about the Xfce4-commits mailing list