SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftPrintPreview/DLL 2.0 - Print Preview Control (discontinued)
SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftDirectory 3.5 - File/Folder Control (discontinued)
SftMask/OCX 7.0 - Masked Edit Control
SftOptions 1.0 - Registry/INI Control (discontinued)
SftPrintPreview/OCX 1.0 - Print Preview Control (discontinued)
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftTabs/NET 6.0 - Tab Control (discontinued)
SftTree/NET 2.0 - Tree Control
The SFTTREE_VIRTUALDEF structure is used by VirtualInitialize to use the tree control in virtual mode and to define the virtual data source.
typedef struct tagSftTreeVirtualFuncs { DWORD version; SFTTREE_DWORD_PTR userdataVirtPool; LPFNSFTTREE_VGETITEM lpfnVGetItem; LPFNSFTTREE_VRELEASEITEM lpfnVReleaseItem; LPFNSFTTREE_VGETSTATUS lpfnVGetStatus; LPFNSFTTREE_VSETSTATUS lpfnVSetStatus; LPFNSFTTREE_VINDEXTOVISIBLE lpfnVCvtIndexToVisible; LPFNSFTTREE_VVISIBLETOINDEX lpfnVCvtVisibleToIndex; LPFNSFTTREE_VGETPARENTINDEX lpfnVGetParentIndex; LPFNSFTTREE_VGETNEXTSIBLING lpfnVGetNextSibling; LPFNSFTTREE_VGETPREVSIBLING lpfnVGetPrevSibling; LPFNSFTTREE_VGETFIRSTSIBLING lpfnVGetFirstSibling; LPFNSFTTREE_VGETLASTSIBLING lpfnVGetLastSibling; LPFNSFTTREE_VGETITEM_EX lpfnVGetItemEx; LPFNSFTTREE_VRELEASEITEM_EX lpfnVReleaseItemEx; SFTTREE_DWORD_PTR res4, res5, res6; } SFTTREE_VIRTUALDEF, * LPSFTTREE_VIRTUALDEF; typedef const SFTTREE_VIRTUALDEF * LPCSFTTREE_VIRTUALDEF;
The SftTree/DLL version expected by the application. This value must be set to SFTTREE_VERSION_750, otherwise the call to VirtualInitialize will fail (SFTTREE_VERSION_400, SFTTREE_VERSION_450, SFTTREE_VERSION_500, SFTTREE_VERSION_600 and SFTTREE_VERSION_650 are still accepted as the current version is upward compatible). This version field will be used by future versions of SftTree/DLL to provide upward compatibility for applications designed for earlier versions.
An application defined value. May be 0. This value is used as userData parameter in the callback functions SFTTREE_VGETITEM, SFTTREE_VRELEASEITEM, etc. The value defined here can also be retrieved using GetVirtualUserData.
A pointer to a callback function SFTTREE_VGETITEM. This function is called by SftTree/DLL to retrieve item information.
A pointer to a callback function SFTTREE_VRELEASEITEM. This function is called by SftTree/DLL to release item information previously retrieved using SFTTREE_VGETITEM.
lpfnVGetStatus, lpfnVSetStatus, lpfnVCvtIndexToVisible, , lpfnVCvtVisibleToIndex, lpfnVGetParentIndex, lpfnVGetNextSibling, lpfnVGetPrevSibling, lpfnVGetFirstSibling, lpfnVGetLastSibling, lpfnVGetItemEx, lpfnVReleaseItemEx, res4, res5, res6
These fields must be set to NULL and are reserved for future use.
The SFTTREE_VIRTUALDEF structure is used by VirtualInitialize to use the tree control in virtual mode and to define the virtual data source.
All fields marked "reserved for future use" must be initialized to 0 or NULL to insure compatibility with future releases of SftTree/DLL.
SftTree/DLL supports "flat" lists only in virtual mode. Hierarchies cannot be represented in virtual mode.
/* Resources, such as bitmaps, should be loaded and must remain */ /* valid until the tree control is destroyed or no longer uses */ /* these. For example, use DeleteObject to delete any bitmaps. */ /* Initialize "virtual" data callback routines. The */ /* routines used are defined below. */ { SFTTREE_VIRTUALDEF virt = { SFTTREE_VERSION_700, 0, Tree_VirtualStorageGetItemCallback, Tree_VirtualStorageReleaseItemCallback, }; if (!SftTreeSplit_VirtualInitialize(g_hwndTree, &virt)) ; /* error handling goes here */ /* Set current number of items in the control. */
/* these. */ /* Initialize "virtual" data callback routines. The */ /* routines used are defined below. The callbacks are */ /* static functions so they don't have a 'this' pointer. */ /* We pass the 'this' pointer as userdata for the call- */ /* back routine. */ { SFTTREE_VIRTUALDEF virt = { SFTTREE_VERSION_700, (SFTTREE_DWORD_PTR)(LPVOID)this, VirtualStorageGetItemCallback, VirtualStorageReleaseItemCallback, }; if (!m_Tree.VirtualInitialize(&virt)) return -1; /* error handling goes here */
See Also C/C++ API | Categories | Notifications