Наследование: IKeyboardCapabilities
        /// <summary>
        /// Initializes a new instance of the <see cref="DeviceStatusService"/> class.
        /// </summary>
        public DeviceStatusService()
        {
            _easClientDeviceInformation = new EasClientDeviceInformation();
            _keyboardCapabilities = new KeyboardCapabilities();

#if WINDOWS_PHONE_APP
            Battery.GetDefault().RemainingChargePercentChanged += OnPowerChanged;
            PowerManager.PowerSavingModeChanged += OnPowerChanged;
#elif WINDOWS_UWP
            Battery.AggregateBattery.ReportUpdated += OnPowerChanged;
            PowerManager.EnergySaverStatusChanged += OnPowerChanged;
#endif
        }
Пример #2
0
        public static bool IsHasPhysicalKeyboard()
        {
            KeyboardCapabilities keyboardCapabilities = new Windows.Devices.Input.KeyboardCapabilities();

            return(keyboardCapabilities.KeyboardPresent != 0);
        }
 static SystemMetricsInfo()
 {
     TouchCapabilitiesExt = new TouchCapabilities();
     KeyboardCapabilitiesExt = new KeyboardCapabilities();
     MouseCapabilitiesExt = new MouseCapabilities();
 }
Пример #4
0
 public KeyboardCaps()
 {
     var keybCaps = new KeyboardCapabilities();
     IsPresent = keybCaps.KeyboardPresent != 0;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="DeviceStatusService"/> class.
 /// </summary>
 public DeviceStatusService()
 {
     _easClientDeviceInformation = new EasClientDeviceInformation();
     _keyboardCapabilities = new KeyboardCapabilities();
 }