1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-05 06:09:47 +02:00

Remove eIs(Getting|Saving)ViaShuttle enum values...

... Because:

1 They weren't used

2 The branches selected by them were wrongly passing user-visible prompt strings
to DoDataShuttle, which elsewhere takes a preference path (this is an error that
could have been detected and avoided if there weren't naked wxString arguments)

3 Without those branches, the affected Tie... functions become more parallel to
other ShuttleGui member functions, which might later be unified into fewer
functions
This commit is contained in:
Paul Licameli 2019-12-06 20:45:28 -05:00
parent 8d1dd10dee
commit 0247329077
2 changed files with 0 additions and 44 deletions

View File

@ -1239,12 +1239,6 @@ wxCheckBox * ShuttleGuiBase::DoTieCheckBox(const wxString &Prompt, WrappedType &
pCheckBox->SetValue( WrappedRef.ReadAsBool() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsSavingViaShuttle:
case eIsGettingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1281,12 +1275,6 @@ wxCheckBox * ShuttleGuiBase::DoTieCheckBoxOnRight(const wxString &Prompt, Wrappe
pCheckBox->SetValue( WrappedRef.ReadAsBool() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsSavingViaShuttle:
case eIsGettingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1324,12 +1312,6 @@ wxSpinCtrl * ShuttleGuiBase::DoTieSpinCtrl( const wxString &Prompt, WrappedType
pSpinCtrl->SetValue( WrappedRef.ReadAsInt() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsGettingViaShuttle:
case eIsSavingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1367,12 +1349,6 @@ wxTextCtrl * ShuttleGuiBase::DoTieTextBox( const wxString &Prompt, WrappedType &
pTextBox->SetValue( WrappedRef.ReadAsString() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsGettingViaShuttle:
case eIsSavingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1410,12 +1386,6 @@ wxTextCtrl * ShuttleGuiBase::DoTieNumericTextBox( const wxString &Prompt, Wrappe
pTextBox->SetValue( WrappedRef.ReadAsString() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsGettingViaShuttle:
case eIsSavingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1456,12 +1426,6 @@ wxSlider * ShuttleGuiBase::DoTieSlider( const wxString &Prompt, WrappedType & Wr
pSlider->SetValue( WrappedRef.ReadAsInt() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsSavingViaShuttle:
case eIsGettingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;
@ -1520,12 +1484,6 @@ wxChoice * ShuttleGuiBase::DoTieChoice(
pChoice->SetSelection( WrappedRef.ReadAsInt() );
}
break;
// IF Saving settings to external storage...
// or IF Getting settings from external storage.
case eIsSavingViaShuttle:
case eIsGettingViaShuttle:
DoDataShuttle( Prompt, WrappedRef );
break;
default:
wxASSERT( false );
break;

View File

@ -36,8 +36,6 @@ enum teShuttleMode
eIsCreating,
eIsGettingFromDialog,
eIsSettingToDialog,
eIsSavingViaShuttle,
eIsGettingViaShuttle,
eIsGettingMetadata,
// Next two are only ever seen in constructor.