summaryrefslogtreecommitdiffstats
path: root/examples/bluetooth/heartrate-game/devicefinder.cpp
diff options
context:
space:
mode:
authorJuha Vuolle <juha.vuolle@insta.fi>2022-08-16 13:32:04 +0300
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-08-17 05:59:55 +0000
commit819f42dca8610c8f79477b9ce598fcf674efca45 (patch)
tree84712bdf12a367a110ef807ea271dc74041bbf9a /examples/bluetooth/heartrate-game/devicefinder.cpp
parentcf1365c6ec775d46dec60edea0119d231bc0e8fd (diff)
Bluetooth heartrate example: increase scan time and remove QML warnings
Increase the time for device discovery as it often takes more than 5 seconds to find the devices. Introduce formal function parameters to QML signal handler functions to remove the related warnings. Change-Id: I79589803a1c6082f02fa13a9e0044a7c03ef0daa Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> (cherry picked from commit 868d7702d6efce4e92e712bc51148b3b04596c04) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'examples/bluetooth/heartrate-game/devicefinder.cpp')
-rw-r--r--examples/bluetooth/heartrate-game/devicefinder.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/bluetooth/heartrate-game/devicefinder.cpp b/examples/bluetooth/heartrate-game/devicefinder.cpp
index 1b7845c6..54dbd2bb 100644
--- a/examples/bluetooth/heartrate-game/devicefinder.cpp
+++ b/examples/bluetooth/heartrate-game/devicefinder.cpp
@@ -12,7 +12,7 @@ DeviceFinder::DeviceFinder(DeviceHandler *handler, QObject *parent):
{
//! [devicediscovery-1]
m_deviceDiscoveryAgent = new QBluetoothDeviceDiscoveryAgent(this);
- m_deviceDiscoveryAgent->setLowEnergyDiscoveryTimeout(5000);
+ m_deviceDiscoveryAgent->setLowEnergyDiscoveryTimeout(15000);
connect(m_deviceDiscoveryAgent, &QBluetoothDeviceDiscoveryAgent::deviceDiscovered, this, &DeviceFinder::addDevice);
connect(m_deviceDiscoveryAgent, &QBluetoothDeviceDiscoveryAgent::errorOccurred, this,