Remove unneccessary import of PyQt

This commit is contained in:
Kovid Goyal 2011-06-04 19:26:15 -06:00
parent c6733399f7
commit 5e4e45ec92

View File

@ -223,8 +223,7 @@ class OptionSet(object):
if val is val is True or val is False or val is None or \
isinstance(val, (int, float, long, basestring)):
return repr(val)
from PyQt4.QtCore import QString
if isinstance(val, QString):
if val.__class__.__name__ == 'QString' or hasattr(val, 'isNull'):
return repr(unicode(val))
pickle = cPickle.dumps(val, -1)
return 'cPickle.loads(%s)'%repr(pickle)