Mercurial > hg > dmlib
changeset 275:26d714c72c0f
Cleanups.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 10 Oct 2012 21:23:18 +0300 |
parents | 31e62b1f1b6e |
children | 40efff364904 |
files | ppl.c |
diffstat | 1 files changed, 5 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ppl.c Wed Oct 10 21:23:09 2012 +0300 +++ b/ppl.c Wed Oct 10 21:23:18 2012 +0300 @@ -720,9 +720,12 @@ SDL_WM_SetCaption(dmProgDesc, dmProgName); + SDL_EnableKeyRepeat(SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL); + // okay, main loop here ... "play" module and print out info + SDL_LockAudio(); SDL_PauseAudio(0); - SDL_EnableKeyRepeat(SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL); + SDL_UnlockAudio(); int currTick, prevTick = 0, prevRow = -1; @@ -891,12 +894,11 @@ } error_exit: - SDL_PauseAudio(1); - if (engine.screen) SDL_FreeSurface(engine.screen); SDL_LockAudio(); + SDL_PauseAudio(1); jmpClose(engine.plr); jvmClose(engine.dev); jssFreeModule(engine.mod);