mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-09 18:27:00 +00:00
Remove wxCHECK_VERSION(3,1,x) guards and legacy wxinit.h macros
Since we now target wxWidgets 3.3, all wxCHECK_VERSION(3,1,N) checks are always true. Remove the guards keeping only the true branches: - I18N.hpp: Remove version guard around _wxGetTranslation_ctx macro - ExtraRenderers.hpp, GUI_App.hpp: Simplify SUPPORTS_MARKUP to check only wxUSE_MARKUP (version check always true) - ConfigWizard.cpp: Remove manual wxArrayInt comparison fallback - SendSystemInfoDialog.cpp: Simplify display scaling guard to _WIN32 only - GUI_Utils.cpp: Remove IsDark() fallback using luma approximation - wxinit.h: Remove legacy wxEVT_BUTTON and wxEVT_HTML_LINK_CLICKED compat macros (these event names exist natively in wx 3.3)
This commit is contained in:
@@ -64,11 +64,7 @@ namespace I18N {
|
||||
inline std::string translate_utf8(const std::wstring &s, const std::wstring &plural, unsigned int n) { return translate(s, plural, n).ToUTF8().data(); }
|
||||
inline std::string translate_utf8(const wxString &s, const wxString &plural, unsigned int n) { return translate(s, plural, n).ToUTF8().data(); }
|
||||
|
||||
#if wxCHECK_VERSION(3, 1, 1)
|
||||
#define _wxGetTranslation_ctx(S, CTX) wxGetTranslation((S), wxEmptyString, (CTX))
|
||||
#else
|
||||
#define _wxGetTranslation_ctx(S, CTX) ((void)(CTX), wxGetTranslation((S)))
|
||||
#endif
|
||||
#define _wxGetTranslation_ctx(S, CTX) wxGetTranslation((S), wxEmptyString, (CTX))
|
||||
|
||||
inline wxString translate(const char *s, const char* ctx) { return _wxGetTranslation_ctx(wxString(s, wxConvUTF8), ctx); }
|
||||
inline wxString translate(const wchar_t *s, const char* ctx) { return _wxGetTranslation_ctx(s, ctx); }
|
||||
|
||||
Reference in New Issue
Block a user