-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMyGridRegistration.vb
39 lines (36 loc) · 1.25 KB
/
MyGridRegistration.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
Imports System
Imports DevExpress.XtraGrid
Imports DevExpress.XtraGrid.Drawing
Imports DevExpress.XtraGrid.Views.Base
Imports DevExpress.XtraGrid.Views.Base.ViewInfo
Imports DevExpress.XtraGrid.Registrator
Namespace CustomGrid
Public Class MyGridViewInfoRegistrator
Inherits GridInfoRegistrator
Public Overrides ReadOnly Property ViewName() As String
Get
Return "MyGridView"
End Get
End Property
Public Overrides Function CreateView(ByVal grid As GridControl) As BaseView
Return New MyGridView(TryCast(grid, GridControl))
End Function
Public Overrides Function CreatePainter(ByVal view As BaseView) As BaseViewPainter
Return New MyGridPainter(TryCast(view, MyGridView))
End Function
End Class
Public Class MyBandedGridViewInfoRegistrator
Inherits BandedGridInfoRegistrator
Public Overrides ReadOnly Property ViewName() As String
Get
Return "MyBandedGridView"
End Get
End Property
Public Overrides Function CreateView(ByVal grid As GridControl) As BaseView
Return New MyBandedGridView(TryCast(grid, GridControl))
End Function
Public Overrides Function CreatePainter(ByVal view As BaseView) As BaseViewPainter
Return New MyBandedGridPainter(TryCast(view, MyBandedGridView))
End Function
End Class
End Namespace