Changed some treeview related definitions.
This commit is contained in:
parent
a9c17d2e3d
commit
26ff83dfed
|
@ -17,7 +17,7 @@
|
||||||
* -drag&drop.
|
* -drag&drop.
|
||||||
* -scrollbars.
|
* -scrollbars.
|
||||||
* -Unicode messages
|
* -Unicode messages
|
||||||
* -TVITEMEX
|
* -TV_ITEMEX
|
||||||
*
|
*
|
||||||
* FIXMEs:
|
* FIXMEs:
|
||||||
-GetNextItem: add flags for traversing child lists.
|
-GetNextItem: add flags for traversing child lists.
|
||||||
|
@ -512,7 +512,7 @@ TREEVIEW_SetItem (WND *wndPtr, WPARAM32 wParam, LPARAM lParam)
|
||||||
TV_ITEM *tvItem;
|
TV_ITEM *tvItem;
|
||||||
INT32 iItem,len;
|
INT32 iItem,len;
|
||||||
|
|
||||||
tvItem=(LPTVITEM) lParam;
|
tvItem=(LPTV_ITEM) lParam;
|
||||||
iItem=tvItem->hItem;
|
iItem=tvItem->hItem;
|
||||||
TRACE (treeview,"item %d,mask %x\n",iItem,tvItem->mask);
|
TRACE (treeview,"item %d,mask %x\n",iItem,tvItem->mask);
|
||||||
|
|
||||||
|
@ -715,12 +715,12 @@ static LRESULT
|
||||||
TREEVIEW_GetItem (WND *wndPtr, WPARAM32 wParam, LPARAM lParam)
|
TREEVIEW_GetItem (WND *wndPtr, WPARAM32 wParam, LPARAM lParam)
|
||||||
{
|
{
|
||||||
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
||||||
LPTVITEM tvItem;
|
LPTV_ITEM tvItem;
|
||||||
TREEVIEW_ITEM *wineItem;
|
TREEVIEW_ITEM *wineItem;
|
||||||
INT32 iItem;
|
INT32 iItem;
|
||||||
|
|
||||||
TRACE (treeview,"\n");
|
TRACE (treeview,"\n");
|
||||||
tvItem=(LPTVITEM) lParam;
|
tvItem=(LPTV_ITEM) lParam;
|
||||||
iItem=tvItem->hItem;
|
iItem=tvItem->hItem;
|
||||||
|
|
||||||
wineItem = TREEVIEW_ValidItem (infoPtr, iItem);
|
wineItem = TREEVIEW_ValidItem (infoPtr, iItem);
|
||||||
|
@ -850,13 +850,13 @@ TREEVIEW_InsertItem32A (WND *wndPtr, WPARAM32 wParam, LPARAM lParam)
|
||||||
|
|
||||||
{
|
{
|
||||||
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
||||||
TVINSERTSTRUCT *ptdi;
|
TVINSERTSTRUCTA *ptdi;
|
||||||
TV_ITEM *tvItem;
|
TV_ITEM *tvItem;
|
||||||
TREEVIEW_ITEM *wineItem, *parentItem, *prevsib, *sibItem;
|
TREEVIEW_ITEM *wineItem, *parentItem, *prevsib, *sibItem;
|
||||||
INT32 iItem,listItems,i,len;
|
INT32 iItem,listItems,i,len;
|
||||||
|
|
||||||
TRACE (treeview,"\n");
|
TRACE (treeview,"\n");
|
||||||
ptdi = (TVINSERTSTRUCT *) lParam;
|
ptdi = (TVINSERTSTRUCTA *) lParam;
|
||||||
|
|
||||||
/* check if memory is available */
|
/* check if memory is available */
|
||||||
|
|
||||||
|
@ -1261,7 +1261,7 @@ TREEVIEW_SendTreeviewNotify (WND *wndPtr, UINT32 code, UINT32 action,
|
||||||
INT32 oldItem, INT32 newItem, POINT32 pt)
|
INT32 oldItem, INT32 newItem, POINT32 pt)
|
||||||
{
|
{
|
||||||
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
TREEVIEW_INFO *infoPtr = TREEVIEW_GetInfoPtr(wndPtr);
|
||||||
NMTREEVIEW nmhdr;
|
NM_TREEVIEW nmhdr;
|
||||||
TREEVIEW_ITEM *wineItem;
|
TREEVIEW_ITEM *wineItem;
|
||||||
|
|
||||||
TRACE (treeview,"code:%x action:%x olditem:%x newitem:%x\n",
|
TRACE (treeview,"code:%x action:%x olditem:%x newitem:%x\n",
|
||||||
|
|
|
@ -1755,7 +1755,23 @@ typedef struct {
|
||||||
INT32 iSelectedImage;
|
INT32 iSelectedImage;
|
||||||
INT32 cChildren;
|
INT32 cChildren;
|
||||||
LPARAM lParam;
|
LPARAM lParam;
|
||||||
} TV_ITEM, *LPTVITEM;
|
} TVITEMA, *LPTVITEMA;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
UINT32 mask;
|
||||||
|
HTREEITEM hItem;
|
||||||
|
UINT32 state;
|
||||||
|
UINT32 stateMask;
|
||||||
|
LPWSTR pszText;
|
||||||
|
int cchTextMax;
|
||||||
|
int iImage;
|
||||||
|
int iSelectedImage;
|
||||||
|
int cChildren;
|
||||||
|
LPARAM lParam;
|
||||||
|
} TVITEMW, *LPTVITEMW;
|
||||||
|
|
||||||
|
#define LPTV_ITEM LPTVITEMA
|
||||||
|
#define TV_ITEM TVITEMA
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
UINT32 mask;
|
UINT32 mask;
|
||||||
|
@ -1768,34 +1784,72 @@ typedef struct {
|
||||||
INT32 iSelectedImage;
|
INT32 iSelectedImage;
|
||||||
INT32 cChildren;
|
INT32 cChildren;
|
||||||
LPARAM lParam;
|
LPARAM lParam;
|
||||||
INT32 iIntegral;
|
int iIntegral;
|
||||||
} TV_ITEMEX, *LPTVITEMEX;
|
} TVITEMEXA, *LPTVITEMEXA;
|
||||||
|
|
||||||
#define TVITEM TV_ITEM
|
typedef struct {
|
||||||
|
UINT32 mask;
|
||||||
|
HTREEITEM hItem;
|
||||||
|
UINT32 state;
|
||||||
|
UINT32 stateMask;
|
||||||
|
LPWSTR pszText;
|
||||||
|
int cchTextMax;
|
||||||
|
int iImage;
|
||||||
|
int iSelectedImage;
|
||||||
|
int cChildren;
|
||||||
|
LPARAM lParam;
|
||||||
|
int iIntegral;
|
||||||
|
} TVITEMEXW, *LPTV_ITEMEXW;
|
||||||
|
|
||||||
|
#define TV_ITEMEX TVITEMEXA
|
||||||
|
#define LPTV_ITEMEXA LPTVITEMEXA
|
||||||
|
|
||||||
|
typedef struct tagTVINSERTSTRUCTA {
|
||||||
typedef struct tagTVINSERTSTRUCT {
|
|
||||||
HTREEITEM hParent;
|
HTREEITEM hParent;
|
||||||
HTREEITEM hInsertAfter;
|
HTREEITEM hInsertAfter;
|
||||||
TV_ITEM item;
|
TVITEMA item;
|
||||||
} TVINSERTSTRUCT, *LPTVINSERTSTRUCT;
|
} TVINSERTSTRUCTA, *LPTVINSERTSTRUCTA;
|
||||||
|
|
||||||
#define TV_INSERTSTRUCT TVINSERTSTRUCT
|
typedef struct tagTVINSERTSTRUCTW {
|
||||||
#define LPTV_INSERTSTRUCT LPTVINSERTSTRUCT
|
HTREEITEM hParent;
|
||||||
|
HTREEITEM hInsertAfter;
|
||||||
|
TVITEMW item;
|
||||||
|
} TVINSERTSTRUCTW, *LPTVINSERTSTRUCTW;
|
||||||
|
|
||||||
typedef struct tagNMTREEVIEW {
|
#define TV_INSERTSTRUCT TVINSERTSTRUCTA
|
||||||
|
#define LPTV_INSERTSTRUCT LPTVINSERTSTRUCTA
|
||||||
|
|
||||||
|
typedef struct tagNMTREEVIEWA {
|
||||||
NMHDR hdr;
|
NMHDR hdr;
|
||||||
UINT32 action;
|
UINT32 action;
|
||||||
TVITEM itemOld;
|
TVITEMA itemOld;
|
||||||
TVITEM itemNew;
|
TVITEMA itemNew;
|
||||||
POINT32 ptDrag;
|
POINT32 ptDrag;
|
||||||
} NMTREEVIEW, *LPNMTREEVIEW;
|
} NMTREEVIEWA, *LPNMTREEVIEWA;
|
||||||
|
|
||||||
typedef struct tagTVDISPINFO {
|
typedef struct tagNMTREEVIEWW {
|
||||||
NMHDR hdr;
|
NMHDR hdr;
|
||||||
TVITEM item;
|
UINT32 action;
|
||||||
} NMTVDISPINFO, *LPNMTVDISPINFO;
|
TVITEMW itemOld;
|
||||||
|
TVITEMW itemNew;
|
||||||
|
POINT32 ptDrag;
|
||||||
|
} NMTREEVIEWW, *LPNMTREEVIEWW;
|
||||||
|
|
||||||
|
#define NM_TREEVIEW NMTREEVIEWA
|
||||||
|
#define LPNM_TREEVIEW LPNMTREEVIEWA
|
||||||
|
|
||||||
|
typedef struct tagTVDISPINFOA {
|
||||||
|
NMHDR hdr;
|
||||||
|
TVITEMA item;
|
||||||
|
} NMTVDISPINFOA, *LPNMTVDISPINFOA;
|
||||||
|
|
||||||
|
typedef struct tagTVDISPINFOW {
|
||||||
|
NMHDR hdr;
|
||||||
|
TVITEMW item;
|
||||||
|
} NMTVDISPINFOW, *LPNMTVDISPINFOW;
|
||||||
|
|
||||||
|
#define NMTVDISPINFO NMTVDISPINFOA
|
||||||
|
#define LPNMTVDISPINFO LPNMTVDISPINFOA
|
||||||
|
|
||||||
typedef INT32 (CALLBACK *PFNTVCOMPARE)(LPARAM, LPARAM, LPARAM);
|
typedef INT32 (CALLBACK *PFNTVCOMPARE)(LPARAM, LPARAM, LPARAM);
|
||||||
|
|
||||||
|
@ -1817,9 +1871,9 @@ typedef struct tagTVHITTESTINFO {
|
||||||
|
|
||||||
#define TV_HITTESTINFO TVHITTESTINFO
|
#define TV_HITTESTINFO TVHITTESTINFO
|
||||||
|
|
||||||
#define TreeView_InsertItem(hwndHD, phdi) \
|
#define TreeView_InsertItem32A(hwnd, phdi) \
|
||||||
(INT32)SendMessage32A((hwnd), TVM_INSERTITEM, 0, \
|
(INT32)SendMessage32A((hwnd), TVM_INSERTITEM32A, 0, \
|
||||||
(LPARAM)(LPTV_INSERTSTRUCT)(phdi))
|
(LPARAM)(LPTVINSERTSTRUCTA)(phdi))
|
||||||
#define TreeView_DeleteItem(hwnd, hItem) \
|
#define TreeView_DeleteItem(hwnd, hItem) \
|
||||||
(BOOL32)SendMessage32A((hwnd), TVM_DELETEITEM, 0, (LPARAM)(HTREEITEM)(hItem))
|
(BOOL32)SendMessage32A((hwnd), TVM_DELETEITEM, 0, (LPARAM)(HTREEITEM)(hItem))
|
||||||
#define TreeView_DeleteAllItems(hwnd) \
|
#define TreeView_DeleteAllItems(hwnd) \
|
||||||
|
@ -1877,7 +1931,7 @@ typedef struct tagTVHITTESTINFO {
|
||||||
|
|
||||||
|
|
||||||
#define TreeView_Select(hwnd, hitem, code) \
|
#define TreeView_Select(hwnd, hitem, code) \
|
||||||
(UINT32)SendMessage32A((hwnd), TVM_SELECTITEM, (WPARAM)code, \
|
(UINT32)SendMessage32A((hwnd), TVM_SELECTITEM, (WPARAM32)code, \
|
||||||
(LPARAM)(UINT32)(hitem))
|
(LPARAM)(UINT32)(hitem))
|
||||||
|
|
||||||
|
|
||||||
|
@ -1890,11 +1944,11 @@ typedef struct tagTVHITTESTINFO {
|
||||||
TreeView_Select(hwnd, hitem, TVGN_FIRSTVISIBLE)
|
TreeView_Select(hwnd, hitem, TVGN_FIRSTVISIBLE)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define TreeView_GetItem(hwnd, pitem) \
|
#define TreeView_GetItem32A(hwnd, pitem) \
|
||||||
(BOOL32)SendMessage32A((hwnd), TVM_GETITEM, 0, (LPARAM) (TV_ITEM *)(pitem))
|
(BOOL32)SendMessage32A((hwnd), TVM_GETITEM32A, 0, (LPARAM) (TVITEMA *)(pitem))
|
||||||
|
|
||||||
#define TreeView_SetItem(hwnd, pitem) \
|
#define TreeView_SetItem32A(hwnd, pitem) \
|
||||||
(BOOL32)SendMessage32A((hwnd), TVM_SETITEM, 0, (LPARAM)(const TV_ITEM *)(pitem))
|
(BOOL32)SendMessage32A((hwnd), TVM_SETITEM32A, 0, (LPARAM)(const TVITEMA *)(pitem))
|
||||||
|
|
||||||
#define TreeView_EditLabel(hwnd, hitem) \
|
#define TreeView_EditLabel(hwnd, hitem) \
|
||||||
(HWND)SendMessage32A((hwnd), TVM_EDITLABEL, 0, (LPARAM)(HTREEITEM)(hitem))
|
(HWND)SendMessage32A((hwnd), TVM_EDITLABEL, 0, (LPARAM)(HTREEITEM)(hitem))
|
||||||
|
@ -1908,32 +1962,32 @@ typedef struct tagTVHITTESTINFO {
|
||||||
|
|
||||||
#define TreeView_HitTest(hwnd, lpht) \
|
#define TreeView_HitTest(hwnd, lpht) \
|
||||||
(HTREEITEM)SendMessage32A((hwnd), TVM_HITTEST, 0,\
|
(HTREEITEM)SendMessage32A((hwnd), TVM_HITTEST, 0,\
|
||||||
(LPARAM)(LPTV_HITTESTINFO)(lpht))
|
(LPARAM)(LPTVHITTESTINFO)(lpht))
|
||||||
|
|
||||||
#define TreeView_CreateDragImage(hwnd, hitem) \
|
#define TreeView_CreateDragImage(hwnd, hitem) \
|
||||||
(HIMAGELIST)SendMessage32A((hwnd), TVM_CREATEDRAGIMAGE, 0,\
|
(HIMAGELIST)SendMessage32A((hwnd), TVM_CREATEDRAGIMAGE, 0,\
|
||||||
(LPARAM)(HTREEITEM)(hitem))
|
(LPARAM)(HTREEITEM)(hitem))
|
||||||
|
|
||||||
#define TreeView_SortChildren(hwnd, hitem, recurse) \
|
#define TreeView_SortChildren(hwnd, hitem, recurse) \
|
||||||
(BOOL)SendMessage32A((hwnd), TVM_SORTCHILDREN, (WPARAM)recurse,\
|
(BOOL32)SendMessage32A((hwnd), TVM_SORTCHILDREN, (WPARAM32)recurse,\
|
||||||
(LPARAM)(HTREEITEM)(hitem))
|
(LPARAM)(HTREEITEM)(hitem))
|
||||||
|
|
||||||
#define TreeView_EnsureVisible(hwnd, hitem) \
|
#define TreeView_EnsureVisible(hwnd, hitem) \
|
||||||
(BOOL)SendMessage32A((hwnd), TVM_ENSUREVISIBLE, 0, (LPARAM)(UINT32)(hitem))
|
(BOOL32)SendMessage32A((hwnd), TVM_ENSUREVISIBLE, 0, (LPARAM)(UINT32)(hitem))
|
||||||
|
|
||||||
#define TreeView_SortChildrenCB(hwnd, psort, recurse) \
|
#define TreeView_SortChildrenCB(hwnd, psort, recurse) \
|
||||||
(BOOL)SendMessage32A((hwnd), TVM_SORTCHILDRENCB, (WPARAM)recurse, \
|
(BOOL32)SendMessage32A((hwnd), TVM_SORTCHILDRENCB, (WPARAM32)recurse, \
|
||||||
(LPARAM)(LPTV_SORTCB)(psort))
|
(LPARAM)(LPTV_SORTCB)(psort))
|
||||||
|
|
||||||
#define TreeView_EndEditLabelNow(hwnd, fCancel) \
|
#define TreeView_EndEditLabelNow(hwnd, fCancel) \
|
||||||
(BOOL)SendMessage32A((hwnd), TVM_ENDEDITLABELNOW, (WPARAM)fCancel, 0)
|
(BOOL32)SendMessage32A((hwnd), TVM_ENDEDITLABELNOW, (WPARAM32)fCancel, 0)
|
||||||
|
|
||||||
#define TreeView_GetISearchString(hwndTV, lpsz) \
|
#define TreeView_GetISearchString(hwndTV, lpsz) \
|
||||||
(BOOL)SendMessage32A((hwndTV), TVM_GETISEARCHSTRING, 0, \
|
(BOOL32)SendMessage32A((hwndTV), TVM_GETISEARCHSTRING, 0, \
|
||||||
(LPARAM)(LPTSTR)lpsz)
|
(LPARAM)(LPTSTR)lpsz)
|
||||||
|
|
||||||
#define TreeView_SetItemHeight(hwnd, iHeight) \
|
#define TreeView_SetItemHeight(hwnd, iHeight) \
|
||||||
(INT32)SendMessage32A((hwnd), TVM_SETITEMHEIGHT, (WPARAM)iHeight, 0)
|
(INT32)SendMessage32A((hwnd), TVM_SETITEMHEIGHT, (WPARAM32)iHeight, 0)
|
||||||
#define TreeView_GetItemHeight(hwnd) \
|
#define TreeView_GetItemHeight(hwnd) \
|
||||||
(INT32)SendMessage32A((hwnd), TVM_GETITEMHEIGHT, 0, 0)
|
(INT32)SendMessage32A((hwnd), TVM_GETITEMHEIGHT, 0, 0)
|
||||||
|
|
||||||
|
@ -2679,6 +2733,7 @@ typedef struct tagNMIPADDRESS
|
||||||
* Property sheet support (callback procs)
|
* Property sheet support (callback procs)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#define WC_PROPSHEET32A "SysPropertySheet"
|
#define WC_PROPSHEET32A "SysPropertySheet"
|
||||||
#define WC_PROPSHEET32W L"SysPropertySheet"
|
#define WC_PROPSHEET32W L"SysPropertySheet"
|
||||||
#define WC_PROPSHEET WINELIB_NAME_AW(WC_PROPSHEET)
|
#define WC_PROPSHEET WINELIB_NAME_AW(WC_PROPSHEET)
|
||||||
|
|
Loading…
Reference in New Issue