Listview mousewheel fix
Rein Klazes
rklazes at xs4all.nl
Tue Oct 29 11:33:50 CST 2002
Hi,
(cc'd to Dimitri)
Make wheelmouse work again.
Changelog:
dlls/comctl32/ : listview.c
Fix for listview wheelmouse message handling.
Rein.
--
Rein Klazes
rklazes at xs4all.nl
-------------- next part --------------
--- wine/dlls/comctl32/listview.c 2002-10-29 13:37:51.000000000 +0100
+++ mywine/dlls/comctl32/listview.c 2002-10-29 17:34:28.000000000 +0100
@@ -7325,22 +7325,16 @@
* listview should be scrolled by a multiple of 37 dependently on its dimension or its visible item number
* should be fixed in the future.
*/
- if (GetScrollInfo(infoPtr->hwndSelf, SB_VERT, &scrollInfo))
- LISTVIEW_VScroll(infoPtr, SB_THUMBPOSITION,
- scrollInfo.nPos + (gcWheelDelta < 0) ?
- LISTVIEW_SCROLL_ICON_LINE_SIZE :
- -LISTVIEW_SCROLL_ICON_LINE_SIZE, 0);
+ LISTVIEW_VScroll(infoPtr, SB_INTERNAL, (gcWheelDelta < 0) ?
+ LISTVIEW_SCROLL_ICON_LINE_SIZE : -LISTVIEW_SCROLL_ICON_LINE_SIZE, 0);
break;
case LVS_REPORT:
if (abs(gcWheelDelta) >= WHEEL_DELTA && pulScrollLines)
{
- if (GetScrollInfo(infoPtr->hwndSelf, SB_VERT, &scrollInfo))
- {
- int cLineScroll = min(LISTVIEW_GetCountPerColumn(infoPtr), pulScrollLines);
- cLineScroll *= (gcWheelDelta / WHEEL_DELTA);
- LISTVIEW_VScroll(infoPtr, SB_THUMBPOSITION, scrollInfo.nPos + cLineScroll, 0);
- }
+ int cLineScroll = min(LISTVIEW_GetCountPerColumn(infoPtr), pulScrollLines);
+ cLineScroll *= (gcWheelDelta / WHEEL_DELTA);
+ LISTVIEW_VScroll(infoPtr, SB_INTERNAL, cLineScroll, 0);
}
break;
More information about the wine-patches
mailing list