[Ocfs2-tools-commits] manish commits r827 - trunk/ocfs2console/ocfs2interface

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Tue Apr 19 17:46:04 CDT 2005


Author: manish
Date: 2005-04-19 17:46:02 -0500 (Tue, 19 Apr 2005)
New Revision: 827

Modified:
   trunk/ocfs2console/ocfs2interface/about.py
   trunk/ocfs2console/ocfs2interface/fswidgets.py
Log:
Use pygtk version number checks, since hasattr on class types isn't reliable.


Modified: trunk/ocfs2console/ocfs2interface/about.py
===================================================================
--- trunk/ocfs2console/ocfs2interface/about.py	2005-04-19 18:39:36 UTC (rev 826)
+++ trunk/ocfs2console/ocfs2interface/about.py	2005-04-19 22:46:02 UTC (rev 827)
@@ -54,7 +54,7 @@
 
     from guiutil import set_props
 
-    if hasattr(gtk, 'AboutDialog'):
+    if gtk.pygtk_version >= (2,4,0):
         copyright = 'Copyright (C) 2002, 2005 Oracle.  All rights reserved.'
         license = '''
 This program is free software; you can redistribute it and/or

Modified: trunk/ocfs2console/ocfs2interface/fswidgets.py
===================================================================
--- trunk/ocfs2console/ocfs2interface/fswidgets.py	2005-04-19 18:39:36 UTC (rev 826)
+++ trunk/ocfs2console/ocfs2interface/fswidgets.py	2005-04-19 22:46:02 UTC (rev 827)
@@ -21,7 +21,7 @@
 
 from guiutil import set_props, format_bytes
 
-if hasattr(gtk, 'ComboBox'):
+if gtk.pygtk_version >= (2,4,0):
     class BaseCombo(gtk.ComboBox):
         def __init__(self):
             self.store = gtk.ListStore(str)



More information about the Ocfs2-tools-commits mailing list