qingdoa daoo : comctl32:
Update first visible when appropiate in the TVI_SORT case.
Alexandre Julliard
julliard at wine.codeweavers.com
Sun May 7 03:36:30 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 53654c6938cc1193301ba1ae9f0d5d5781a8162d
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=53654c6938cc1193301ba1ae9f0d5d5781a8162d
Author: qingdoa daoo <qingdao33122 at yahoo.com>
Date: Tue Apr 25 11:27:29 2006 +0800
comctl32: Update first visible when appropiate in the TVI_SORT case.
---
dlls/comctl32/treeview.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/dlls/comctl32/treeview.c b/dlls/comctl32/treeview.c
index b333fa3..a6aadf5 100644
--- a/dlls/comctl32/treeview.c
+++ b/dlls/comctl32/treeview.c
@@ -1299,6 +1299,7 @@ TREEVIEW_InsertItemT(TREEVIEW_INFO *info
{
TREEVIEW_ITEM *aChild;
TREEVIEW_ITEM *previousChild = NULL;
+ TREEVIEW_ITEM *originalFirst = parentItem->firstChild;
BOOL bItemInserted = FALSE;
aChild = parentItem->firstChild;
@@ -1317,6 +1318,9 @@ TREEVIEW_InsertItemT(TREEVIEW_INFO *info
if (comp < 0) /* we are smaller than the current one */
{
TREEVIEW_InsertBefore(newItem, aChild, parentItem);
+ if (infoPtr->firstVisible == originalFirst &&
+ aChild == originalFirst)
+ TREEVIEW_SetFirstVisible(infoPtr, newItem, TRUE);
bItemInserted = TRUE;
break;
}
More information about the wine-cvs
mailing list