or download this
oop( \%actions )
SDLx::App::loop is a simple event loop method which takes a reference
+to a hash of event handler subroutines. The keys of the hash must be
+SDL event types such as SDL_QUIT(), SDL_KEYDOWN(), and the like. When
+ called, the event method recieves as its parameter the event object
+used in the loop.
...
);
$app->loop( \%actions );