EnableKeyRepeat while console is open.
authorWolfgang Becker <uafr@gmx.de>
Wed, 7 Jun 2006 20:53:19 +0000 (20:53 +0000)
committerWolfgang Becker <uafr@gmx.de>
Wed, 7 Jun 2006 20:53:19 +0000 (20:53 +0000)
SVN-Revision: 3638

src/console.cpp

index fba096f..cc88905 100644 (file)
@@ -420,6 +420,7 @@ Console::show()
   focused = true;
   height = 256;
   alpha = 1.0;
+  SDL_EnableKeyRepeat(SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL);
 }
 
 void 
@@ -431,6 +432,7 @@ Console::hide()
 
   // clear input buffer
   inputBuffer.str(std::string());
+  SDL_EnableKeyRepeat(0, SDL_DEFAULT_REPEAT_INTERVAL);
 }
 
 void