]> Pileus Git - ~andy/gtk/commitdiff
When converting a stock item based on the label, remove the label
authorJohan Dahlin <johan@gnome.org>
Sun, 17 Feb 2008 22:28:55 +0000 (22:28 +0000)
committerJohan Dahlin <johan@src.gnome.org>
Sun, 17 Feb 2008 22:28:55 +0000 (22:28 +0000)
2008-02-17  Johan Dahlin  <johan@gnome.org>

    * gtk/gtk-builder-convert (GtkBuilderConverter._add_action_from_menuitem):
    When converting a stock item based on the label, remove the label property.
    (bug #515824, Yuri Pimenov)

svn path=/trunk/; revision=19607

ChangeLog
gtk/gtk-builder-convert

index dee6725240fc8d7876fe0c9f177ee5f6d5e094cb..3a04260321e1034f0a5c19def55cc0789cb4c81e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2008-02-17  Johan Dahlin  <johan@gnome.org>
+
+       * gtk/gtk-builder-convert (GtkBuilderConverter._add_action_from_menuitem): 
+       When converting a stock item based on the label, remove the label property.
+
 2008-02-17  Richard Hult  <richard@imendio.com>
 
        * gdk/quartz/GdkQuartzWindow.c: (showAndMakeKey): Update the
index 689c96593ed3d5e1eb54c28b5816f265d22b670c..088637f2e2e8547f339c254fd703f40075055201 100755 (executable)
@@ -421,15 +421,14 @@ class GtkBuilderConverter(object):
             raise NotImplementedError(object_class)
 
         if get_property(node, 'use_stock') == 'True':
-            child = get_property_node(node, 'label')
-            if child:
+            if 'label' in properties:
                 properties['stock_id'] = child
+                del properties['label']
 
         properties['name'] = object_id
         action = self._create_object(name,
                                      object_id,
                                      properties=properties)
-
         for signal in get_signal_nodes(node):
             signal_name = signal.getAttribute('name')
             if signal_name in ['activate', 'toggled']: