BUG REPORT: e-conf capplet set background



Setting desktop backgrounds from gnomecc does not work in CVS,
990112

Here's a fix

Peter Wainwright
Home: prw@wainpr.demon.co.uk   Work: peter.wainwright@nrpb.org.uk
http://www.wainpr.demon.co.uk
Visit the Opera Exchange Homepage at http://www.treda.co.uk/opex/
diff -U4 -r control-center-old/capplets/e-conf/e-conf.c control-center/capplets/e-conf/e-conf.c
--- control-center-old/capplets/e-conf/e-conf.c	Sun Jan 10 17:46:33 1999
+++ control-center/capplets/e-conf/e-conf.c	Tue Jan 12 22:08:45 1999
@@ -163,8 +163,9 @@
 static void         e_revert(void);
 static void         e_ok(void);
 static void         e_cancel(void);
 static void         e_read(void);
+static void         e_set_bg_to_e(Background *bg);
 static void         e_render_bg_onto(GdkWindow * win, Background * bg);
 static void         e_init_capplet(GtkWidget * c, GtkSignalFunc try, GtkSignalFunc revert, GtkSignalFunc ok, GtkSignalFunc cancel);
 static void         e_cb_icon_option(GtkWidget * widget, gpointer data);
 static GtkWidget   *e_create_icon_option(gchar * title, gint * option, gint width, gint num_options, IconOption * options);
@@ -177,8 +178,9 @@
 static void         e_cb_desk_redraw(GtkWidget * widget, gpointer data);
 static void         e_cb_area_range(GtkWidget * widget, gpointer data);
 static GtkWidget   *e_areas_config(void);
 static void         e_cb_desk_range(GtkWidget * widget, gpointer data);
+static void         e_rebuild_desk_menu(void);
 static GtkWidget   *e_desktops_config(void);
 static GtkWidget   *__setup_pane_1(void);
 static GtkWidget   *__setup_pane_2(void);
 static GtkWidget   *__setup_pane_3(void);
@@ -353,22 +355,22 @@
 	      }
 	    if (changed)
 	      CommsSend(cmd);
 	  }
-	changed = 0;
-	g_snprintf(cmd, sizeof(cmd), "use_no_bg ");
-	for (i = 0; i < 32; i++)
+      }
+    changed = 0;
+    g_snprintf(cmd, sizeof(cmd), "use_no_bg ");
+    for (i = 0; i < 32; i++)
+      {
+	if ((deskbgchanged[i]) && (!deskbg[i]))
 	  {
-	    if ((deskbgchanged[i]) && (!deskbg[i]))
-	      {
-		g_snprintf(buf, sizeof(buf), " %i", i);
-		strcat(cmd, buf);
-		changed = 1;
-	      }
+	    g_snprintf(buf, sizeof(buf), " %i", i);
+	    strcat(cmd, buf);
+	    changed = 1;
 	  }
-	if (changed)
-	  CommsSend(cmd);
       }
+    if (changed)
+      CommsSend(cmd);
     for (i = 0; i < 32; i++)
       deskbgchanged[i] = 0;
   }
 }
@@ -1525,8 +1527,9 @@
 	       bg->top.yjust, bg->top.xperc, bg->top.yperc);
   else if ((!(bg->bg.file)) && (!(bg->top.file)))
     g_snprintf(buf, sizeof(buf),
 	       "set_bg %s %i %i %i %s %i %i %i %i %i %i %s %i %i %i %i %i",
+	       bg->name,
 	       bg->bg.solid.r, bg->bg.solid.g, bg->bg.solid.b,
 	       "(null)", bg->bg.tile, bg->bg.keep_aspect,
 	       bg->bg.xjust, bg->bg.yjust, bg->bg.xperc, bg->bg.yperc,
 	       "(null)", bg->top.keep_aspect, bg->top.xjust,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]