void USBHostController_DeviceConnectedEvent(USBH_Device device) { if (device.TYPE == USBH_DeviceType.Keyboard) { if (_KeyboardAndMouseInput == null) _KeyboardAndMouseInput = new KeyboardAndMouseInput(_UI, _KeyboardAndMouseOutput, _FiddleConfig, _DebuggerOnUsb); _KeyboardAndMouseInput.BeginMonitorKeyboardFrom(device); } else if (device.TYPE == USBH_DeviceType.Mouse) { if (_KeyboardAndMouseInput == null) _KeyboardAndMouseInput = new KeyboardAndMouseInput(_UI, _KeyboardAndMouseOutput, _FiddleConfig, _DebuggerOnUsb); _KeyboardAndMouseInput.BeginMonitorMouseFrom(device); } }
public static void UseKeyboardLayoutPreset(KeyboardLayoutPreset preset) { switch (preset) { case KeyboardLayoutPreset.AZERTY: Up = AZERTYUp; Down = AZERTYDown; Left = AZERTYLeft; Right = AZERTYRight; break; case KeyboardLayoutPreset.QWERTY: Up = QWERTYUp; Down = QWERTYDown; Left = QWERTYLeft; Right = QWERTYRight; break; } }