]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/treectlg.cpp
Ensure there is valid context for DrawRectangle
[wxWidgets.git] / src / generic / treectlg.cpp
index a48ff7003e44a4e66b02649eb7d7cfbc523d87e0..d7193a9febe4380661f50f6e188580b8a453bb14 100644 (file)
@@ -3483,11 +3483,7 @@ wxTextCtrl *wxGenericTreeCtrl::EditLabel(const wxTreeItemId& item,
     // question might just have been added and no screen
     // update taken place.
     if ( m_dirty )
-#if defined( __WXMSW__ ) || defined(__WXMAC__)
-        Update();
-#else
         DoDirtyProcessing();
-#endif
 
     // TODO: use textCtrlClass here to create the control of correct class
     m_textCtrl = new wxTreeTextCtrl(this, itemEdit);
@@ -3594,6 +3590,13 @@ void wxGenericTreeCtrl::OnMouse( wxMouseEvent &event )
         wxTreeEvent
             hevent(wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP,  this, hoverItem);
 
+        // setting a tooltip upon leaving a view is getting the tooltip displayed
+        // on the neighbouring view ...
+#ifdef __WXOSX__
+        if ( event.Leaving() )
+            SetToolTip(NULL);
+        else
+#endif
         if ( GetEventHandler()->ProcessEvent(hevent) )
         {
             // If the user permitted the tooltip change, update it, otherwise