ChangeSet 1.2231.1.131, 2005/03/28 19:52:59-08:00, [EMAIL PROTECTED]

        [PATCH] revert recent gconfig changes
        
        Revert a 2.6.11 patch "make gconfig work with gtk-2.4".  It causes the 
cute
        little pixmap buttons to not appear any more.
        
        Hopefully this will motivate someone to have another attempt at fixing 
gconf
        for gtk-2.4.
        
        Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
        Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>



 gconf.c     |   69 ++++++++++++++++++++++++++++--------------------------------
 gconf.glade |   40 ++++++++++++++++------------------
 2 files changed, 52 insertions(+), 57 deletions(-)


diff -Nru a/scripts/kconfig/gconf.c b/scripts/kconfig/gconf.c
--- a/scripts/kconfig/gconf.c   2005-03-28 21:35:25 -08:00
+++ b/scripts/kconfig/gconf.c   2005-03-28 21:35:25 -08:00
@@ -11,6 +11,7 @@
 #endif
 
 #include "lkc.h"
+#include "images.c"
 
 #include <glade/glade.h>
 #include <gtk/gtk.h>
@@ -186,6 +187,8 @@
        GtkWidget *widget;
        GtkTextBuffer *txtbuf;
        char title[256];
+       GdkPixmap *pixmap;
+       GdkBitmap *mask;
        GtkStyle *style;
 
        xml = glade_xml_new(glade_file, "window1", NULL);
@@ -218,6 +221,36 @@
        style = gtk_widget_get_style(main_wnd);
        widget = glade_xml_get_widget(xml, "toolbar1");
 
+       pixmap = gdk_pixmap_create_from_xpm_d(main_wnd->window, &mask,
+                                             &style->bg[GTK_STATE_NORMAL],
+                                             (gchar **) xpm_single_view);
+       gtk_image_set_from_pixmap(GTK_IMAGE
+                                 (((GtkToolbarChild
+                                    *) (g_list_nth(GTK_TOOLBAR(widget)->
+                                                   children,
+                                                   5)->data))->icon),
+                                 pixmap, mask);
+       pixmap =
+           gdk_pixmap_create_from_xpm_d(main_wnd->window, &mask,
+                                        &style->bg[GTK_STATE_NORMAL],
+                                        (gchar **) xpm_split_view);
+       gtk_image_set_from_pixmap(GTK_IMAGE
+                                 (((GtkToolbarChild
+                                    *) (g_list_nth(GTK_TOOLBAR(widget)->
+                                                   children,
+                                                   6)->data))->icon),
+                                 pixmap, mask);
+       pixmap =
+           gdk_pixmap_create_from_xpm_d(main_wnd->window, &mask,
+                                        &style->bg[GTK_STATE_NORMAL],
+                                        (gchar **) xpm_tree_view);
+       gtk_image_set_from_pixmap(GTK_IMAGE
+                                 (((GtkToolbarChild
+                                    *) (g_list_nth(GTK_TOOLBAR(widget)->
+                                                   children,
+                                                   7)->data))->icon),
+                                 pixmap, mask);
+
        switch (view_mode) {
        case SINGLE_VIEW:
                widget = glade_xml_get_widget(xml, "button4");
@@ -1138,42 +1171,6 @@
        return FALSE;
 }
 
-
-/* Conf management */
-
-static const char *xpm_menu[] = {
-"12 12 2 1",
-"  c white",
-". c black",
-"            ",
-"            ",
-"  .         ",
-"  ..        ",
-"  ...       ",
-"  ....      ",
-"  .....     ",
-"  ....      ",
-"  ...       ",
-"  ..        ",
-"  .         ",
-"            "};
-
-static const char *xpm_void[] = {
-"12 12 2 1",
-"  c white",
-". c black",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            ",
-"            "};
 
 /* Fill a row of strings */
 static gchar **fill_row(struct menu *menu)
diff -Nru a/scripts/kconfig/gconf.glade b/scripts/kconfig/gconf.glade
--- a/scripts/kconfig/gconf.glade       2005-03-28 21:35:25 -08:00
+++ b/scripts/kconfig/gconf.glade       2005-03-28 21:35:25 -08:00
@@ -310,13 +310,13 @@
              <property name="tooltips">True</property>
 
              <child>
-               <widget class="GtkToolButton" id="button1">
+               <widget class="button" id="button1">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Goes up of one 
level (single view)</property>
                  <property name="label" translatable="yes">Back</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-undo</property>
-                 <signal name="clicked" handler="on_back_pressed"/>
+                 <property name="stock_pixmap">gtk-undo</property>
+                 <signal name="pressed" handler="on_back_pressed"/>
                </widget>
              </child>
 
@@ -327,24 +327,24 @@
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button2">
+               <widget class="button" id="button2">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Load a config 
file</property>
                  <property name="label" translatable="yes">Load</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-open</property>
-                 <signal name="clicked" handler="on_load_pressed"/>
+                 <property name="stock_pixmap">gtk-open</property>
+                 <signal name="pressed" handler="on_load_pressed"/>
                </widget>
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button3">
+               <widget class="button" id="button3">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Save a config 
file</property>
                  <property name="label" translatable="yes">Save</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-save</property>
-                 <signal name="clicked" handler="on_save_pressed"/>
+                 <property name="stock_pixmap">gtk-save</property>
+                 <signal name="pressed" handler="on_save_pressed"/>
                </widget>
              </child>
 
@@ -355,34 +355,34 @@
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button4">
+               <widget class="button" id="button4">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Single 
view</property>
                  <property name="label" translatable="yes">Single</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-indent</property>
+                 <property name="stock_pixmap">gtk-missing-image</property>
                  <signal name="clicked" handler="on_single_clicked" 
last_modification_time="Sun, 12 Jan 2003 14:28:39 GMT"/>
                </widget>
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button5">
+               <widget class="button" id="button5">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Split 
view</property>
                  <property name="label" translatable="yes">Split</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-copy</property>
+                 <property name="stock_pixmap">gtk-missing-image</property>
                  <signal name="clicked" handler="on_split_clicked" 
last_modification_time="Sun, 12 Jan 2003 14:28:45 GMT"/>
                </widget>
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button6">
+               <widget class="button" id="button6">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Full 
view</property>
                  <property name="label" translatable="yes">Full</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-justify-left</property>
+                 <property name="stock_pixmap">gtk-missing-image</property>
                  <signal name="clicked" handler="on_full_clicked" 
last_modification_time="Sun, 12 Jan 2003 14:28:50 GMT"/>
                </widget>
              </child>
@@ -394,24 +394,22 @@
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button7">
+               <widget class="button" id="button7">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Collapse the 
whole tree in the right frame</property>
                  <property name="label" translatable="yes">Collapse</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-zoom-out</property>
-                 <signal name="clicked" handler="on_collapse_pressed"/>
+                 <signal name="pressed" handler="on_collapse_pressed"/>
                </widget>
              </child>
 
              <child>
-               <widget class="GtkToolButton" id="button8">
+               <widget class="button" id="button8">
                  <property name="visible">True</property>
                  <property name="tooltip" translatable="yes">Expand the whole 
tree in the right frame</property>
                  <property name="label" translatable="yes">Expand</property>
                  <property name="use_underline">True</property>
-                 <property name="stock-id">gtk-zoom-in</property>
-                 <signal name="clicked" handler="on_expand_pressed"/>
+                 <signal name="pressed" handler="on_expand_pressed"/>
                </widget>
              </child>
            </widget>
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to