debtkda.blogg.se

Sharpkeys mouse wheel down
Sharpkeys mouse wheel down










sharpkeys mouse wheel down

Otherwise, the parameters are exactly the same as for WM_MOUSEWHEEL. Note, there is no fwKeys for MSH_MOUSEWHEEL. You can also choose your scroll granularity and accumulate deltas until it is reached. To use this feature, you can either add the incoming delta values until WHEEL_DELTA is reached (so for a delta-rotation you get the same response), or scroll partial lines in response to the more frequent messages. The delta was set to 120 to allow Microsoft or other vendors to build finer-resolution wheels (a freely-rotating wheel with no notches) to send more messages per rotation, but with a smaller value in each message. This is the threshold for action to be taken, and one such action (for example, scrolling one increment) should occur for each delta. The wheel rotation will be a multiple of WHEEL_DELTA, which is set at 120. Systems with multiple monitors can have negative x- and y- coordinates, and LOWORD and HIWORD treat the coordinates as unsigned quantities. You can also use the GET_X_LPARAM or GET_Y_LPARAM macro to extract the x- or y-coordinate.ĭo not use the LOWORD or HIWORD macros to extract the x- and y- coordinates of the cursor position because these macros return incorrect results on systems with multiple monitors. If the return value is assigned to a variable, you can use the MAKEPOINTS macro to obtain a POINTS structure from the return value. Use the following code to obtain the horizontal and vertical position: xPos = GET_X_LPARAM(lParam) Īs noted above, the x-coordinate is in the low-order short of the return value the y-coordinate is in the high-order short (both represent signed values because they can take negative values on systems with multiple monitors). Use the following code to get the information in the wParam parameter: fwKeys = GET_KEYSTATE_WPARAM(wParam) If an application processes this message, it should return zero. The high-order word specifies the y-coordinate of the pointer, relative to the upper-left corner of the screen. The low-order word specifies the x-coordinate of the pointer, relative to the upper-left corner of the screen. This parameter can be one or more of the following values. The low-order word indicates whether various virtual keys are down. A positive value indicates that the wheel was rotated forward, away from the user a negative value indicates that the wheel was rotated backward, toward the user. The high-order word indicates the distance the wheel is rotated, expressed in multiples or divisions of WHEEL_DELTA, which is 120.

sharpkeys mouse wheel down

There should be no internal forwarding of the message, since DefWindowProc propagates it up the parent chain until it finds a window that processes it.Ī window receives this message through its WindowProc function. The DefWindowProc function propagates the message to the window's parent.

sharpkeys mouse wheel down

Sent to the focus window when the mouse wheel is rotated.












Sharpkeys mouse wheel down