mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-07-28 05:12:27 +00:00
fix crash when opening preference dialog
This commit is contained in:
@@ -273,6 +273,7 @@ private:
|
||||
const wxLanguageInfo *m_language_info_system = nullptr;
|
||||
// Best translation language, provided by Windows or OSX, owned by wxWidgets.
|
||||
const wxLanguageInfo *m_language_info_best = nullptr;
|
||||
wxString m_active_language_code;
|
||||
|
||||
OpenGLManager m_opengl_mgr;
|
||||
std::unique_ptr<RemovableDriveManager> m_removable_drive_manager;
|
||||
@@ -563,7 +564,7 @@ public:
|
||||
void preset_deleted_from_cloud(std::string setting_id);
|
||||
|
||||
wxString filter_string(wxString str);
|
||||
wxString current_language_code() const { return m_wxLocale->GetCanonicalName(); }
|
||||
wxString current_language_code() const { return m_active_language_code.empty() && m_wxLocale ? m_wxLocale->GetCanonicalName() : m_active_language_code; }
|
||||
// Translate the language code to a code, for which Prusa Research maintains translations. Defaults to "en_US".
|
||||
wxString current_language_code_safe() const;
|
||||
bool is_localized() const { return m_wxLocale->GetLocale() != "English"; }
|
||||
|
||||
Reference in New Issue
Block a user