public Scenario9_CustomPairDevice() { this.InitializeComponent(); deviceWatcherHelper = new DeviceWatcherHelper(resultCollection, Dispatcher); deviceWatcherHelper.DeviceChanged += OnDeviceListChanged; }
private void StartWatchers() { startWatcherButton.IsEnabled = false; resultCollection.Clear(); // Create a watcher for each DeviceInformationKind selected by the user foreach (DeviceInformationKind deviceInfoKind in ((DeviceInformationKindChoice)kindComboBox.SelectedItem).DeviceInformationKinds) { DeviceWatcher deviceWatcher = DeviceInformation.CreateWatcher( "", // AQS Filter string null, // requested properties deviceInfoKind); DeviceWatcherHelper deviceWatcherHelper = new DeviceWatcherHelper(resultCollection, Dispatcher); deviceWatcherHelper.UpdateStatus = false; // we will show our own status messages deviceWatcherHelper.DeviceChanged += OnDeviceListChanged; deviceWatcherHelpers.Add(deviceWatcherHelper); deviceWatcherHelper.StartWatcher(deviceWatcher); } stopWatcherButton.IsEnabled = true; stopWatcherButton.Focus(FocusState.Keyboard); }
public Scenario6_CustomFilterAddedProps() { this.InitializeComponent(); deviceWatcherHelper = new DeviceWatcherHelper(resultCollection, Dispatcher); }
public Scenario2_DeviceWatcher() { this.InitializeComponent(); deviceWatcherHelper = new DeviceWatcherHelper(resultCollection, Dispatcher); }