fix earlier patch

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@74111 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2013-06-06 01:58:45 +00:00
parent baca577355
commit 32c1e977c6

View File

@@ -111,6 +111,7 @@ class FillingTree(wx.TreeCtrl):
def objGetChildren(self, obj):
"""Return dictionary with attributes or contents of object."""
busy = wx.BusyCursor()
otype = type(obj)
if (isinstance(obj, dict)
or 'BTrees' in six.text_type(otype)
@@ -207,9 +208,9 @@ class FillingTree(wx.TreeCtrl):
obj = self.GetItemData(parent)
# Apply dictionary syntax to dictionary items, except the root
# and first level children of a namepace.
if (isinstance(obj, dict)
if ((isinstance(obj, dict)
or 'BTrees' in six.text_type(type(obj))
and hasattr(obj, 'keys')
and hasattr(obj, 'keys'))
and ((item != self.root and parent != self.root)
or (parent == self.root and not self.rootIsNamespace))):
name = '[' + name + ']'