From: Kartik Thakore Date: Sun, 8 Nov 2009 01:15:31 +0000 (-0500) Subject: Finished up JoyButtonEvent X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3737658e85e21510dd397f94d23b1018634d2389;p=sdlgit%2FSDL_perl.git Finished up JoyButtonEvent --- diff --git a/src/Core/objects/JoyButtonEvent.xs b/src/Core/objects/JoyButtonEvent.xs index 3727e81..304389d 100644 --- a/src/Core/objects/JoyButtonEvent.xs +++ b/src/Core/objects/JoyButtonEvent.xs @@ -49,6 +49,12 @@ jbevent_which ( event ) SDL_JoyButtonEvent * event CODE: + if( items > 1 ) + { + event->which = SvIV( ST(1) ); + + } + RETVAL = event->which; OUTPUT: RETVAL @@ -59,6 +65,12 @@ jbevent_button ( event ) SDL_JoyButtonEvent * event CODE: + if( items > 1 ) + { + event->button = SvIV( ST(1) ); + + } + RETVAL = event->button; OUTPUT: RETVAL @@ -69,6 +81,20 @@ jbevent_state ( event ) SDL_JoyButtonEvent * event CODE: + if( items > 1 ) + { + event->state = SvIV( ST(1) ); + + } + RETVAL = event->state; OUTPUT: RETVAL + +void +jbevent_DESTROY(self) + + SDL_JoyButtonEvent *self + + CODE: + safefree( (char *)self );