Fixed #206 - disabled key repeat.

This commit is contained in:
yvt 2014-03-24 23:52:07 +09:00
parent 27da8c5ffb
commit f8f09593e8

View File

@ -154,8 +154,9 @@ namespace spades {
view->WheelEvent(-event.wheel.x, -event.wheel.y);
break;
case SDL_KEYDOWN:
view->KeyEvent(TranslateKey(event.key.keysym),
true);
if(!event.key.repeat)
view->KeyEvent(TranslateKey(event.key.keysym),
true);
break;
case SDL_KEYUP:
view->KeyEvent(TranslateKey(event.key.keysym),