CUETools: small glitch - when renaming user defined encoder,

cuetools wav encoder dissapeared (changed extension)
This commit is contained in:
Grigory Chudov
2013-04-18 22:48:48 -04:00
parent 7a6a42d9d2
commit 1674a977d6
4 changed files with 8 additions and 11 deletions

View File

@@ -132,11 +132,17 @@ namespace CUETools.Processor
get { return lossless; }
set { lossless = value; if (PropertyChanged != null) PropertyChanged(this, new PropertyChangedEventArgs("Lossless")); }
}
public string Extension
{
get { return extension; }
set { if (extension == value) return; extension = value; if (PropertyChanged != null) PropertyChanged(this, new PropertyChangedEventArgs("Extension")); }
set
{
if (extension == value) return;
if (type != null && type != typeof(UserDefinedWriter)) throw new InvalidOperationException();
extension = value;
if (PropertyChanged != null) PropertyChanged(this, new PropertyChangedEventArgs("Extension"));
}
}
public string DotExtension

View File

@@ -2718,7 +2718,6 @@ namespace JDP
settingsForm.Config = _profile._config;
settingsForm.ShowDialog(this);
}
SaveSettings();
SelectedOutputAudioType = SelectedOutputAudioType;
}
}

View File

@@ -1174,7 +1174,6 @@ namespace JDP
this.comboBoxEncoderExtension.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBoxEncoderExtension.FormattingEnabled = true;
this.comboBoxEncoderExtension.Name = "comboBoxEncoderExtension";
this.comboBoxEncoderExtension.SelectedIndexChanged += new System.EventHandler(this.comboBoxEncoderExtension_SelectedIndexChanged);
//
// listBoxEncoders
//

View File

@@ -459,13 +459,6 @@ namespace JDP
}
}
private void comboBoxEncoderExtension_SelectedIndexChanged(object sender, EventArgs e)
{
// Setting DataSourceUpdateMode to OnPropertyChanged doesn't seem
// to do the trick, so updating manually
comboBoxEncoderExtension.DataBindings["SelectedItem"].WriteValue();
}
private void encodersBindingSource_CurrentItemChanged(object sender, EventArgs e)
{
CUEToolsUDC encoder = encodersBindingSource.Current as CUEToolsUDC;