]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/wx/lib/combotreebox.py
updates from Andrea, plus some fixes
[wxWidgets.git] / wxPython / wx / lib / combotreebox.py
index bdfd31034ccafe55e43fbe1b068c2fb4c579a3fc..6817ae404bc4d28e6a4400d9d75071de5c847d22 100644 (file)
@@ -37,8 +37,8 @@ workaround.
 Author: Frank Niessink <frank@niessink.com>
 Copyright 2006, Frank Niessink
 License: wxWidgets license
-Version: 0.8
-Date: August 21, 2006
+Version: 0.9
+Date: September 6, 2006
 """
 
 import wx
@@ -150,7 +150,7 @@ class IterableTreeCtrl(wx.TreeCtrl):
 # ---------------------------------------------------------------------------
 
 
-class BasePopupFrame(wx.MiniFrame):
+class BasePopupFrame(wx.Frame):
     """ 
     BasePopupFrame is the base class for platform specific
     versions of the PopupFrame. The PopupFrame is the frame that 
@@ -450,6 +450,9 @@ class BaseComboTreeBox(object):
         item = self.FindClientData(clientData)
         if item:
             self._tree.SelectItem(item)
+            string = self._tree.GetItemText(item)
+            if self._text.GetValue() != string:
+                self._text.SetValue(string)
             return True
         else:
             return False
@@ -718,6 +721,8 @@ class MSWComboTreeBox(NativeComboTreeBox):
         return events
 
     def OnSelectionChangedInTree(self, event):
+        if self.IsBeingDeleted():
+            return
         item = event.GetItem()
         if item:
             selectedValue = self._tree.GetItemText(item)