Commit 02300aea authored by Sylvain St.Germain's avatar Sylvain St.Germain Committed by Alexandre Julliard

Fixed some graphical problems of the treeview and added support LMB

click on +/- sign to open and close. Fixed a bug in imagelist where the last image could not be displayed.
parent 6d45e7a9
...@@ -894,7 +894,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) ...@@ -894,7 +894,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
return FALSE; return FALSE;
if (pimldp->himl == NULL) if (pimldp->himl == NULL)
return FALSE; return FALSE;
if ((pimldp->i < 0) || (pimldp->i >= pimldp->himl->cCurImage)) if ((pimldp->i < 0) || (pimldp->i > pimldp->himl->cCurImage))
return FALSE; return FALSE;
himlLocal = pimldp->himl; himlLocal = pimldp->himl;
......
...@@ -30,7 +30,6 @@ typedef struct { ...@@ -30,7 +30,6 @@ typedef struct {
int iIntegral; int iIntegral;
int iLevel; /* indentation level:0=root level */ int iLevel; /* indentation level:0=root level */
COLORREF clrText; COLORREF clrText;
HTREEITEM parent; /* handle to parent or 0 if at root*/ HTREEITEM parent; /* handle to parent or 0 if at root*/
HTREEITEM firstChild; /* handle to first child or 0 if no child*/ HTREEITEM firstChild; /* handle to first child or 0 if no child*/
HTREEITEM sibling; /* handle to next item in list, 0 if last */ HTREEITEM sibling; /* handle to next item in list, 0 if last */
...@@ -38,10 +37,10 @@ typedef struct { ...@@ -38,10 +37,10 @@ typedef struct {
int visible; int visible;
RECT rect; RECT rect;
RECT text; RECT text;
RECT expandBox; /* expand box (+/-) coordinate */
} TREEVIEW_ITEM; } TREEVIEW_ITEM;
typedef struct tagTREEVIEW_INFO typedef struct tagTREEVIEW_INFO
{ {
UINT uInternalStatus; UINT uInternalStatus;
...@@ -52,9 +51,8 @@ typedef struct tagTREEVIEW_INFO ...@@ -52,9 +51,8 @@ typedef struct tagTREEVIEW_INFO
HTREEITEM uMaxHandle; /* needed for delete_item */ HTREEITEM uMaxHandle; /* needed for delete_item */
HTREEITEM TopRootItem; /* handle to first item in treeview */ HTREEITEM TopRootItem; /* handle to first item in treeview */
INT cdmode; /* last custom draw setting */ INT cdmode; /* last custom draw setting */
UINT uItemHeight; /* item height, -1 for default item height */ UINT uItemHeight; /* item height, -1 for default item height */
UINT uRealItemHeight; /* current item height in pixels */ UINT uRealItemHeight;/* current item height in pixels */
UINT uVisibleHeight; /* visible height of treeview in pixels */ UINT uVisibleHeight; /* visible height of treeview in pixels */
UINT uTotalHeight; /* total height of treeview in pixels */ UINT uTotalHeight; /* total height of treeview in pixels */
UINT uVisibleWidth; UINT uVisibleWidth;
...@@ -75,14 +73,12 @@ typedef struct tagTREEVIEW_INFO ...@@ -75,14 +73,12 @@ typedef struct tagTREEVIEW_INFO
HWND hwndToolTip; HWND hwndToolTip;
HWND hwndEdit; HWND hwndEdit;
WNDPROC wpEditOrig; /* needed for subclassing edit control */ WNDPROC wpEditOrig; /* needed for subclassing edit control */
HIMAGELIST himlNormal; HIMAGELIST himlNormal;
HIMAGELIST himlState; HIMAGELIST himlState;
TREEVIEW_ITEM *items; /* itemlist */ TREEVIEW_ITEM *items; /* itemlist */
INT *freeList; /* bitmap indicating which elements are valid */ INT *freeList; /* bitmap indicating which elements are valid */
/* 1=valid, 0=free; */ /* 1=valid, 0=free; */
/* size of list= uNumPtrsAlloced/32 */ /* size of list= uNumPtrsAlloced/32 */
} TREEVIEW_INFO; } TREEVIEW_INFO;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment