Polling joyGetCaps is very very slow, so we should not do that every
time GetCapabilities is called. Instead, we should call joyGetCaps once
and cache the results.
We need to find a different way to implement hotplugging.
public static void Main(string[] args)
{
Trace.Listeners.Add(new ConsoleTraceListener());
+ Tests.GameWindowStates.Main();
+ return;
if (args.Length > 0)
{
readonly XInputJoystick xinput;
readonly WinMMJoystick winmm;
+ readonly Dictionary<int, int> index_to_winmm =
+ new Dictionary<int, int>();
+
#region Constructors
public WinCombinedJoystick(XInputJoystick xinput, WinMMJoystick winmm)
const ClassStyle DefaultClassStyle = ClassStyle.OwnDC;
+ // Used for IInputDriver implementation
+ LegacyJoystickDriver joystick_driver = new LegacyJoystickDriver();
+ KeyboardDevice keyboard = new KeyboardDevice();
+ MouseDevice mouse = new MouseDevice();
+ IList<KeyboardDevice> keyboards = new List<KeyboardDevice>(1);
+ IList<MouseDevice> mice = new List<MouseDevice>(1);
+
const long ExtendedBit = 1 << 24; // Used to distinguish left and right control, alt and enter keys.
public static readonly uint ShiftLeftScanCode = Functions.MapVirtualKey(VirtualKeys.LSHIFT, 0);