diff --git a/src/gtk/filectrl.cpp b/src/gtk/filectrl.cpp index 5d60802904..4c0d97ba34 100644 --- a/src/gtk/filectrl.cpp +++ b/src/gtk/filectrl.cpp @@ -47,7 +47,7 @@ wxString wxGtkFileChooser::GetPath() const wxGtkString str( gtk_file_chooser_get_filename( m_widget ) ); wxString string; - if (str.c_str() != NULL) + if (str) string = wxString::FromUTF8(str); return string; } diff --git a/src/gtk/taskbar.cpp b/src/gtk/taskbar.cpp index 4d53edd850..120630a0ea 100644 --- a/src/gtk/taskbar.cpp +++ b/src/gtk/taskbar.cpp @@ -207,7 +207,7 @@ void wxTaskBarIcon::Private::SetIcon() #if wxUSE_TOOLTIPS const char *tip_text = NULL; if (!m_tipText.empty()) - tip_text = m_tipText.c_str(); + tip_text = m_tipText; #if GTK_CHECK_VERSION(2,10,0) if (m_statusIcon) diff --git a/src/gtk/utilsgtk.cpp b/src/gtk/utilsgtk.cpp index fefda2bd80..bfe8e9c076 100644 --- a/src/gtk/utilsgtk.cpp +++ b/src/gtk/utilsgtk.cpp @@ -122,7 +122,7 @@ wxConvertToGTK(const wxString& s, wxFontEncoding enc) wxWCharBuffer wbuf; if ( enc == wxFONTENCODING_SYSTEM || enc == wxFONTENCODING_DEFAULT ) { - wbuf = wxConvUI->cMB2WC(s.c_str()); + wbuf = wxConvUI->cMB2WC(s); } else // another encoding, use generic conversion class {