v2026.6.4
All Bundles
Bundle SDL2 multimedia library for 2D graphics, input handling, audio playback, and window management. Core types: Window, Renderer, Texture, Surface, Event, and Mixer. Compile with -lib sdl2.

MouseWheelEvent

Mouse wheel event

Operations

GetDirection #

Mouse wheel scroll direction

method : public : GetDirection() ~ MouseWheelDirection

Return

TypeDescription
MouseWheelDirectionSDL_MOUSEWHEEL_NORMAL or SDL_MOUSEWHEEL_FLIPPED

GetTimestamp #

Timestamp of the event

method : public : GetTimestamp() ~ Int

Return

TypeDescription
Intevent timestamp

GetType #

Event type

method : public : GetType() ~ Int

Return

TypeDescription
IntEventType->SDL_MOUSEWHEEL

GetWhich #

Mouse instance id or -1

method : public : GetWhich() ~ Int

GetWindowID #

Window with mouse focus, if any

method : public : GetWindowID() ~ Int

Return

TypeDescription
Intwindow ID

GetX #

Amount scrolled horizontally, positive to the right and negative to the left

method : public : GetX() ~ Int

Return

TypeDescription
Inthorizontally scrolled value

GetY #

Amount scrolled vertically, positive away from the user and negative toward the user

method : public : GetY() ~ Int

Return

TypeDescription
Intvertically scrolled value