diff options
Diffstat (limited to 'src/WixToolset.Data/Symbols/BBControlSymbol.cs')
-rw-r--r-- | src/WixToolset.Data/Symbols/BBControlSymbol.cs | 180 |
1 files changed, 180 insertions, 0 deletions
diff --git a/src/WixToolset.Data/Symbols/BBControlSymbol.cs b/src/WixToolset.Data/Symbols/BBControlSymbol.cs new file mode 100644 index 00000000..277d1d85 --- /dev/null +++ b/src/WixToolset.Data/Symbols/BBControlSymbol.cs | |||
@@ -0,0 +1,180 @@ | |||
1 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. | ||
2 | |||
3 | namespace WixToolset.Data | ||
4 | { | ||
5 | using WixToolset.Data.Symbols; | ||
6 | |||
7 | public static partial class SymbolDefinitions | ||
8 | { | ||
9 | public static readonly IntermediateSymbolDefinition BBControl = new IntermediateSymbolDefinition( | ||
10 | SymbolDefinitionType.BBControl, | ||
11 | new[] | ||
12 | { | ||
13 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.BillboardRef), IntermediateFieldType.String), | ||
14 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.BBControl), IntermediateFieldType.String), | ||
15 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Type), IntermediateFieldType.String), | ||
16 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.X), IntermediateFieldType.Number), | ||
17 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Y), IntermediateFieldType.Number), | ||
18 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Width), IntermediateFieldType.Number), | ||
19 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Height), IntermediateFieldType.Number), | ||
20 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Attributes), IntermediateFieldType.Number), | ||
21 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Enabled), IntermediateFieldType.Bool), | ||
22 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Indirect), IntermediateFieldType.Bool), | ||
23 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Integer), IntermediateFieldType.Bool), | ||
24 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.LeftScroll), IntermediateFieldType.Bool), | ||
25 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.RightAligned), IntermediateFieldType.Bool), | ||
26 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.RightToLeft), IntermediateFieldType.Bool), | ||
27 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Sunken), IntermediateFieldType.Bool), | ||
28 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Visible), IntermediateFieldType.Bool), | ||
29 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.Text), IntermediateFieldType.String), | ||
30 | new IntermediateFieldDefinition(nameof(BBControlSymbolFields.SourceFile), IntermediateFieldType.Path), | ||
31 | }, | ||
32 | typeof(BBControlSymbol)); | ||
33 | } | ||
34 | } | ||
35 | |||
36 | namespace WixToolset.Data.Symbols | ||
37 | { | ||
38 | public enum BBControlSymbolFields | ||
39 | { | ||
40 | BillboardRef, | ||
41 | BBControl, | ||
42 | Type, | ||
43 | X, | ||
44 | Y, | ||
45 | Width, | ||
46 | Height, | ||
47 | Attributes, | ||
48 | Enabled, | ||
49 | Indirect, | ||
50 | Integer, | ||
51 | LeftScroll, | ||
52 | RightAligned, | ||
53 | RightToLeft, | ||
54 | Sunken, | ||
55 | Visible, | ||
56 | Text, | ||
57 | SourceFile | ||
58 | } | ||
59 | |||
60 | public class BBControlSymbol : IntermediateSymbol | ||
61 | { | ||
62 | public BBControlSymbol() : base(SymbolDefinitions.BBControl, null, null) | ||
63 | { | ||
64 | } | ||
65 | |||
66 | public BBControlSymbol(SourceLineNumber sourceLineNumber, Identifier id = null) : base(SymbolDefinitions.BBControl, sourceLineNumber, id) | ||
67 | { | ||
68 | } | ||
69 | |||
70 | public IntermediateField this[BBControlSymbolFields index] => this.Fields[(int)index]; | ||
71 | |||
72 | public string BillboardRef | ||
73 | { | ||
74 | get => (string)this.Fields[(int)BBControlSymbolFields.BillboardRef]; | ||
75 | set => this.Set((int)BBControlSymbolFields.BillboardRef, value); | ||
76 | } | ||
77 | |||
78 | public string BBControl | ||
79 | { | ||
80 | get => (string)this.Fields[(int)BBControlSymbolFields.BBControl]; | ||
81 | set => this.Set((int)BBControlSymbolFields.BBControl, value); | ||
82 | } | ||
83 | |||
84 | public string Type | ||
85 | { | ||
86 | get => (string)this.Fields[(int)BBControlSymbolFields.Type]; | ||
87 | set => this.Set((int)BBControlSymbolFields.Type, value); | ||
88 | } | ||
89 | |||
90 | public int X | ||
91 | { | ||
92 | get => (int)this.Fields[(int)BBControlSymbolFields.X]; | ||
93 | set => this.Set((int)BBControlSymbolFields.X, value); | ||
94 | } | ||
95 | |||
96 | public int Y | ||
97 | { | ||
98 | get => (int)this.Fields[(int)BBControlSymbolFields.Y]; | ||
99 | set => this.Set((int)BBControlSymbolFields.Y, value); | ||
100 | } | ||
101 | |||
102 | public int Width | ||
103 | { | ||
104 | get => (int)this.Fields[(int)BBControlSymbolFields.Width].AsNumber(); | ||
105 | set => this.Set((int)BBControlSymbolFields.Width, value); | ||
106 | } | ||
107 | |||
108 | public int Height | ||
109 | { | ||
110 | get => (int)this.Fields[(int)BBControlSymbolFields.Height]; | ||
111 | set => this.Set((int)BBControlSymbolFields.Height, value); | ||
112 | } | ||
113 | |||
114 | public int Attributes | ||
115 | { | ||
116 | get => this.Fields[(int)BBControlSymbolFields.Attributes].AsNumber(); | ||
117 | set => this.Set((int)BBControlSymbolFields.Attributes, value); | ||
118 | } | ||
119 | |||
120 | public bool Enabled | ||
121 | { | ||
122 | get => this.Fields[(int)BBControlSymbolFields.Enabled].AsBool(); | ||
123 | set => this.Set((int)BBControlSymbolFields.Enabled, value); | ||
124 | } | ||
125 | |||
126 | public bool Indirect | ||
127 | { | ||
128 | get => this.Fields[(int)BBControlSymbolFields.Indirect].AsBool(); | ||
129 | set => this.Set((int)BBControlSymbolFields.Indirect, value); | ||
130 | } | ||
131 | |||
132 | public bool Integer | ||
133 | { | ||
134 | get => this.Fields[(int)BBControlSymbolFields.Integer].AsBool(); | ||
135 | set => this.Set((int)BBControlSymbolFields.Integer, value); | ||
136 | } | ||
137 | |||
138 | public bool LeftScroll | ||
139 | { | ||
140 | get => this.Fields[(int)BBControlSymbolFields.LeftScroll].AsBool(); | ||
141 | set => this.Set((int)BBControlSymbolFields.LeftScroll, value); | ||
142 | } | ||
143 | |||
144 | public bool RightAligned | ||
145 | { | ||
146 | get => this.Fields[(int)BBControlSymbolFields.RightAligned].AsBool(); | ||
147 | set => this.Set((int)BBControlSymbolFields.RightAligned, value); | ||
148 | } | ||
149 | |||
150 | public bool RightToLeft | ||
151 | { | ||
152 | get => this.Fields[(int)BBControlSymbolFields.RightToLeft].AsBool(); | ||
153 | set => this.Set((int)BBControlSymbolFields.RightToLeft, value); | ||
154 | } | ||
155 | |||
156 | public bool Sunken | ||
157 | { | ||
158 | get => this.Fields[(int)BBControlSymbolFields.Sunken].AsBool(); | ||
159 | set => this.Set((int)BBControlSymbolFields.Sunken, value); | ||
160 | } | ||
161 | |||
162 | public bool Visible | ||
163 | { | ||
164 | get => this.Fields[(int)BBControlSymbolFields.Visible].AsBool(); | ||
165 | set => this.Set((int)BBControlSymbolFields.Visible, value); | ||
166 | } | ||
167 | |||
168 | public string Text | ||
169 | { | ||
170 | get => (string)this.Fields[(int)BBControlSymbolFields.Text]; | ||
171 | set => this.Set((int)BBControlSymbolFields.Text, value); | ||
172 | } | ||
173 | |||
174 | public IntermediateFieldPathValue SourceFile | ||
175 | { | ||
176 | get => this.Fields[(int)BBControlSymbolFields.SourceFile].AsPath(); | ||
177 | set => this.Set((int)BBControlSymbolFields.SourceFile, value); | ||
178 | } | ||
179 | } | ||
180 | } \ No newline at end of file | ||