示例#1
0
 private bool GetBindedButton(Key key, out GameBoyPadButton button)
 {
     foreach (var name in Enum.GetValues(typeof(GameBoyPadButton)).Cast <GameBoyPadButton>().Where(x => x != GameBoyPadButton.None))
     {
         var bindedKey = (Key)Properties.Settings.Default["KeyBinding" + name];
         if (bindedKey == key)
         {
             button = name;
             return(true);
         }
     }
     button = GameBoyPadButton.A;
     return(false);
 }
示例#2
0
 public void Reset()
 {
     _joyP           = 0;
     _pressedButtons = GameBoyPadButton.None;
 }