]> Pileus Git - ~andy/gtk/commitdiff
Improve dialog handling in gtk-builder-convert
authorMOROHOSHI Akihiko <moro@remus.dti.ne.jp>
Sat, 11 Apr 2009 05:34:22 +0000 (01:34 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Sat, 11 Apr 2009 05:34:22 +0000 (01:34 -0400)
Make gtk-builder-convert handle response ids in GtkFileChooserDialog
correctly. (#557629)

gtk/gtk-builder-convert

index 6406b108d0db208d620d121ee3d87f459647e00b..c6b36578b5f4d520d81960023d2750d032ddbeb9 100755 (executable)
@@ -42,10 +42,10 @@ import sys
 
 from xml.dom import minidom, Node
 
-WINDOWS = ['GtkWindow',
-           'GtkDialog',
+DIALOGS = ['GtkDialog',
            'GtkFileChooserDialog',
            'GtkMessageDialog']
+WINDOWS = ['GtkWindow'] + DIALOGS
 
 # The subprocess is only available in Python 2.4+
 try:
@@ -499,7 +499,7 @@ class GtkBuilderConverter(object):
                 return
 
             if (node.tagName == 'object' and
-                node.getAttribute('class') == 'GtkDialog'):
+                node.getAttribute('class') in DIALOGS):
                 dialog = node
                 break
             node = node.parentNode