Commit Graph

68 Commits

Author SHA1 Message Date
Sam Lantinga
9c4c023744 Removed the SDL 1.2 compatibility API... we'll see how painful this is. 2012-01-22 18:11:41 -05:00
Sam Lantinga
e256711bb9 Happy New Year! 2011-12-31 09:28:07 -05:00
Sam Lantinga
4ec39d8333 Fixed bug 1336 - Added a timestamp on all SDL events
Gueniffey 2011-11-23 04:11:31 PST

The attached simple patch adds a timestamp to all SDL events. It is useful to
dismiss old events and add UI responsiveness (my application does some
extensive tasks that creates a delay in the event queue handling. With this
patch, I can deal only with the most recent events.
2011-12-29 05:13:55 -05:00
Sam Lantinga
79494aee9d First pass at a simple drag and drop API, allowing you to accept files dropped into your application. 2011-11-20 19:38:18 -05:00
Sam Lantinga
76714d4f99 Fixed a typo in the header. 2011-11-07 02:25:01 -05:00
Sam Lantinga
6196aa221e SDL 1.3 is now under the zlib license. 2011-04-08 13:03:26 -07:00
Sam Lantinga
a2cdcf5486 Happy 2011! :) 2011-02-11 22:37:15 -08:00
Sam Lantinga
23370c8928 Sheena pointed out that "scancode" and "keysym" are single words and shouldn't be camel-cased. 2011-02-07 09:37:11 -08:00
Sam Lantinga
5978f70063 Added functions to watch events as they go through the event queue. 2011-02-01 19:15:42 -08:00
krogoway
d35de7167f Renamed SDL_keysym to SDL_KeySym
Renamed SDL_scancode to SDL_ScanCode
Added #defines to SDL_compat.h
2011-01-24 13:47:35 -06:00
Sam Lantinga
f5bbe15139 Fixed compiler error 2011-01-17 14:05:14 -08:00
Sam Lantinga
9017f24006 Minor documentation consistency cleanup 2011-01-17 09:09:15 -08:00
Sam Lantinga
036154b8c0 Fixed spacing in comments 2011-01-12 11:55:02 -08:00
Sam Lantinga
15e43076a4 Updated headers to match wiki documentation 2011-01-12 09:47:33 -08:00
Sam Lantinga
7f6ad8e572 Merged Jim's Google Summer of Code work from SDL-gsoc2010_gesture 2010-08-22 12:07:55 -07:00
Jim Grandpre
e9d12a479a Added README.touch and README.gesture. Moved touchtest/gestureSDLTest to test/testgesture 2010-08-15 00:36:28 -04:00
Sam Lantinga
0f67a475f9 Fixed documentation error 2010-08-14 12:28:43 -07:00
Jim Grandpre
db352f3b39 Fixed gestureMulti. Disabled dollar gesture temporarily. 2010-08-04 23:17:30 -04:00
jimtla
05c264c774 Added SDL_TouchID, SDL_FingerID, SDL_GestureID types. Converted to integer cioordinates (<- not working). 2010-07-31 20:02:54 +04:00
jimtla
214939549f Upgraded touchId/fingerId to long. Changed position variables to floats. 2010-07-30 23:18:35 +04:00
Sam Lantinga
741880b4dc Added support for keyboard repeat (only tested on Windows so far) 2010-07-20 23:25:24 -07:00
Jim Grandpre
4b707013d1 Added alternative finger tracking method. Still prefer IPHONE_TOUCH_EFFICIENT_DANGEROUS. 2010-07-13 18:31:09 -04:00
Sam Lantinga
6f2000e6d2 Merged changes from the main SDL codebase 2010-07-12 21:09:23 -07:00
Jim Grandpre
9e7603a6ba Added some files I had previosuly missed 2010-07-11 01:15:39 -04:00
Jim Grandpre
bdbb130028 Moved $1 Gestures into the SDL Library 2010-07-09 00:50:40 -07:00
Sam Lantinga
ddf0465549 Added an event when the clipboard is updated, triggered after the window gains the keyboard focus. 2010-07-08 22:54:03 -07:00
Jim Grandpre
9d8bd2bcf5 Moved Multi finger gesture recognition into the library. 2010-07-07 04:13:08 -07:00
Jim Grandpre
80ecbb9011 Added pressure support for touch events. 2010-05-29 02:09:16 -04:00
Jim Grandpre
a1401afe42 Added reading of event* for touch events. 2010-05-28 01:26:52 -04:00
Jim Grandpre
4a3ed7b859 Added touch event definitions. Heavily modified events/SDL_touch*. 2010-05-27 01:21:37 -04:00
Sam Lantinga
4b1c945432 Removed multi-mouse / multi-keyboard support in anticipation of a real multi-mouse and multi-touch API.
Plus, this lets me start implementing cursor support.
2010-05-09 20:47:22 -07:00
Sam Lantinga
6c556c1780 Minor cleanup on Jiang's patch 2010-04-15 22:27:01 -07:00
Sam Lantinga
b87ae3913b changeset: 4433:25667ea797fa
tag: tip
user: Jiang Jiang <gzjjgod@gmail.com>
date: Thu Apr 15 12:01:46 2010 +0800
summary: Add windowID to text editing event
2010-04-15 22:14:26 -07:00
Sam Lantinga
b0847f3de2 General improvements for user custom event registration
* Switched event type to enum (int32)
* Switched polling by mask to polling by type range
* Added SDL_RegisterEvents() to allow dynamic user event registration
* Spread events out to allow inserting new related events without breaking binary compatibility
* Added padding to event structures so they're the same size regardless of 32-bit compiler structure packing settings
* Split SDL_HasEvent() to SDL_HasEvent() for a single event and SDL_HasEvents() for a range of events
* Added SDL_GetEventState() as a shortcut for SDL_EventState(X, SDL_QUERY)
* Added SDL_FlushEvent() and SDL_FlushEvents() to clear events from the event queue
2010-03-25 01:08:26 -07:00
Sam Lantinga
7052036491 Fixed bug #926
Updated copyright to LGPL version 2.1 and year 2010
2010-01-24 21:10:53 +00:00
Sam Lantinga
e0a31b4dbb Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance. 2010-01-21 06:21:52 +00:00
Sam Lantinga
fbcae020cf Fixed bug #642
Gerry JJ      2008-11-09 02:11:49 PST

