Merge pull request #3012 from matham/type

Python 3 doesn't have ClassType anymore.
This commit is contained in:
matham 2015-02-08 11:48:10 -05:00
commit 0167171e3e
1 changed files with 4 additions and 2 deletions

View File

@ -798,8 +798,10 @@ lang_keyvalue = re.compile('([a-zA-Z_][a-zA-Z0-9_.]*\.[a-zA-Z0-9_.]+)')
lang_tr = re.compile('(_\()')
# class types to check with isinstance
_cls_type = (type, types.ClassType)
if PY2:
_cls_type = (type, types.ClassType)
else:
_cls_type = (type, )
# all the widget handlers, used to correctly unbind all the callbacks then the
# widget is deleted