mirror of
https://github.com/greenshot/greenshot
synced 2025-07-15 09:33:46 -07:00
Fixed bug #3526374, overlooked an issue with loading the ini file.
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@1845 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
b7cd728697
commit
a6935012c3
1 changed files with 7 additions and 4 deletions
|
@ -314,10 +314,7 @@ namespace Greenshot.IniFile {
|
|||
Value = defaultValueFromConfig;
|
||||
return;
|
||||
}
|
||||
} if (defaultValueFromConfig != null) {
|
||||
Value = defaultValueFromConfig;
|
||||
return;
|
||||
} else {
|
||||
} else if (propertyValue != null) {
|
||||
if (valueType.IsGenericType && valueType.GetGenericTypeDefinition().Equals(typeof(Nullable<>))) {
|
||||
// We are dealing with a generic type that is nullable
|
||||
valueType = Nullable.GetUnderlyingType(valueType);
|
||||
|
@ -340,6 +337,12 @@ namespace Greenshot.IniFile {
|
|||
Value = newValue;
|
||||
return;
|
||||
}
|
||||
|
||||
// If nothing is set, we can use the default value from the config (if we habe one)
|
||||
if (defaultValueFromConfig != null) {
|
||||
Value = defaultValueFromConfig;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue