hedgewars/uKeys.pas
changeset 3038 4e48c276a468
parent 2948 3f21a9dc93d0
child 3221 3e6586c1ab4f
equal deleted inserted replaced
3037:ab6e949eb5cb 3038:4e48c276a468
    23 uses uConsts, SDLh;
    23 uses uConsts, SDLh;
    24 
    24 
    25 type TBinds = array[0..cKeyMaxIndex] of shortstring;
    25 type TBinds = array[0..cKeyMaxIndex] of shortstring;
    26 type TKeyboardState = array[0..cKeyMaxIndex] of Byte;
    26 type TKeyboardState = array[0..cKeyMaxIndex] of Byte;
    27 
    27 
    28 procedure init_uKeys;
    28 procedure initModule;
    29 procedure free_uKeys;
    29 procedure freeModule;
    30 
    30 
    31 function  KeyNameToCode(name: shortstring): word;
    31 function  KeyNameToCode(name: shortstring): word;
    32 procedure ProcessKbd;
    32 procedure ProcessKbd;
    33 procedure ResetKbd;
    33 procedure ResetKbd;
    34 procedure FreezeEnterKey;
    34 procedure FreezeEnterKey;
   486 begin
   486 begin
   487     if pressed then ControllerButtons[joy][button]:= 1
   487     if pressed then ControllerButtons[joy][button]:= 1
   488     else ControllerButtons[joy][button]:= 0;
   488     else ControllerButtons[joy][button]:= 0;
   489 end;
   489 end;
   490 
   490 
   491 procedure init_uKeys;
   491 procedure initModule;
   492 begin
   492 begin
   493     wheelUp:= false;
   493     wheelUp:= false;
   494     wheelDown:= false;
   494     wheelDown:= false;
   495 {$IFDEF IPHONEOS}
   495 {$IFDEF IPHONEOS}
   496     // this function is called by HW_allKeysUp so be careful
   496     // this function is called by HW_allKeysUp so be careful
   512     pauseAction:= false;
   512     pauseAction:= false;
   513     switchAction:= false;
   513     switchAction:= false;
   514 {$ENDIF}
   514 {$ENDIF}
   515 end;
   515 end;
   516 
   516 
   517 procedure free_uKeys;
   517 procedure freeModule;
   518 begin
   518 begin
   519 
   519 
   520 end;
   520 end;
   521 
   521 
   522 end.
   522 end.