Common: Use GridBuilder in DocumentResultList
This commit is contained in:
parent
dd2ed7d6a0
commit
04db51f845
@ -40,6 +40,7 @@ Public Class frmDocumentResultList
|
||||
Private _ResultLists As List(Of DocumentResult)
|
||||
Private _Helpers As DocumentResultList
|
||||
Private _Filesystem As DigitalData.Modules.Filesystem.File
|
||||
Private _GridBuilder As GridBuilder
|
||||
|
||||
' Runtime variables
|
||||
Private _IsLoading As Boolean = True
|
||||
@ -74,6 +75,7 @@ Public Class frmDocumentResultList
|
||||
_Config = New ConfigManager(Of DocumentResultConfig)(LogConfig, oConfigPath, oConfigPath)
|
||||
_Helpers = New DocumentResultList(LogConfig)
|
||||
_Filesystem = New Modules.Filesystem.File(_LogConfig)
|
||||
_GridBuilder = New GridBuilder(New List(Of GridView) From {GridView1, GridView2, GridView3})
|
||||
|
||||
_Environment = Environment
|
||||
_Params = Params
|
||||
@ -126,6 +128,10 @@ Public Class frmDocumentResultList
|
||||
SwitchDetailContainerHorizontal.Visibility = DevExpress.XtraBars.BarItemVisibility.Never
|
||||
End If
|
||||
|
||||
_GridBuilder.
|
||||
WithDefaults().
|
||||
WithReadOnlyOptions()
|
||||
|
||||
AddHandler GridView1.FocusedRowChanged, AddressOf GridView_FocusedRowChanged
|
||||
AddHandler GridView2.FocusedRowChanged, AddressOf GridView_FocusedRowChanged
|
||||
AddHandler GridView3.FocusedRowChanged, AddressOf GridView_FocusedRowChanged
|
||||
@ -928,24 +934,24 @@ Public Class frmDocumentResultList
|
||||
_DragBoxFromMouseDown = Rectangle.Empty
|
||||
End Sub
|
||||
|
||||
Private Sub GridView1_MouseMove(sender As GridView, e As MouseEventArgs) Handles GridView1.MouseMove
|
||||
If e.Button AndAlso e.Button = MouseButtons.Left Then
|
||||
If _DragBoxFromMouseDown <> Rectangle.Empty And Not _DragBoxFromMouseDown.Contains(e.X, e.Y) Then
|
||||
Private Sub GridView1_MouseMove(sender As GridView, e As MouseEventArgs) Handles GridView1.MouseMove
|
||||
If e.Button AndAlso e.Button = MouseButtons.Left Then
|
||||
If _DragBoxFromMouseDown <> Rectangle.Empty And Not _DragBoxFromMouseDown.Contains(e.X, e.Y) Then
|
||||
|
||||
Dim oHitInfo = sender.CalcHitInfo(e.Location)
|
||||
Dim oHitInfo = sender.CalcHitInfo(e.Location)
|
||||
|
||||
If oHitInfo.InRow Then
|
||||
If _CurrentDocument IsNot Nothing AndAlso _CurrentDocument.AccessRight >= Rights.AccessRight.VIEW_EXPORT Then
|
||||
_ScreenOffset = SystemInformation.WorkingArea.Location
|
||||
If oHitInfo.InRow Then
|
||||
If _CurrentDocument IsNot Nothing AndAlso _CurrentDocument.AccessRight >= Rights.AccessRight.VIEW_EXPORT Then
|
||||
_ScreenOffset = SystemInformation.WorkingArea.Location
|
||||
|
||||
Dim oFullPath As String = _CurrentDocument.FullPath
|
||||
Dim oFiles As String() = {oFullPath}
|
||||
Dim oData As New DataObject(DataFormats.FileDrop, oFiles)
|
||||
Dim oFullPath As String = _CurrentDocument.FullPath
|
||||
Dim oFiles As String() = {oFullPath}
|
||||
Dim oData As New DataObject(DataFormats.FileDrop, oFiles)
|
||||
|
||||
sender.GridControl.DoDragDrop(oData, DragDropEffects.All)
|
||||
End If
|
||||
sender.GridControl.DoDragDrop(oData, DragDropEffects.All)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
Loading…
x
Reference in New Issue
Block a user