vbAccelerator - Contents of code file: cCTreeViewNodeSubItem.clsVERSION 1.0 CLASS
BEGIN
MultiUse = -1 'True
END
Attribute VB_Name = "cCTreeViewNodeSubItem"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = True
Option Explicit
Private m_hWndCtl As Long
Private m_lID As Long
Private m_lIndex As Long
Friend Sub fInit(ctl As vbalColumnTreeView, ByVal lID As Long, ByVal lIndex As
Long)
m_hWndCtl = ctl.hwnd
m_lID = lID
m_lIndex = lIndex
End Sub
Private Function pbVerify(ByRef ctlThis As vbalColumnTreeView) As Boolean
Dim lPtr As Long
Dim lIdx As Long
If IsWindow(m_hWndCtl) Then
lPtr = GetProp(m_hWndCtl, gcOBJECT_PROP)
If Not (lPtr = 0) Then
If (lPtr = 1) Then
Debug.Print "NOOOOOO"
End If
Set ctlThis = ObjectFromPtr(lPtr)
If (ctlThis.fhItemForID(m_lID)) Then
pbVerify = True
End If
Else
gErr 1, "cListItems"
End If
Else
gErr 1, "cListItems"
End If
End Function
Public Property Get Text() As String
Dim ctl As vbalColumnTreeView
If (pbVerify(ctl)) Then
Text = ctl.fSubItemText(m_lID, m_lIndex)
End If
End Property
Public Property Let Text(ByVal sText As String)
Dim ctl As vbalColumnTreeView
If (pbVerify(ctl)) Then
ctl.fSubItemText(m_lID, m_lIndex) = sText
End If
End Property
Public Property Get Image() As Long
Dim ctl As vbalColumnTreeView
If (pbVerify(ctl)) Then
Image = ctl.fSubItemImage(m_lID, m_lIndex)
End If
End Property
Public Property Let Image(ByVal lIconIndex As Long)
Dim ctl As vbalColumnTreeView
If (pbVerify(ctl)) Then
ctl.fSubItemImage(m_lID, m_lIndex) = lIconIndex
End If
End Property
|
|