git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16572
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
wxString wxStaticText::GetLabel() const
{
- char *str = (char *) NULL;
- gtk_label_get( GTK_LABEL(m_widget), &str );
+ GtkLabel *label = GTK_LABEL(m_widget);
+
+#ifdef __WXGTK20__
+ wxString str = wxGTK_CONV_BACK( gtk_label_get_text( label ) );
+#else
+ wxString str = wxString( label->label );
+#endif
return wxString(str);
}
wxString wxStaticText::GetLabel() const
{
- char *str = (char *) NULL;
- gtk_label_get( GTK_LABEL(m_widget), &str );
+ GtkLabel *label = GTK_LABEL(m_widget);
+
+#ifdef __WXGTK20__
+ wxString str = wxGTK_CONV_BACK( gtk_label_get_text( label ) );
+#else
+ wxString str = wxString( label->label );
+#endif
return wxString(str);
}