| Home >> All >> org >> libsdl >> [ event Javadoc ] |
org.libsdl.event: Javadoc index of package org.libsdl.event.
Package Samples:
org.libsdl.event
Classes:
SDLEventManager: The SDLEventManager class encompasses the ability to receive events, either by polling or waiting. Most of the event related SDL functions can be found here, such as SDL_WaitEvent, SDL_PumpEvents, and SDL_PollEvent (to name a few). ------ EXAMPLE ------ SDL sdl = SDL.getInstance(); sdl.init(SDL.SDL_INIT_EVERYTHING); SDLEventManager eventManager = sdl.getEventManager(); SDLEvent event = null; while ( (event = eventManager.waitEvent()) != null ) { if (event instanceOf SDLMouseButtonEvent) { // do something } else if (event instanceOf SDLKeyboardEvent) { // do something else } // etc... }
SDLEvent: The SDLEvent represents a single SDL event. All specific event classes extend this class. There are two ways to determine what kind of event this is. The first is to use introspection (instanceof) to determine the type of the object. The second is to use the getType() method below.
SDLCursor: The SDLCursor represents an SDL cursor. This class is then passed to SDLEventManager.setCursor() method to set the current cursor for the screen. Note that this class supplies a standard error cursor.
SDLQuitEvent: The SDLQuitEvent represents a user quit event. When the user closes the window, for example, this event will occur.
SDLJoyBallEvent: The SDLJoyBallEvent represents a joystick trackball motion event.
SDLActiveEvent: The SDLActiveEvent represents an application visibility event.
SDLJoyAxisEvent: The SDLJoyAxisEvent represents a joystick axis motion event.
SDLJoyHatEvent: The SDLJoyHatEvent represents a joystick hat position event.
SDLMouseState: The SDLMouseState represents a snapshot of the mouse state.
SDLJoyButtonEvent: The SDLJoyButtonEvent represents a joystick button event.
SDLMouseButtonEvent: The SDLMouseButtonEvent represents a mouse button event.
SDLMouseMotionEvent: The SDLMouseMotionEvent represents a mouse motion event.
SDLResizeEvent: The SDLResizeEvent represents a window resize event.
SDLSywWMEvent: The SDLSywWMEvent represents a window manager event.
SDLKeyboardEvent: The SDLKeyboardEvent represents a keyboard event.
SDLUserEvent: The SDLUserEvent represents a user defined event.
SDLKey
SDLKeySym
SDLMod
| Home | Contact Us | Privacy Policy | Terms of Service |