hedgewars/uKeys.pas
changeset 2805 36a8cebb91e8
parent 2786 85f6425a4d74
child 2905 f3c79f7193a9
equal deleted inserted replaced
2804:31c6c36c5d34 2805:36a8cebb91e8
    74 	spaceKey: boolean;
    74 	spaceKey: boolean;
    75 	enterKey: boolean;
    75 	enterKey: boolean;
    76 	tabKey: boolean;
    76 	tabKey: boolean;
    77 	
    77 	
    78 	chatAction: boolean;
    78 	chatAction: boolean;
       
    79 	pauseAction: boolean;
    79 	switchAction: boolean;
    80 	switchAction: boolean;
    80 
    81 
    81 	theJoystick: PSDL_Joystick;
    82 	theJoystick: PSDL_Joystick;
    82 	
    83 	
    83 procedure setiPhoneBinds;
    84 procedure setiPhoneBinds;
   334 DefaultBinds[23]:= '+up';
   335 DefaultBinds[23]:= '+up';
   335 DefaultBinds[24]:= '+down';
   336 DefaultBinds[24]:= '+down';
   336 DefaultBinds[25]:= '+left';
   337 DefaultBinds[25]:= '+left';
   337 DefaultBinds[26]:= '+right';
   338 DefaultBinds[26]:= '+right';
   338 DefaultBinds[44]:= 'chat';
   339 DefaultBinds[44]:= 'chat';
       
   340 DefaultBinds[55]:= 'pause';
   339 {$ELSE}
   341 {$ELSE}
   340 DefaultBinds[KeyNameToCode('up')]:= '+up';
   342 DefaultBinds[KeyNameToCode('up')]:= '+up';
   341 DefaultBinds[KeyNameToCode('down')]:= '+down';
   343 DefaultBinds[KeyNameToCode('down')]:= '+down';
   342 DefaultBinds[KeyNameToCode('left')]:= '+left';
   344 DefaultBinds[KeyNameToCode('left')]:= '+left';
   343 DefaultBinds[KeyNameToCode('right')]:= '+right';
   345 DefaultBinds[KeyNameToCode('right')]:= '+right';
   374 	tkbdn[ 9]:= ord(tabKey);
   376 	tkbdn[ 9]:= ord(tabKey);
   375 	tkbdn[13]:= ord(enterKey);
   377 	tkbdn[13]:= ord(enterKey);
   376 	tkbdn[32]:= ord(spaceKey);
   378 	tkbdn[32]:= ord(spaceKey);
   377 
   379 
   378 	tkbdn[44]:= ord(chatAction);
   380 	tkbdn[44]:= ord(chatAction);
       
   381 	tkbdn[55]:= ord(pauseAction);
   379 	//tkbdn[100]:= ord(switchAction);
   382 	//tkbdn[100]:= ord(switchAction);
   380 	
   383 	
   381 	leftClick:= false;
   384 	leftClick:= false;
   382 	middleClick:= false;
   385 	middleClick:= false;
   383 	rightClick:= false;
   386 	rightClick:= false;
   385 	tabKey:= false;
   388 	tabKey:= false;
   386 	enterKey:= false;
   389 	enterKey:= false;
   387 	backspaceKey:= false;
   390 	backspaceKey:= false;
   388 	
   391 	
   389 	chatAction:= false;
   392 	chatAction:= false;
       
   393 	pauseAction:= false;
   390 	//switchAction:= false;
   394 	//switchAction:= false;
   391 end;
   395 end;
   392 {$ENDIF}
   396 {$ENDIF}
   393 
   397 
   394 procedure FreezeEnterKey;
   398 procedure FreezeEnterKey;
   503 	spaceKey:= false;
   507 	spaceKey:= false;
   504 	enterKey:= false;
   508 	enterKey:= false;
   505 	tabKey:= false;
   509 	tabKey:= false;
   506 	
   510 	
   507 	chatAction:= false;
   511 	chatAction:= false;
       
   512 	pauseAction:= false;
   508 	switchAction:= false;
   513 	switchAction:= false;
   509 {$ENDIF}
   514 {$ENDIF}
   510 end;
   515 end;
   511 
   516 
   512 procedure free_uKeys;
   517 procedure free_uKeys;