forked from BeyondDimension/SteamTools
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStartupOptions.cs
More file actions
37 lines (28 loc) · 1.2 KB
/
StartupOptions.cs
File metadata and controls
37 lines (28 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
namespace System.Application
{
public sealed class StartupOptions
{
public bool HasMainProcessRequired { get; set; }
public bool HasNotifyIcon { get; set; }
public bool HasGUI { get; set; }
public bool HasServerApiClient { get; set; }
public bool HasHttpClientFactory { get; set; }
public bool HasHttpProxy { get; set; }
public bool HasHosts { get; set; }
public bool HasSteam { get; set; }
public StartupOptions(DILevel level)
{
mValue = this;
HasMainProcessRequired = level.HasFlag(DILevel.MainProcessRequired);
HasNotifyIcon = HasMainProcessRequired;
HasGUI = level.HasFlag(DILevel.GUI);
HasServerApiClient = level.HasFlag(DILevel.ServerApiClient);
HasHttpClientFactory = level.HasFlag(DILevel.HttpClientFactory);
HasHttpProxy = level.HasFlag(DILevel.HttpProxy);
HasHosts = level.HasFlag(DILevel.Hosts);
HasSteam = level.HasFlag(DILevel.Steam);
}
static StartupOptions? mValue;
public static StartupOptions Value => mValue ?? throw new NullReferenceException("StartupOptions init fail.");
}
}