예제 #1
0
 protected virtual void OnOpenCommand(SingleAxisCommand command)
 {
     if (IsSelected && _openCommands.Contains(command))
     {
         command.ConsumeInput();
         command.BlockNextRelease();
         Open();
     }
 }
예제 #2
0
 protected virtual void OnButton(SingleAxisCommand command)
 {
     command.ConsumeInput();
     if ((command == InputLibrary.confirm && (OWInput.IsGamepadEnabled() || !InputLibrary.enter.GetValue <bool>("_blockNextRelease"))) ||
         command == InputLibrary.enter2)
     {
         OnSave();
     }
     if (command == InputLibrary.cancel || command == InputLibrary.escape)
     {
         OnExit();
     }
     if (command == InputLibrary.setDefaults)
     {
         OnReset();
     }
 }