Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Unified Diff: device/bluetooth/bluetooth_adapter.h

Issue 1842223003: Remove outdated devices from Android device chooser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased on master Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: device/bluetooth/bluetooth_adapter.h
diff --git a/device/bluetooth/bluetooth_adapter.h b/device/bluetooth/bluetooth_adapter.h
index c8b33fe960556e6e6071dbd39a78d8187f13afc8..2b48212ecb1d8e52fcc333a143ced1bdf79ee48a 100644
--- a/device/bluetooth/bluetooth_adapter.h
+++ b/device/bluetooth/bluetooth_adapter.h
@@ -444,6 +444,9 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAdapter
BluetoothRemoteGattDescriptor* descriptor,
const std::vector<uint8_t>& value);
+ // The timeout in seconds used by RemoveTimedOutDevices.
+ static const base::TimeDelta timeoutSec;
+
protected:
friend class base::RefCounted<BluetoothAdapter>;
friend class BluetoothDiscoverySession;
@@ -539,6 +542,12 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAdapter
void DeleteDeviceForTesting(const std::string& address);
+ // Removes from |devices_| any previously paired, connected or seen
+ // devices which are no longer present. Notifies observers. Note:
+ // this is only used by platforms where there is no notification of
+ // lost devices.
+ void RemoveTimedOutDevices();
+
// Observers of BluetoothAdapter, notified from implementation subclasses.
base::ObserverList<device::BluetoothAdapter::Observer> observers_;

Powered by Google App Engine
This is Rietveld 408576698