WingMan – Diff between revs 32 and 36
?pathlinks?
Rev 32 | Rev 36 | |||
---|---|---|---|---|
1 | using System.Collections.Generic; |
1 | using System.Collections.Generic; |
|
2 | using System.Xml.Serialization; |
2 | using ProtoBuf; |
|
3 | |
3 | |
|
4 | namespace WingMan.Bindings |
4 | namespace WingMan.Bindings |
|
5 | { |
5 | { |
|
- | 6 | [ProtoContract] |
||
6 | public class KeyBindingExchange |
7 | public class KeyBindingExchange |
|
7 | { |
8 | { |
|
8 | [XmlIgnore] public static readonly XmlSerializer XmlSerializer = |
- | ||
9 | new XmlSerializer(typeof(KeyBindingExchange)); |
9 | private readonly List<string> _keyBindings = new List<string>(); |
|
10 | |
10 | |
|
11 | public KeyBindingExchange() |
11 | public KeyBindingExchange() |
|
12 | { |
12 | { |
|
13 | } |
13 | } |
|
14 | |
14 | |
|
15 | public KeyBindingExchange(string nick, List<KeyBinding> keyBindings) |
15 | public KeyBindingExchange(string nick, List<string> keyBindings) : this() |
|
16 | { |
16 | { |
|
17 | Nick = nick; |
17 | Nick = nick; |
|
18 | KeyBindings = keyBindings; |
18 | KeyBindings = keyBindings; |
|
19 | } |
19 | } |
|
20 | |
20 | |
|
- | 21 | [ProtoMember(1)] public string Nick { get; set; } |
||
21 | public string Nick { get; set; } |
22 | |
|
- | 23 | [ProtoMember(2)] |
||
- | 24 | public List<string> KeyBindings |
||
- | 25 | { |
||
- | 26 | get => _keyBindings; |
||
22 | |
27 | set => _keyBindings.AddRange(value); |
|
23 | public List<KeyBinding> KeyBindings { get; set; } |
- | ||
24 | } |
28 | } |
|
- | 29 | } |
||
25 | } |
30 | } |
|
26 | |
31 | |
|
27 |
|
- | ||
28 | |
- | ||
29 | |
- | ||
30 | |
- |