hedgewars/hwengine.dpr
changeset 415 d6d3a6a473a3
parent 394 4c017ae1226a
child 426 7523417d84d6
equal deleted inserted replaced
414:52e6be3a0985 415:d6d3a6a473a3
   138                              gsGame: if event.key.keysym.sym = 96 then
   138                              gsGame: if event.key.keysym.sym = 96 then
   139                                         begin
   139                                         begin
   140                                         cConsoleYAdd:= cConsoleHeight;
   140                                         cConsoleYAdd:= cConsoleHeight;
   141                                         GameState:= gsConsole
   141                                         GameState:= gsConsole
   142                                         end;
   142                                         end;
   143                           gsConsole: KeyPressConsole(event.key.keysym.unicode);
   143                           gsConsole: if event.key.keysym.sym = 96 then
       
   144                                         begin
       
   145                                         GameState:= gsGame;
       
   146                                         cConsoleYAdd:= 0;
       
   147                                         ResetKbd
       
   148                                         end else KeyPressConsole(event.key.keysym.unicode);
   144                              end;
   149                              end;
   145            SDL_ACTIVEEVENT: if (event.active.state and SDL_APPINPUTFOCUS) <> 0 then
   150            SDL_ACTIVEEVENT: if (event.active.state and SDL_APPINPUTFOCUS) <> 0 then
   146                                cHasFocus:= event.active.gain = 1;
   151                                cHasFocus:= event.active.gain = 1;
   147            SDL_QUITEV: isTerminated:= true
   152            SDL_QUITEV: isTerminated:= true
   148            end;
   153            end;