mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 08:47:52 -06:00
GUI::show_error() is now generalized for std::string and const char*
Fixed return type of std::string translate_utf8() with context (incorrectly returned wxString, should return std::string). Fixed double translation of BackgroundSlicingProcess::validate() in Plater.
This commit is contained in:
parent
0486e412f4
commit
a7ffd2a6fe
8 changed files with 19 additions and 12 deletions
|
@ -229,10 +229,15 @@ void show_error(wxWindow* parent, const wxString& message)
|
|||
msg.ShowModal();
|
||||
}
|
||||
|
||||
void show_error(wxWindow* parent, const char* message)
|
||||
{
|
||||
show_error(parent, wxString::FromUTF8(message));
|
||||
}
|
||||
|
||||
void show_error_id(int id, const std::string& message)
|
||||
{
|
||||
auto *parent = id != 0 ? wxWindow::FindWindowById(id) : nullptr;
|
||||
show_error(parent, from_u8(message));
|
||||
show_error(parent, message);
|
||||
}
|
||||
|
||||
void show_info(wxWindow* parent, const wxString& message, const wxString& title)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue