Пример #1
0
    void HandleSearchBLEDevicesEvent()
    {
        DidStartPeripheralScanEvent?.Invoke();
        ShowActivityIndicatorEvent?.Invoke();

        searchBleDevicesButton.GetComponent <Button>().enabled = false;

        BLEController.ScanForPeripherals();
        infoMessage.GetComponent <Text>().text = "Scanning for devices...";
    }
    void HandleSearchBLEDevicesEvent()
    {
        if (DidStartPeripheralScanEvent != null)
        {
            DidStartPeripheralScanEvent();
        }

        if (ShowActivityIndicatorEvent != null)
        {
            ShowActivityIndicatorEvent();
        }

        searchBleDevicesButton.GetComponent <Button>().enabled = false;

        BLEController.ScanForPeripherals();
    }