1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-26 15:23:48 +01:00

Conversion of TranslatableString to wxString is private

This commit is contained in:
Paul Licameli
2019-11-30 13:32:18 -05:00
parent 0b6618e491
commit 72df562c4a
30 changed files with 119 additions and 99 deletions

View File

@@ -687,14 +687,14 @@ registeredStatusWidthFunction{
-> ProjectStatus::StatusWidthResult
{
if ( field == stateStatusBarField ) {
const auto pauseString = wxT(" ") + GetCustomTranslation(sStatePause);
const auto pauseString = wxT(" ") + sStatePause.Translation();
std::vector<wxString> strings;
for ( auto pString :
{ &sStatePlay, &sStateStop, &sStateRecord } )
{
strings.push_back(
GetCustomTranslation(*pString) + pauseString + wxT(".") );
pString->Translation() + pauseString + wxT(".") );
}
// added constant needed because xMax isn't large enough for some reason, plus some space.
@@ -716,16 +716,16 @@ wxString ControlToolBar::StateForStatusBar()
if (!scrubState.empty())
state = scrubState.Translation();
else if (mPlay->IsDown())
state = wxGetTranslation(sStatePlay);
state = sStatePlay.Translation();
else if (projectAudioManager.Recording())
state = wxGetTranslation(sStateRecord);
state = sStateRecord.Translation();
else
state = wxGetTranslation(sStateStop);
state = sStateStop.Translation();
if (mPause->IsDown())
{
state.Append(wxT(" "));
state.Append(wxGetTranslation(sStatePause));
state.Append(sStatePause.Translation());
}
state.Append(wxT("."));

View File

@@ -278,7 +278,7 @@ void EditToolBar::ForAllButtons(int Action)
#if wxUSE_TOOLTIPS
if( Action & ETBActTooltips ){
TranslatedInternalString command{
entry.commandName, wxGetTranslation(entry.untranslatedLabel) };
entry.commandName, entry.untranslatedLabel.Translation() };
ToolBar::SetButtonToolTip( mProject,
*mButtons[entry.tool], &command, 1u );
}

View File

@@ -154,7 +154,7 @@ void ToolsToolBar::RegenerateTooltips()
for (const auto &entry : table) {
TranslatedInternalString command{
entry.commandName, wxGetTranslation(entry.untranslatedLabel) };
entry.commandName, entry.untranslatedLabel.Translation() };
ToolBar::SetButtonToolTip( mProject,
*mTool[entry.tool], &command, 1u );
}

View File

@@ -347,8 +347,8 @@ void TranscriptionToolBar::RegenerateTooltips()
for (const auto &entry : table) {
TranslatedInternalString commands[] = {
{ entry.commandName, wxGetTranslation(entry.untranslatedLabel) },
{ entry.commandName2, wxGetTranslation(entry.untranslatedLabel2) },
{ entry.commandName, entry.untranslatedLabel.Translation() },
{ entry.commandName2, entry.untranslatedLabel2.Translation() },
};
ToolBar::SetButtonToolTip( mProject,
*mButtons[entry.tool], commands, 2u );