diff --git a/espanso-modulo/src/sys/form/form.cpp b/espanso-modulo/src/sys/form/form.cpp index 120c053..722cd6b 100644 --- a/espanso-modulo/src/sys/form/form.cpp +++ b/espanso-modulo/src/sys/form/form.cpp @@ -102,8 +102,8 @@ enum bool FormApp::OnInit() { - FormFrame *frame = new FormFrame(formMetadata->windowTitle, wxPoint(50, 50), wxSize(450, 340) ); - setFrameIcon(formMetadata->iconPath, frame); + FormFrame *frame = new FormFrame(wxString::FromUTF8(formMetadata->windowTitle), wxPoint(50, 50), wxSize(450, 340) ); + setFrameIcon(wxString::FromUTF8(formMetadata->iconPath), frame); frame->Show( true ); Activate(frame); diff --git a/espanso-modulo/src/sys/search/search.cpp b/espanso-modulo/src/sys/search/search.cpp index b514e95..0e16d13 100644 --- a/espanso-modulo/src/sys/search/search.cpp +++ b/espanso-modulo/src/sys/search/search.cpp @@ -166,7 +166,7 @@ private: bool SearchApp::OnInit() { - SearchFrame *frame = new SearchFrame(searchMetadata->windowTitle, wxPoint(50, 50), wxSize(450, 340)); + SearchFrame *frame = new SearchFrame(wxString::FromUTF8(searchMetadata->windowTitle), wxPoint(50, 50), wxSize(450, 340)); frame->Show(true); SetupWindowStyle(frame); Activate(frame); @@ -198,7 +198,7 @@ SearchFrame::SearchFrame(const wxString &title, const wxPoint &pos, const wxSize iconPanel = nullptr; if (searchMetadata->iconPath) { - wxString iconPath = wxString(searchMetadata->iconPath); + wxString iconPath = wxString::FromUTF8(searchMetadata->iconPath); if (wxFileExists(iconPath)) { wxBitmap bitmap = wxBitmap(iconPath, wxBITMAP_TYPE_PNG); diff --git a/espanso-modulo/src/sys/troubleshooting/troubleshooting.cpp b/espanso-modulo/src/sys/troubleshooting/troubleshooting.cpp index f34bd75..ace30b4 100644 --- a/espanso-modulo/src/sys/troubleshooting/troubleshooting.cpp +++ b/espanso-modulo/src/sys/troubleshooting/troubleshooting.cpp @@ -81,7 +81,7 @@ public: if (error_set_metadata->errors[i].level == ERROR_METADATA_LEVEL_WARNING) { level = wxT("WARNING"); } - wxString error_text = wxString::Format(wxT("[%s] %s\n"), level, error_set_metadata->errors[i].message); + wxString error_text = wxString::Format(wxT("[%s] %s\n"), level, wxString::FromUTF8(error_set_metadata->errors[i].message)); errors_text.Append(error_text); } @@ -171,7 +171,7 @@ bool TroubleshootingApp::OnInit() if (troubleshooting_metadata->window_icon_path) { - setFrameIcon(troubleshooting_metadata->window_icon_path, frame); + setFrameIcon(wxString::FromUTF8(troubleshooting_metadata->window_icon_path), frame); } frame->Show(true); diff --git a/espanso-modulo/src/sys/welcome/welcome.cpp b/espanso-modulo/src/sys/welcome/welcome.cpp index d6c0201..26d85bf 100644 --- a/espanso-modulo/src/sys/welcome/welcome.cpp +++ b/espanso-modulo/src/sys/welcome/welcome.cpp @@ -54,7 +54,7 @@ DerivedWelcomeFrame::DerivedWelcomeFrame(wxWindow *parent) if (welcome_metadata->tray_image_path) { - wxBitmap trayBitmap = wxBitmap(welcome_metadata->tray_image_path, wxBITMAP_TYPE_PNG); + wxBitmap trayBitmap = wxBitmap(wxString::FromUTF8(welcome_metadata->tray_image_path), wxBITMAP_TYPE_PNG); this->tray_bitmap->SetBitmap(trayBitmap); #ifdef __WXOSX__ this->tray_info_label->SetLabel("You should see the espanso icon on the status bar:"); @@ -91,7 +91,7 @@ bool WelcomeApp::OnInit() if (welcome_metadata->window_icon_path) { - setFrameIcon(welcome_metadata->window_icon_path, frame); + setFrameIcon(wxString::FromUTF8(welcome_metadata->window_icon_path), frame); } frame->Show(true); diff --git a/espanso-modulo/src/sys/wizard/wizard.cpp b/espanso-modulo/src/sys/wizard/wizard.cpp index 5b9de10..a4b94cf 100644 --- a/espanso-modulo/src/sys/wizard/wizard.cpp +++ b/espanso-modulo/src/sys/wizard/wizard.cpp @@ -130,7 +130,7 @@ DerivedFrame::DerivedFrame(wxWindow *parent) if (wizard_metadata->welcome_image_path) { - wxBitmap welcomeBitmap = wxBitmap(wizard_metadata->welcome_image_path, wxBITMAP_TYPE_PNG); + wxBitmap welcomeBitmap = wxBitmap(wxString::FromUTF8(wizard_metadata->welcome_image_path), wxBITMAP_TYPE_PNG); this->welcome_image->SetBitmap(welcomeBitmap); } @@ -140,12 +140,12 @@ DerivedFrame::DerivedFrame(wxWindow *parent) if (wizard_metadata->accessibility_image_1_path) { - wxBitmap accessiblityImage1 = wxBitmap(wizard_metadata->accessibility_image_1_path, wxBITMAP_TYPE_PNG); + wxBitmap accessiblityImage1 = wxBitmap(wxString::FromUTF8(wizard_metadata->accessibility_image_1_path), wxBITMAP_TYPE_PNG); this->accessibility_image1->SetBitmap(accessiblityImage1); } if (wizard_metadata->accessibility_image_2_path) { - wxBitmap accessiblityImage2 = wxBitmap(wizard_metadata->accessibility_image_2_path, wxBITMAP_TYPE_PNG); + wxBitmap accessiblityImage2 = wxBitmap(wxString::FromUTF8(wizard_metadata->accessibility_image_2_path), wxBITMAP_TYPE_PNG); this->accessibility_image2->SetBitmap(accessiblityImage2); } @@ -380,7 +380,7 @@ bool WizardApp::OnInit() if (wizard_metadata->window_icon_path) { - setFrameIcon(wizard_metadata->window_icon_path, frame); + setFrameIcon(wxString::FromUTF8(wizard_metadata->window_icon_path), frame); } frame->Show(true);