mirror of
https://github.com/Kopano-dev/kopano-ol-extension.git
synced 2023-10-10 13:37:40 +02:00
Made "Background" the default threading option
This commit is contained in:
parent
ab37b666df
commit
5806ee9b80
@ -68,19 +68,25 @@ namespace Acacia
|
||||
}
|
||||
|
||||
public class EnumOption<EnumType> : Option<EnumType>
|
||||
where EnumType : struct
|
||||
{
|
||||
private readonly EnumType? _defaultValue;
|
||||
|
||||
private EnumType DefaultValue
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_defaultValue.HasValue)
|
||||
return (EnumType)_defaultValue;
|
||||
return (EnumType)typeof(EnumType).GetEnumValues().GetValue(0);
|
||||
}
|
||||
}
|
||||
|
||||
public EnumOption(string token)
|
||||
public EnumOption(string token, EnumType? defaultValue = null)
|
||||
:
|
||||
base(token)
|
||||
{
|
||||
this._defaultValue = defaultValue;
|
||||
}
|
||||
|
||||
public override string GetToken(EnumType value)
|
||||
|
@ -51,7 +51,7 @@ namespace Acacia
|
||||
get { return GetOption(null, THREADING); }
|
||||
set { SetOption(null, THREADING, value); }
|
||||
}
|
||||
private static readonly EnumOption<Threading> THREADING = new EnumOption<Threading>("Threading");
|
||||
private static readonly EnumOption<Threading> THREADING = new EnumOption<Threading>("Threading", Threading.Background);
|
||||
|
||||
[AcaciaOption("Enables or disables ZPush account checking. To enable advanced features, it must be known " +
|
||||
"which accounts use ZPush servers. This option checks responses from ActiveSync servers to " +
|
||||
|
Loading…
x
Reference in New Issue
Block a user