GtkWidget *GetConnectWidget();
#if wxUSE_TOOLTIPS
- void ApplyToolTip( GtkTooltips *tips, const wxChar *tip );
+ void ApplyToolTip( GtkTooltips *tips, const gchar *tip );
#endif // wxUSE_TOOLTIPS
struct _GtkTreeView *m_treeview;
void GtkDisableEvents();
void GtkEnableEvents();
#if wxUSE_TOOLTIPS
- void ApplyToolTip( GtkTooltips *tips, const wxChar *tip );
+ void ApplyToolTip( GtkTooltips *tips, const gchar *tip );
#endif // wxUSE_TOOLTIPS
virtual void OnInternalIdle();
// this just sets the given tooltip for the specified widget
//
// tip must be already UTF-8 encoded
- static void Apply(GtkWidget *w, const wxCharBuffer& tip);
+ static void Apply(GtkWidget *w, const gchar *tip);
private:
wxString m_text;
PangoContext *GtkGetPangoDefaultContext();
#if wxUSE_TOOLTIPS
- virtual void ApplyToolTip( GtkTooltips *tips, const wxChar *tip );
+ // applies tooltip to the widget (tip must be UTF-8 encoded)
+ virtual void ApplyToolTip( GtkTooltips *tips, const gchar *tip );
#endif // wxUSE_TOOLTIPS
// Called when a window should delay showing itself
// ----------------------------------------------------------------------------
#if wxUSE_TOOLTIPS
-void wxListBox::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
+void wxListBox::ApplyToolTip( GtkTooltips *tips, const gchar *tip )
{
// RN: Is this needed anymore?
- gtk_tooltips_set_tip( tips, GTK_WIDGET( m_treeview ), wxGTK_CONV(tip), (gchar*) NULL );
+ gtk_tooltips_set_tip( tips, GTK_WIDGET( m_treeview ), tip, (gchar*) NULL );
}
#endif // wxUSE_TOOLTIPS
}
#if wxUSE_TOOLTIPS
-void wxRadioBox::ApplyToolTip(GtkTooltips * WXUNUSED(tips), const wxChar *tip)
+void wxRadioBox::ApplyToolTip(GtkTooltips * WXUNUSED(tips), const gchar *tip)
{
// set this tooltip for all radiobuttons which don't have their own tips
unsigned n = 0;
{
if ( !GetItemToolTip(n) )
{
- wxToolTip::Apply(GTK_WIDGET(node->GetData()->button),
- wxConvCurrent->cWX2MB(tip));
+ wxToolTip::Apply(GTK_WIDGET(node->GetData()->button), tip);
}
}
}
m_window = win;
if (m_text.empty())
- m_window->ApplyToolTip( gs_tooltips, (wxChar*) NULL );
+ m_window->ApplyToolTip( gs_tooltips, NULL );
else
- m_window->ApplyToolTip( gs_tooltips, m_text );
+ m_window->ApplyToolTip( gs_tooltips, wxGTK_CONV_SYS(m_text) );
}
/* static */
-void wxToolTip::Apply(GtkWidget *w, const wxCharBuffer& tip)
+void wxToolTip::Apply(GtkWidget *w, const gchar *tip)
{
if ( !gs_tooltips )
gs_tooltips = gtk_tooltips_new();
m_tooltip->Apply( (wxWindow *)this );
}
-void wxWindowGTK::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
+void wxWindowGTK::ApplyToolTip( GtkTooltips *tips, const gchar *tip )
{
- if (tip)
- {
- wxString tmp( tip );
- gtk_tooltips_set_tip( tips, GetConnectWidget(), wxGTK_CONV(tmp), (gchar*) NULL );
- }
- else
- {
- gtk_tooltips_set_tip( tips, GetConnectWidget(), NULL, NULL);
- }
+ gtk_tooltips_set_tip(tips, GetConnectWidget(), tip, NULL);
}
#endif // wxUSE_TOOLTIPS