void ReleaseDesignerOutlets() { if (DeviceTable != null) { DeviceTable.Dispose(); DeviceTable = null; } if (DeviceTableHeaderView != null) { DeviceTableHeaderView.Dispose(); DeviceTableHeaderView = null; } if (DeviceTableView != null) { DeviceTableView.Dispose(); DeviceTableView = null; } if (tableContent != null) { tableContent.Dispose(); tableContent = null; } }
void ReleaseDesignerOutlets() { if (ConnectButton != null) { ConnectButton.Dispose(); ConnectButton = null; } if (DeviceTableView != null) { DeviceTableView.Dispose(); DeviceTableView = null; } if (PairedDevicesLabel != null) { PairedDevicesLabel.Dispose(); PairedDevicesLabel = null; } if (ScanButton != null) { ScanButton.Dispose(); ScanButton = null; } }
/// <summary> /// Handler for the BluetoothSensorManager's DiscoveredPeripheral event. /// </summary> /// <param name="sender">Sender.</param> /// <param name="e">E.</param> void OnDiscoveredPeripheral(object sender, BluetoothDiscoveredPeripheralEventArgs e) { Console.WriteLine($"discovered {e.PeripheralName}"); // add to underlying list and reload data _sensorListSource.Add(e.PeripheralName, e.Peripheral, e.bIsHexoskinPeripheral); DeviceTableView.ReloadData(); }