[Linux] Start/Stop BLE scan when going to sleep

This commit is contained in:
Tim Gromeyer
2025-06-24 13:29:54 +02:00
committed by Tim Gromeyer
parent 05c0a7c88b
commit fb3c8c73a4
5 changed files with 75 additions and 0 deletions

View File

@@ -112,6 +112,11 @@ void BleManager::stopScan()
discoveryAgent->stop();
}
bool BleManager::isScanning() const
{
return discoveryAgent->isActive();
}
void BleManager::onDeviceDiscovered(const QBluetoothDeviceInfo &info)
{
// Check for Apple's manufacturer ID (0x004C)

View File

@@ -72,6 +72,7 @@ public:
void startScan();
void stopScan();
bool isScanning() const;
private slots:
void onDeviceDiscovered(const QBluetoothDeviceInfo &info);