logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

SDL_MouseButtonEvent - Mouse button event structure (event.button.*)

Availability

       This struct is available since SDL 3.2.0.

Simple Directmedia Layer                           SDL 3.2.10                        SDL_MouseButtonEvent(3type)

Header File

       Defined in SDL3/SDL_events.h

Name

       SDL_MouseButtonEvent - Mouse button event structure (event.button.*)

Synopsis

#include"SDL3/SDL.h"typedefstructSDL_MouseButtonEvent{SDL_EventTypetype;/**<SDL_EVENT_MOUSE_BUTTON_DOWNorSDL_EVENT_MOUSE_BUTTON_UP*/Uint32reserved;Uint64timestamp;/**<Innanoseconds,populatedusingSDL_GetTicksNS()*/SDL_WindowIDwindowID;/**<Thewindowwithmousefocus,ifany*/SDL_MouseIDwhich;/**<Themouseinstanceidinrelativemode,SDL_TOUCH_MOUSEIDfortouchevents,or0*/Uint8button;/**<Themousebuttonindex*/booldown;/**<trueifthebuttonispressed*/Uint8clicks;/**<1forsingle-click,2fordouble-click,etc.*/Uint8padding;floatx;/**<Xcoordinate,relativetowindow*/floaty;/**<Ycoordinate,relativetowindow*/}SDL_MouseButtonEvent;

See Also