Horizon – Blame information for rev 7
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
1 | office | 1 | using System.ComponentModel; |
2 | using System.IO; |
||
3 | using System.Runtime.CompilerServices; |
||
4 | using System.Xml.Serialization; |
||
5 | using Configuration.Annotations; |
||
6 | |||
7 | namespace Configuration |
||
8 | { |
||
9 | [XmlRoot(Namespace = "urn:horizon-configuration-schema", ElementName = "Configuration")] |
||
10 | public class Configuration : INotifyPropertyChanged |
||
11 | { |
||
12 | private bool _atomicOperations = true; |
||
13 | |||
14 | private bool _enabled; |
||
15 | |||
16 | private string _lastFolder = "C:\\Users"; |
||
17 | |||
18 | private bool _launchOnBoot; |
||
19 | |||
20 | private bool _showBalloonTooltips = true; |
||
21 | |||
22 | private bool _networkSharing = false; |
||
23 | |||
24 | private NotifyFilters _notifyFilters = NotifyFilters.LastWrite | NotifyFilters.Attributes; |
||
25 | |||
7 | office | 26 | private NotifyEvent _notifyEvents = NotifyEvent.Create; |
27 | |||
28 | private bool _enableGotify = false; |
||
29 | |||
30 | private string _gotifyURL = string.Empty; |
||
31 | |||
1 | office | 32 | public NotifyFilters NotifyFilters |
33 | { |
||
34 | get => _notifyFilters; |
||
35 | set |
||
36 | { |
||
37 | if (value == _notifyFilters) |
||
38 | { |
||
39 | return; |
||
40 | } |
||
41 | |||
42 | _notifyFilters = value; |
||
43 | OnPropertyChanged(); |
||
44 | } |
||
45 | } |
||
46 | |||
7 | office | 47 | public NotifyEvent NotifyEvents |
48 | { |
||
49 | get => _notifyEvents; |
||
50 | set |
||
51 | { |
||
52 | if (value == _notifyEvents) |
||
53 | { |
||
54 | return; |
||
55 | } |
||
56 | |||
57 | _notifyEvents = value; |
||
58 | OnPropertyChanged(); |
||
59 | } |
||
60 | } |
||
61 | |||
62 | |||
1 | office | 63 | public bool NetworkSharing |
64 | { |
||
65 | get => _networkSharing; |
||
66 | set |
||
67 | { |
||
68 | if (value == _networkSharing) |
||
69 | { |
||
70 | return; |
||
71 | } |
||
72 | |||
73 | _networkSharing = value; |
||
74 | OnPropertyChanged(); |
||
75 | } |
||
76 | } |
||
77 | |||
78 | public bool ShowBalloonTooltips |
||
79 | { |
||
80 | get => _showBalloonTooltips; |
||
81 | set |
||
82 | { |
||
83 | if (value == _showBalloonTooltips) |
||
84 | { |
||
85 | return; |
||
86 | } |
||
87 | |||
88 | _showBalloonTooltips = value; |
||
89 | OnPropertyChanged(); |
||
90 | } |
||
91 | } |
||
92 | |||
93 | public bool Enabled |
||
94 | { |
||
95 | get => _enabled; |
||
96 | set |
||
97 | { |
||
98 | if (value == _enabled) |
||
99 | { |
||
100 | return; |
||
101 | } |
||
102 | |||
103 | _enabled = value; |
||
104 | OnPropertyChanged(); |
||
105 | } |
||
106 | } |
||
107 | |||
108 | public bool LaunchOnBoot |
||
109 | { |
||
110 | get => _launchOnBoot; |
||
111 | set |
||
112 | { |
||
113 | if (value == _launchOnBoot) |
||
114 | { |
||
115 | return; |
||
116 | } |
||
117 | |||
118 | _launchOnBoot = value; |
||
119 | OnPropertyChanged(); |
||
120 | } |
||
121 | } |
||
122 | |||
123 | public string LastFolder |
||
124 | { |
||
125 | get => _lastFolder; |
||
126 | set |
||
127 | { |
||
128 | if (value == _lastFolder) |
||
129 | { |
||
130 | return; |
||
131 | } |
||
132 | |||
133 | _lastFolder = value; |
||
134 | OnPropertyChanged(); |
||
135 | } |
||
136 | } |
||
137 | |||
138 | public bool AtomicOperations |
||
139 | { |
||
140 | get => _atomicOperations; |
||
141 | set |
||
142 | { |
||
143 | if (value == _atomicOperations) |
||
144 | { |
||
145 | return; |
||
146 | } |
||
147 | |||
148 | _atomicOperations = value; |
||
149 | OnPropertyChanged(); |
||
150 | } |
||
151 | } |
||
152 | |||
7 | office | 153 | public bool EnableGotify |
154 | { |
||
155 | get => _enableGotify; |
||
156 | set |
||
157 | { |
||
158 | if (value == _enableGotify) |
||
159 | { |
||
160 | return; |
||
161 | } |
||
162 | |||
163 | _enableGotify = value; |
||
164 | OnPropertyChanged(); |
||
165 | } |
||
166 | } |
||
167 | |||
168 | public string GotifyURL |
||
169 | { |
||
170 | get => _gotifyURL; |
||
171 | set |
||
172 | { |
||
173 | if (value == _gotifyURL) |
||
174 | { |
||
175 | return; |
||
176 | } |
||
177 | |||
178 | _gotifyURL = value; |
||
179 | OnPropertyChanged(); |
||
180 | } |
||
181 | } |
||
182 | |||
1 | office | 183 | public CaptureMode CaptureMode { get; set; } = CaptureMode.Window; |
184 | |||
185 | public event PropertyChangedEventHandler PropertyChanged; |
||
186 | |||
187 | [NotifyPropertyChangedInvocator] |
||
188 | protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null) |
||
189 | { |
||
190 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); |
||
191 | } |
||
192 | } |
||
193 | } |