mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-21 22:12:58 +02:00
TranslatableString: Make compatible with wx3.0
wxWidgets 3.0 doesn't support context in wxGetTranslation yet, so don't use the context, similar to existing DoChooseFormat handling. This will lead to some untranslated strings or wrong context translations (if we have equal strings that one specifies the context, but the other doesn't), which isn't great, but better than not being able to compile the application at all against a stable wxWidgets library version. Signed-off-by: Mart Raudsepp <leio@gentoo.org>
This commit is contained in:
@@ -97,7 +97,12 @@ wxString TranslatableString::DoSubstitute( const Formatter &formatter,
|
||||
return formatter
|
||||
? formatter( format, debug ? Request::DebugFormat : Request::Format )
|
||||
: // come here for most translatable strings, which have no formatting
|
||||
( debug ? format : wxGetTranslation( format, wxString{}, context ) );
|
||||
( debug ? format : wxGetTranslation(
|
||||
format
|
||||
#if HAS_I18N_CONTEXTS
|
||||
, wxString{}, context
|
||||
#endif
|
||||
) );
|
||||
}
|
||||
|
||||
wxString TranslatableString::DoChooseFormat(
|
||||
|
Reference in New Issue
Block a user