Fix using const char* and wxString in ternary operator

Using a const char* and a wxString in the two branches of the ternary
operator resulted in compile-time errors since the result type of the
conditional expression was ambiguous, so add explicit conversions to fix
it.

Closes https://github.com/wxWidgets/wxWidgets/pull/2634

See #19355.
This commit is contained in:
PB
2022-01-02 17:56:44 +01:00
committed by Vadim Zeitlin
parent 55cb17df78
commit 0f8ab824a3
4 changed files with 6 additions and 5 deletions

View File

@@ -210,7 +210,7 @@ bool MyApp::OnInit()
langInfo = wxLocale::GetLanguageInfo(wxLANGUAGE_DEFAULT);
const wxString
langDesc = langInfo ? langInfo->Description
: "the default system locale";
: wxString("the default system locale");
if ( m_setLocale == Locale_Ask )
{