The SDL_MouseMotionEvent struct has a field named "tilt" (currently marked "for
future use"), for tablet stylus tilt information.  However, one value is not
enough for this, as tilt is two-dimensional.  Reserving only one field for
future use is no good when you're going to need two, so there should be two
fields, tilt_x and tilt_y.
2009-12-16 00:44:53 +00:00
Sam Lantinga
27294b7a4e Partial fix for bug #859
Header file update from Ken for improved doxygen output
2009-10-19 13:31:58 +00:00
Sam Lantinga
95c8f7a517 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009 2009-09-19 13:29:40 +00:00
Sam Lantinga
dd18a26edd Fixed bug #750
Since many different event structures include windowID it should be placed near
the beginning of the structure (preferably right after type) so it's position
is the same between different events.

This is to avoid code like this:
if (event.type == SDL_WINDOWEVENT)
    win = event.window.windowID;
else if ((SDL_EVENTMASK(event.type) & SDL_KEYEVENTMASK) != 0)
    win = event.key.windowID;
else if (event.type == SDL_TEXTINPUT)
    win = event.text.windowID;
else if (event.type == SDL_MOUSEMOTION)
    win = event.motion.windowID;
else if ((SDL_EVENTMASK(event.type) & (SDL_MOUBUTTONDOWNMASK |
SDL_MOUBUTTONUPMASK)) != 0)
    win = event.button.windowID;
else if (event.type == SDL_MOUSEWHEEL)
    win = event.wheel.windowID;
...

in favor of:
win = event.window.windowID;
2009-06-10 14:00:21 +00:00
Bob Pendleton
0a28ca5681 Added a #ifndef SDL_NO_COMPAT around SDL_ActiveEvent and SDL_ResizeEvent so that code
that has a #defien SDL_NO_COMPAT before the #include SDL.h with not be able to use
these obsolete events.
2009-06-05 23:36:00 +00:00
Sam Lantinga
a59d71fd7e Fixed bug #684
Reworked Pierre's patch a little bit, which added SDL_WaitEventTimeout()
2009-02-17 05:59:40 +00:00
Sam Lantinga
befb0f7f42 Updated copyright date 2008-12-08 00:27:32 +00:00
Sam Lantinga
474cfaad1e Final merge of Google Summer of Code 2008 work...
Many-mouse and tablet support
by Szymon Wilczek, mentored by Ryan C. Gordon

Everything concerning the project is noted on the wiki:
http://wilku.ravenlord.ws/doku.php?id=start
2008-08-25 06:33:00 +00:00
Bob Pendleton
16c4fcc95c Minimal implementation of textinput events for x11. It only works for latin-1. 2008-01-15 22:37:17 +00:00
Sam Lantinga
49c02d670f Fixed bug #382
Added horizontal scrolling support
2007-07-06 09:22:18 +00:00
Bob Pendleton
613ad2c0d5 Added a WindowID to the user event and cleaned up a little bit of formating 2007-06-20 00:01:04 +00:00
Sam Lantinga
9617df5b60 Implemented Cocoa mouse wheel events 2006-07-29 22:42:48 +00:00
Sam Lantinga
dcd15904cd Added a test program framework for easy initialization.
Started work on multi-window OpenGL demo
2006-07-18 07:49:51 +00:00
Sam Lantinga
6bc598ea61 SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head. 2006-07-10 21:04:37 +00:00