If an empty string is passed, remove the tooltip instead of setting it

to "".


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42091 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2006-10-18 03:54:48 +00:00
parent 122c2bae32
commit 17b5a3eccb

View File

@@ -3762,10 +3762,17 @@ void wxWindowGTK::DoSetToolTip( wxToolTip *tip )
} }
void wxWindowGTK::ApplyToolTip( GtkTooltips *tips, const wxChar *tip ) void wxWindowGTK::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
{
if (tip)
{ {
wxString tmp( tip ); wxString tmp( tip );
gtk_tooltips_set_tip( tips, GetConnectWidget(), wxGTK_CONV(tmp), (gchar*) NULL ); gtk_tooltips_set_tip( tips, GetConnectWidget(), wxGTK_CONV(tmp), (gchar*) NULL );
} }
else
{
gtk_tooltips_set_tip( tips, GetConnectWidget(), NULL, NULL);
}
}
#endif // wxUSE_TOOLTIPS #endif // wxUSE_TOOLTIPS
bool wxWindowGTK::SetBackgroundColour( const wxColour &colour ) bool wxWindowGTK::SetBackgroundColour( const wxColour &colour )