--- /dev/null
+#include "EXTERN.h"
+#include "perl.h"
+#include "XSUB.h"
+
+#ifndef aTHX_
+#define aTHX_
+#endif
+
+#include <SDL.h>
+
+MODULE = SDL::ActiveEvent PACKAGE = SDL::ActiveEvent PREFIX = aevent_
+
+=for documentation
+
+SDL_ActiveEvent -- Application visibility event structure
+
+ typedef union{
+ Uint8 type;
+ Uint8 gain;
+ Uint8 state;
+ } SDL_Event;
+
+
+=cut
+
+Uint8
+aevent_type ( event, ... )
+ SDL_ActiveEvent *event
+ CODE:
+ RETVAL = event->type;
+ OUTPUT:
+ RETVAL
+
+
+Uint8
+aevent_gain ( event, ... )
+ SDL_ActiveEvent *event
+ CODE:
+ RETVAL = event->gain;
+ OUTPUT:
+ RETVAL
+
+Uint8
+aevent_state ( event, ... )
+ SDL_ActiveEvent *event
+ CODE:
+ RETVAL = event->state;
+ OUTPUT:
+ RETVAL
--- /dev/null
+#include "EXTERN.h"
+#include "perl.h"
+#include "XSUB.h"
+
+#ifndef aTHX_
+#define aTHX_
+#endif
+
+#include <SDL.h>
+
+MODULE = SDL::Event PACKAGE = SDL::Rect PREFIX = event_
+
+=for documentation
+
+SDL_Event -- General event structure
+
+ typedef union{
+ Uint8 type;
+ SDL_ActiveEvent active;
+ SDL_KeyboardEvent key;
+ SDL_MouseMotionEvent motion;
+ SDL_MouseButtonEvent button;
+ SDL_JoyAxisEvent jaxis;
+ SDL_JoyBallEvent jball;
+ SDL_JoyHatEvent jhat;
+ SDL_JoyButtonEvent jbutton;
+ SDL_ResizeEvent resize;
+ SDL_ExposeEvent expose;
+ SDL_QuitEvent quit;
+ SDL_UserEvent user;
+ SDL_SysWMEvent syswm;
+ } SDL_Event;
+
+
+=cut
+
+SDL_Event *
+event_new (CLASS)
+ char* CLASS
+ CODE:
+ SDL_Event* empty_event;
+ RETVAL = empty_event;
+ OUTPUT:
+ RETVAL
+
+Uint8
+event_type ( event, ... )
+ SDL_Event *event
+ CODE:
+ RETVAL = NULL;
+ if ( &event != NULL )
+ RETVAL = event->type;
+ OUTPUT:
+ RETVAL
+
+SDL_ActiveEvent *
+event_active ( event, ... )
+ SDL_Event *event
+ CODE:
+ RETVAL = NULL;
+ if ( &event != NULL )
+ RETVAL = &(event->active);
+ OUTPUT:
+ RETVAL
+
+