[glade--]A patch for togglebuttons

Björn Axelsson <[email protected]>
Newsgroups gmane.comp.gnome.glademm
Message-ID <[email protected]>
The glade (1.1.3) name for togglebuttons seems to be "toggle", not
"togglebutton". This little patch makes sure togglebuttons works fine both
stand-alone and in toolbars.

-- 
Björn Axelsson
diffs.txt (text/plain, 1.2 KB)
Index: src/writers/togglebutton.cc
===================================================================
RCS file: /cvs/gnome/glade--/src/writers/togglebutton.cc,v
retrieving revision 1.29
diff -u -r1.29 togglebutton.cc
--- src/writers/togglebutton.cc	15 Jun 2002 13:22:14 -0000	1.29
+++ src/writers/togglebutton.cc	9 Dec 2002 19:05:33 -0000
@@ -34,6 +34,7 @@
 {  if (!base_class_init)
    {  Writer["GtkToggleButton"]=this;
       Writer["togglebutton"]=this;
+      Writer["toggle"]=this;
    }
 }
 
Index: src/writers/toolbar.cc
===================================================================
RCS file: /cvs/gnome/glade--/src/writers/toolbar.cc,v
retrieving revision 1.69
diff -u -r1.69 toolbar.cc
--- src/writers/toolbar.cc	18 Jul 2002 16:06:31 -0000	1.69
+++ src/writers/toolbar.cc	9 Dec 2002 19:05:33 -0000
@@ -88,7 +88,7 @@
 
 Subwidget Gtk_Toolbar::IsSubwidget(const Widget &w,const Widget &ch) const
 {  if (ch.ChildName()=="Toolbar:button" || ch.Class()=="button"
-	|| ch.Class()=="togglebutton" || ch.Class()=="radiobutton") 
+	|| ch.Class()=="togglebutton" || ch.Class()=="radiobutton" || ch.Class()=="toggle") 
    {  if (ch.begin()!=ch.end()) return not_Subwidget; // constructs itself
       return is_Subwidget_all;
    }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.