Fix for missing LastSaveWithVersion, this is needed to recognize with what version the configuration was stored. [skip ci]

This commit is contained in:
Robin 2015-04-10 13:57:20 +02:00
parent 63412d3b9e
commit 71ff4c6286

View file

@ -407,6 +407,17 @@ namespace GreenshotPlugin.Core {
return base.PreCheckValue(propertyName, propertyValue); return base.PreCheckValue(propertyName, propertyValue);
} }
/// <summary>
/// This method will be called before writing the configuration
/// </summary>
public override void BeforeSave() {
try {
// Store version, this can be used later to fix settings after an update
LastSaveWithVersion = Assembly.GetEntryAssembly().GetName().Version.ToString();
} catch {
}
}
/// <summary> /// <summary>
/// This method will be called after reading the configuration, so eventually some corrections can be made /// This method will be called after reading the configuration, so eventually some corrections can be made
/// </summary> /// </summary>