Private Sub InitTable
Data.Initialize
visibleRows.Initialize
pnlTable.Tag = "Table"
TableObject = Me
[COLOR=rgb(84, 172, 210)]SV[/COLOR].Initialize(0, 0, "[COLOR=rgb(84, 172, 210)]SV[/COLOR]")
internalPanel.Initialize("IP")
innerClearAll(mNumberOfColumns)
[COLOR=rgb(84, 172, 210)]SV[/COLOR].Panel.Color = cTableColor
IsVisible = True
Header.Initialize("")
Header.Color = cTableColor
pnlTable.AddView(Header, 0, 0 , cWidth, cHeaderHeight)
' add status line
lblStatusLine.Initialize("")
lblStatusLine.Color = Colors.Transparent ' is it really ?
internalPanel.Color = Colors.Transparent 'TODO uncomment this
If (cShowStatusLine = True) Then
pnlTable.AddView([COLOR=rgb(84, 172, 210)]SV[/COLOR], 0, Header.Height, cWidth, cHeight - Header.Height - cRowHeight)
pnlTable.AddView(lblStatusLine,0, [COLOR=rgb(84, 172, 210)]SV[/COLOR].Top + [COLOR=rgb(84, 172, 210)]SV[/COLOR].Height, cWidth, cRowHeight)
Else
pnlTable.AddView([COLOR=rgb(84, 172, 210)]SV[/COLOR], 0, Header.Height, cWidth, cHeight - Header.Height)
pnlTable.AddView(lblStatusLine,0, [COLOR=rgb(84, 172, 210)]SV[/COLOR].Top + [COLOR=rgb(84, 172, 210)]SV[/COLOR].Height, 0, 0)
End If
pnlTable.AddView(internalPanel, 0, 0, cWidth, 0)
updateIPLocation
Dim ColumnWidths(mNumberOfColumns) As Int
Dim HeaderWidths(mNumberOfColumns) As Int
Dim DataWidths(mNumberOfColumns) As Int
Dim SavedWidths(mNumberOfColumns) As Int
Dim cColumnDataType(mNumberOfColumns) As String
For i = 0 To mNumberOfColumns - 1
ColumnWidths(i) = [COLOR=rgb(84, 172, 210)]SV[/COLOR].Width / mNumberOfColumns
HeaderWidths(i) = ColumnWidths(i)
DataWidths(i) = ColumnWidths(i)
SavedWidths(i) = ColumnWidths(i)
cColumnDataType(i) = "TEXT"
Next
[COLOR=rgb(84, 172, 210)]SV[/COLOR].Panel.Width = [COLOR=rgb(84, 172, 210)]SV[/COLOR].Width
[COLOR=rgb(84, 172, 210)]SV[/COLOR]_ScrollChanged(0, 0)
If (lblStatusLine.IsInitialized And enableStatusLineAutoFill=True) Then setStatusLine(Data.Size & " rows") ' should this be automatic ?
sortingView.Initialize("")
' used for string width measuements in the LoadSQLiteDB routine
bmp.InitializeMutable(2dip, 2dip)
cvs.Initialize2(bmp)
End Sub