Ejemplo n.º 1
0
        static void UpdateControllerLists()
        {
            _controllers = new Dictionary <RawGameController, IGameController>();
            foreach (var raw in _rawControllers)
            {
                _controllers[raw.Key] = null;
            }
            foreach (var gamepad in _gamepads)
            {
                var raw = RawGameController.FromGameController(gamepad);
                _controllers[raw] = gamepad;
            }

            if (_controllers.Values.Any(x => x == null))
            {
                StartRawPolling();
            }
            else
            {
                StopRawPolling();
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Product represents the Hardware Product ID for a IGamingController object.
        /// </summary>
        /// <returns>
        /// Product returns the Hardware Product ID value for a IGamingController object.
        /// </returns>
        public ushort Product()
        {
            RawGameController raw = RawGameController.FromGameController(Controller);

            return(raw.HardwareProductId);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Vendor represents the Hardware Vendor ID for a IGamingController object.
        /// </summary>
        /// <returns>
        /// Vendor returns the Hardware Vendor ID value for a IGamingController object.
        /// </returns>
        public ushort Vendor()
        {
            RawGameController raw = RawGameController.FromGameController(Controller);

            return(raw.HardwareVendorId);
        }