TREEVIEW_DoSelectItem should not do TVGN_FIRSTVISIBLE work if
selected item is NULL
Evan Deaubl
wine at warpedview.com
Sun Mar 13 12:19:15 CST 2005
ChangeLog:
* TREEVIEW_DoSelectItem should not do any of the TVGN_FIRSTVISIBLE work if the newSelect parameter is NULL
--- wine-20050310/dlls/comctl32/treeview.c 2005-02-22 12:31:01.000000000 -0
700
+++ wine-20050310.new/dlls/comctl32/treeview.c 2005-03-13 11:05:05.940619648 -0
700
@@ -4242,9 +4242,12 @@
break;
case TVGN_FIRSTVISIBLE:
- TREEVIEW_EnsureVisible(infoPtr, newSelect, FALSE);
- TREEVIEW_SetFirstVisible(infoPtr, newSelect, TRUE);
- TREEVIEW_Invalidate(infoPtr, NULL);
+ if (newSelect != NULL)
+ {
+ TREEVIEW_EnsureVisible(infoPtr, newSelect, FALSE);
+ TREEVIEW_SetFirstVisible(infoPtr, newSelect, TRUE);
+ TREEVIEW_Invalidate(infoPtr, NULL);
+ }
break;
}
More information about the wine-patches
mailing list