]> git.saurik.com Git - wxWidgets.git/commitdiff
Really update tooltip when wxToolBar::SetShortHelp() is called.
authorVadim Zeitlin <vadim@wxwidgets.org>
Fri, 5 Nov 2010 21:43:13 +0000 (21:43 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Fri, 5 Nov 2010 21:43:13 +0000 (21:43 +0000)
Changing a toolbar tool tooltip didn't work in wxOSX/Cocoa because the new
value was never propagated to the native control.

See #12362.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66040 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/osx/cocoa/toolbar.mm

index 30858e2119911736f0d39e4083984f3cd4672420..433eadb1a58551b8613c9ec060ab3d8c70428090 100644 (file)
@@ -218,7 +218,17 @@ public:
     {
         wxToolBarToolBase::SetLabel(label);
         UpdateLabel();
-     }
+    }
+
+    virtual bool SetShortHelp(const wxString& help)
+    {
+        if ( !wxToolBarToolBase::SetShortHelp(help) )
+            return false;
+
+        UpdateLabel();
+
+        return true;
+    }
 #endif // wxOSX_USE_NATIVE_TOOLBAR
 
 private: