PropertiesDialog: moved init code to parent's init call
authorWall <wall@gmail.com>
Sun, 1 Mar 2009 10:03:26 +0000 (10:03 +0000)
committerWall <wall@gmail.com>
Sun, 1 Mar 2009 10:03:26 +0000 (10:03 +0000)
src/findit.py

index 240ae75..dc64d92 100755 (executable)
@@ -100,11 +100,9 @@ class PropertiesDialog(gtk.Dialog):
 
     def __init__(self, app, path, size, bytesize):
         """Create&show file properties dialog."""
-        gtk.Dialog.__init__(self)
-        self.set_title( _('File properties') )
-        self.set_transient_for(app)
+        gtk.Dialog.__init__(self, _('File properties'), app,
+            buttons=(gtk.STOCK_OK, gtk.RESPONSE_OK))
         self.set_wmclass('PropertiesDialog', 'FindIT')
-        self.add_buttons(gtk.STOCK_OK, gtk.RESPONSE_OK)
         self.set_resizable(False)
 
         # Достаем свойства выбранного файла