diff --git a/intern/ghost/intern/GHOST_SystemWin32.cpp b/intern/ghost/intern/GHOST_SystemWin32.cpp index ec6d0d355b5..835f7da3038 100644 --- a/intern/ghost/intern/GHOST_SystemWin32.cpp +++ b/intern/ghost/intern/GHOST_SystemWin32.cpp @@ -54,7 +54,7 @@ #define WM_MOUSEWHEEL 0x020A #endif // WM_MOUSEWHEEL #ifndef WHEEL_DELTA -#define WHEEL_DELTA 120 /* Value for rolling one detent */ +#define WHEEL_DELTA 120 /* Value for rolling one detent, (old convention! MS changed it) */ #endif // WHEEL_DELTA @@ -479,7 +479,11 @@ GHOST_EventWheel* GHOST_SystemWin32::processWheelEvent(GHOST_IWindow *window, WP { // short fwKeys = LOWORD(wParam); // key flags int zDelta = (short) HIWORD(wParam); // wheel rotation - zDelta /= WHEEL_DELTA; + + // zDelta /= WHEEL_DELTA; + // temporary fix below: microsoft now has added more precision, making the above division not work + if (zDelta <= 0 ) zDelta= -1; else zDelta= 1; + // short xPos = (short) LOWORD(lParam); // horizontal position of pointer // short yPos = (short) HIWORD(lParam); // vertical position of pointer return new GHOST_EventWheel (getSystem()->getMilliSeconds(), window, zDelta);