Index: trunk/src/lib/shell/shell.cc
===================================================================
--- trunk/src/lib/shell/shell.cc	(revision 5179)
+++ trunk/src/lib/shell/shell.cc	(revision 5180)
@@ -58,6 +58,4 @@
   // INPUT LINE
   this->shellInput = new ShellInput;
-  this->delayed = 0;
-  this->shellInput->setRepeatDelay(.3, .05);
   //this->commandList = new tList<ShellCommand>;
 
@@ -65,9 +63,7 @@
   this->completionList = NULL;
 
-  // EVENT-Handler subscription of '`' to all States, and all other keyboard commands to ES_SEHLL
-  EventHandler* evh = EventHandler::getInstance();
-  evh->subscribe(this, ES_ALL, SDLK_BACKQUOTE);
-  for (int i = 1; i < SDLK_LAST; i++)
-    evh->subscribe(this, ES_SHELL, i);
+  // EVENT-Handler subscription of '`' to all States.
+  EventHandler::getInstance()->subscribe(this, ES_ALL, SDLK_BACKQUOTE);
+
 }
 
@@ -85,4 +81,5 @@
 
   // delete the inputLine
+  delete this->shellInput;
 
   Shell::singletonRef = NULL;
@@ -250,5 +247,4 @@
   if (event.bPressed)
   {
-    PRINTF(5)("Shell received command %s\n", SDLKToKeyname(event.type));
     if (event.type == SDLK_BACKQUOTE)
     {
@@ -258,79 +254,7 @@
         this->deactivate();
     }
-    else if (event.type == SDLK_F1)
-      this->help();
-    else if (event.type == SDLK_F2)
-      this->debug();
-    else if (event.type == SDLK_TAB)
-      ;//this->autoComplete();
-    else if (event.type == SDLK_BACKSPACE)
-    {
-      this->delayed = this->repeatDelay;
-      this->pressedKey = SDLK_BACKSPACE;
-      this->shellInput->removeCharacters(1);
-    }
-    else if (event.type == SDLK_RETURN)
-      this->shellInput->executeCommand();
-    /*
-    else if (event.type == SDLK_UP)
-    {
-//      this->flushInputLine();
-      tIterator<char>* iterator = this->commandList->getIterator();
-      char* command = iterator->lastElement();
-      while (command)
-      {
-        if (!strcmp (command, inputLine))
-        {
-          inputLine = iterator->prevElement();
-          return;
-        }
-        command = iterator->prevElement();
-      }
-      inputLine = iterator->lastElement();
-    }
-    */
-    else if (likely(event.type < 127))
-    {
-      Uint8 *keystate = SDL_GetKeyState(NULL);
-      this->delayed = this->repeatDelay;
-      if (unlikely( keystate[SDLK_LSHIFT] || keystate[SDLK_RSHIFT] ))
-      {
-        this->pressedKey = event.type-32;
-        this->shellInput->addCharacter(event.type-32);
-      }
-      else
-      {
-        this->pressedKey = event.type;
-        this->shellInput->addCharacter(event.type);
-      }
-    }
   }
-  else // if(!event.bPressed)
-  {
-    if (this->pressedKey == event.type || (this->pressedKey == event.type - 32))
-    {
-      this->pressedKey = SDLK_FIRST;
-      this->delayed = 0.0;
-    }
-  }
-}
-
-/**
- * ticks the Shell for dt Seconds
- * @param dt the elapsed time since the last tick();
- */
-void Shell::tick(float dt)
-{
-  if (this->delayed > 0.0)
-    this->delayed -= dt;
-  else if (this->pressedKey != SDLK_FIRST )
-  {
-    this->delayed = this->repeatRate;
-    if (this->pressedKey == SDLK_BACKSPACE)
-      this->shellInput->removeCharacters(1);
-    else if (pressedKey < 127)
-      this->shellInput->addCharacter(this->pressedKey);
-  }
-}
+}
+
 /**
  * displays the Shell
@@ -365,17 +289,4 @@
 }
 
-/**
- * prints out some nice help about the Shell
- */
-void Shell::help() const
-{
-  PRINT(0)("Help for the most important Shell-commands\n");
-  PRINT(0)("F1 - HELP; F2 - DEBUG; ` - open/close shell\n");
-  PRINT(0)("input order:\n");
-  PRINT(0)("ClassName::objectName function [parameter1, [parameter2 ...]]  or\n");
-  PRINT(0)("Command [parameter]\n");
-}
-
-
 ///////////////////////
 // HELPER FUNCTIONS  //
@@ -401,6 +312,6 @@
   PRINT(3)("Debugging output to console (not this shell)\n");
 
-  if (this->pressedKey != SDLK_FIRST)
-    printf("%s::%f %f\n", SDLKToKeyname(this->pressedKey), this->delayed, this->repeatDelay);
+//   if (this->pressedKey != SDLK_FIRST)
+//     printf("%s::%f %f\n", SDLKToKeyname(this->pressedKey), this->delayed, this->repeatDelay);
 
 
