forked from dotnet/project-system
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPropPage.vb
392 lines (295 loc) · 12.6 KB
/
PropPage.vb
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
' Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE.md file in the project root for more information.
Imports System.Runtime.InteropServices
Imports System.Windows.Forms
Imports Microsoft.VisualStudio.Shell
Namespace Microsoft.VisualStudio.Editors.PropertyPages
'CONSIDER: move these to the individual page class files, or at least to a separate .vb file
#Region "Com Classes for our property pages"
#Region "Application property pages (VB and C#)"
'Property page class hierarchy:
'
' ApplicationPropPageBase
' + ApplicationPropPageVBBase
' + ApplicationPropPageVBWinForms
' + ApplicationPropPageVBWPF
' + ApplicationPropPage
' + CSharpApplicationPropPage
'
#Region "ApplicationPropPageComClass (Not directly used, inherited from by C#)"
<Guid("1C25D270-6E41-4360-9221-1D22E4942FAD"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(ApplicationPropPageComClass))>
Public NotInheritable Class ApplicationPropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ApplicationTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(ApplicationPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New ApplicationPropPage
End Function
End Class
#End Region
#Region "ApplicationWithMyPropPageComClass (VB Application property page)"
'Note: This is the VB Application page (naming is historical)
<Guid("8998E48E-B89A-4034-B66E-353D8C1FDC2E"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(ApplicationWithMyPropPageComClass))>
Public NotInheritable Class ApplicationWithMyPropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ApplicationTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(ApplicationPropPageVBWinForms)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New ApplicationPropPageVBWinForms
End Function
End Class
#End Region
#Region "WPFApplicationWithMyPropPageComClass (VB Application page for WPF)"
<Guid("00aa1f44-2ba3-4eaa-b54a-ce18000e6c5d"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(WPFApplicationWithMyPropPageComClass))>
Public NotInheritable Class WPFApplicationWithMyPropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ApplicationTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(WPF.ApplicationPropPageVBWPF)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New WPF.ApplicationPropPageVBWPF
End Function
End Class
#End Region
#Region "CSharpApplicationPropPageComClass (C# Application property page)"
<Guid("5E9A8AC2-4F34-4521-858F-4C248BA31532"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(CSharpApplicationPropPageComClass))>
Public NotInheritable Class CSharpApplicationPropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ApplicationTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(CSharpApplicationPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New CSharpApplicationPropPage
End Function
End Class
#End Region
#End Region
#Region "PackagePropPageComClass (Package property page)"
<Guid("21b78be8-3957-4caa-bf2f-e626107da58e"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(PackagePropPageComClass))>
Public NotInheritable Class PackagePropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_PackageTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(PackagePropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New PackagePropPage
End Function
End Class
#End Region
#Region "CompilePropPageComClass"
<Guid("EDA661EA-DC61-4750-B3A5-F6E9C74060F5"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(CompilePropPageComClass))>
Public NotInheritable Class CompilePropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_CompileTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(CompilePropPage2)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New CompilePropPage2
End Function
Protected Overrides Property DefaultSize As Drawing.Size
Get
' This is somewhat hacky, but the compile's size page can sometimes exceed the default
' minimum size for a property page. The PropPageDesignerView will query for this in order to
' figure out what the minimum autoscrollsize should be set to, but it will also check
' the size of the actual control and use the min of those two values, so as long as we
' we return a default size that is larger than what our maximum minimum size will be, we
' should be fine
Return New Drawing.Size(Integer.MaxValue, Integer.MaxValue)
End Get
Set
MyBase.DefaultSize = Value
End Set
End Property
End Class
#End Region
#Region "ServicesPropPageComClass"
<Guid("43E38D2E-43B8-4204-8225-9357316137A4"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(ServicesPropPageComClass))>
Public NotInheritable Class ServicesPropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_Services
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(ServicesPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New ServicesPropPage
End Function
End Class
#End Region
#Region "DebugPropPageComClass"
<Guid("6185191F-1008-4FB2-A715-3A4E4F27E610"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(DebugPropPageComClass))>
Public NotInheritable Class DebugPropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_DebugTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(DebugPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New DebugPropPage
End Function
End Class
#End Region
#Region "VBBasePropPageComClass"
<Guid("4E43F4AB-9F03-4129-95BF-B8FF870AF6AB"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(ReferencePropPageComClass))>
Public NotInheritable Class ReferencePropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ReferencesTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(ReferencePropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New ReferencePropPage
End Function
End Class
#End Region
#Region "BuildPropPageComClass"
<Guid("A54AD834-9219-4aa6-B589-607AF21C3E26"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(BuildPropPageComClass))>
Public NotInheritable Class BuildPropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_BuildTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(BuildPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New BuildPropPage
End Function
End Class
#End Region
#Region "BuildEventsPropPageComClass"
<Guid("1E78F8DB-6C07-4d61-A18F-7514010ABD56"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(BuildEventsPropPageComClass))>
Public NotInheritable Class BuildEventsPropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_BuildEventsTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(BuildEventsPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New BuildEventsPropPage
End Function
End Class
#End Region
#Region "ReferencePathsPropPageComClass"
<Guid("031911C8-6148-4e25-B1B1-44BCA9A0C45C"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(ReferencePathsPropPageComClass))>
Public NotInheritable Class ReferencePathsPropPageComClass
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_ReferencePathsTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(ReferencePathsPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New ReferencePathsPropPage
End Function
End Class
#End Region
#Region "CodeAnalysisPropPageComClass (Code Analysis property page)"
<Guid("c02f393c-8a1e-480d-aa82-6a75d693559d"), ComVisible(True), CLSCompliant(False)>
<ProvideObject(GetType(CodeAnalysisPropPageComClass))>
Public NotInheritable Class CodeAnalysisPropPageComClass 'See class hierarchy comments above
Inherits VBPropPageBase
Protected Overrides ReadOnly Property Title As String
Get
Return My.Resources.Microsoft_VisualStudio_Editors_Designer.PPG_CodeAnalysisTitle
End Get
End Property
Protected Overrides ReadOnly Property ControlType As Type
Get
Return GetType(CodeAnalysisPropPage)
End Get
End Property
Protected Overrides Function CreateControl() As Control
Return New CodeAnalysisPropPage
End Function
End Class
#End Region
#End Region
End Namespace