-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathClassTreeView.vb
166 lines (122 loc) · 5.12 KB
/
ClassTreeView.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
Imports System.Windows.Forms
Namespace Controls
Namespace AdvancedTreeViewNodes
Public Enum AdvancedTreeViewNodeType
ComboBox
TextBox
Button
End Enum
''' <summary>
''' Still need work to map the button press handling
''' </summary>
Public Class ButtonNode
Inherits Windows.Forms.TreeNode
Private m_ComboBox As Button = New Button()
Public Sub New()
End Sub
Public Sub New(text As String)
MyBase.New()
Button.Text = text
End Sub
Public Sub New(text As String, children() As Windows.Forms.TreeNode)
MyBase.New(text, children)
Button.Text = text
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer)
MyBase.New(text, imageIndex, selectedImageIndex)
Button.Text = text
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer, children() As Windows.Forms.TreeNode)
MyBase.New(text, imageIndex, selectedImageIndex, children)
Button.Text = text
End Sub
Protected Sub New(serializationInfo As Runtime.Serialization.SerializationInfo, context As Runtime.Serialization.StreamingContext)
MyBase.New(serializationInfo, context)
End Sub
Public Property Button As Button
Get
Return Me.m_ComboBox
End Get
Set(ByVal value As Button)
Me.m_ComboBox = value
End Set
End Property
Public ReadOnly Property Type As AdvancedTreeViewNodeType
Get
Return AdvancedTreeViewNodeType.Button
End Get
End Property
End Class
Public Class ComboBoxNode
Inherits Windows.Forms.TreeNode
Private m_ComboBox As ComboBox = New ComboBox()
Public Sub New()
End Sub
Public Sub New(text As String)
MyBase.New(text)
End Sub
Public Sub New(text As String, children() As Windows.Forms.TreeNode)
MyBase.New(text, children)
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer)
MyBase.New(text, imageIndex, selectedImageIndex)
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer, children() As Windows.Forms.TreeNode)
MyBase.New(text, imageIndex, selectedImageIndex, children)
End Sub
Protected Sub New(serializationInfo As Runtime.Serialization.SerializationInfo, context As Runtime.Serialization.StreamingContext)
MyBase.New(serializationInfo, context)
End Sub
Public Property ComboBox As ComboBox
Get
Me.m_ComboBox.DropDownStyle = ComboBoxStyle.DropDown
Return Me.m_ComboBox
End Get
Set(ByVal value As ComboBox)
Me.m_ComboBox = value
End Set
End Property
Public ReadOnly Property Type As AdvancedTreeViewNodeType
Get
Return AdvancedTreeViewNodeType.ComboBox
End Get
End Property
End Class
Public Class TextBoxNode
Inherits Windows.Forms.TreeNode
Private m_ComboBox As TextBox = New TextBox()
Public Sub New()
End Sub
Public Sub New(text As String)
MyBase.New()
TextBox.Text = text
End Sub
Public Sub New(text As String, children() As Windows.Forms.TreeNode)
MyBase.New(text, children)
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer)
MyBase.New(text, imageIndex, selectedImageIndex)
End Sub
Public Sub New(text As String, imageIndex As Integer, selectedImageIndex As Integer, children() As Windows.Forms.TreeNode)
MyBase.New(text, imageIndex, selectedImageIndex, children)
End Sub
Protected Sub New(serializationInfo As Runtime.Serialization.SerializationInfo, context As Runtime.Serialization.StreamingContext)
MyBase.New(serializationInfo, context)
End Sub
Public Property TextBox As TextBox
Get
Return Me.m_ComboBox
End Get
Set(ByVal value As TextBox)
Me.m_ComboBox = value
End Set
End Property
Public ReadOnly Property Type As AdvancedTreeViewNodeType
Get
Return AdvancedTreeViewNodeType.TextBox
End Get
End Property
End Class
End Namespace
End Namespace