|
Size: 1492
Comment: minor change for consistency
|
Size: 1586
Comment: update content for consistency - callback (table); camelcase
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 2: | Line 2: |
| #pragma disable-camelcase | #pragma camelcase off |
| Line 17: | Line 17: |
| ||'''filter'''||^a pointer to fill in with the function to call when an event happens^ ???|| ||'''userdata'''||^a pointer to a pointer filled in with user-specified data^|| |
||'''filter'''||the callback function to get; see [[#Remarks|Remarks]] for details|| ||'''userdata'''||a pointer to a pointer that is passed to '''filter'''|| |
| Line 21: | Line 21: |
| Returns the current event filter. If there is no event filter set, this function returns SDL_FALSE. | Returns SDL_TRUE on success or SDL_FALSE if there is no event filter set,,; call [[SDL_GetError]]() for more information.,, |
| Line 23: | Line 23: |
| <<Color2(green,Does it return SDL_TRUE if there is a filter or does it return other text describing the filter?)>> | <<Color2(green,The header says it "Returns the current event filter" but I suspect this isn't referring to the actual return value but the output of the function. Should that be included here?)>> |
| Line 31: | Line 31: |
| Can be used to "chain" filters. | This function can be used to "chain" filters. |
| Line 33: | Line 33: |
| *<<BR>><<Color2(green,This functions appears to have changed dramatically since 1.2. Is that correct?)>><<BR>>* <<Color2(green,Should the following be included here as it is in [[SDL_SetEventFilter]]()?)>> The '''filter''' function has the following form: |
<<Color2(green,Should the following be included here as it is in [[SDL_SetEventFilter]]()? Right now this is different.)>> The function prototype for '''filter''' is: |
| Line 38: | Line 36: |
| int SDL_EventFilter(void* userdata, SDL_Event* event) | int SDL_EventFilter(void* userdata, SDL_Event* event) |
| Line 40: | Line 39: |
| where '''userdata''' is the event queue to filter and '''event''' is the desired event to pull from the queue. | . where its parameters are: ||`userdata`||what was passed as '''userdata''' to [[SDL_GetEventFilter]]()|| ||`event`||the desired event to query from the queue ???|| |
DRAFT |
SDL_GetEventFilter
Use this function to return the current event filter.
Contents
Syntax
SDL_bool SDL_GetEventFilter(SDL_EventFilter* filter,
void** userdata)
Function Parameters
filter |
the callback function to get; see Remarks for details |
userdata |
a pointer to a pointer that is passed to filter |
Return Value
Returns SDL_TRUE on success or SDL_FALSE if there is no event filter set; call [[SDL_GetError]]() for more information.
green
Code Examples
You can add your code example here
Remarks
This function can be used to "chain" filters.
green
The function prototype for filter is:
int SDL_EventFilter(void* userdata, SDL_Event* event)- where its parameters are:
userdata
what was passed as userdata to SDL_GetEventFilter()
event
the desired event to query from the queue ???
