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

Side by Side Diff: device/bluetooth/bluetooth_adapter_mac.h

Issue 1842223003: Remove outdated devices from Android device chooser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reverted two small unnecessary changes. Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_ 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_
6 #define DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_ 6 #define DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_
7 7
8 #include <IOKit/IOReturn.h> 8 #include <IOKit/IOReturn.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 void ClassicDeviceAdded(IOBluetoothDevice* device); 170 void ClassicDeviceAdded(IOBluetoothDevice* device);
171 171
172 // BluetoothLowEnergyDiscoveryManagerMac::Observer override: 172 // BluetoothLowEnergyDiscoveryManagerMac::Observer override:
173 void LowEnergyDeviceUpdated(CBPeripheral* peripheral, 173 void LowEnergyDeviceUpdated(CBPeripheral* peripheral,
174 NSDictionary* advertisement_data, 174 NSDictionary* advertisement_data,
175 int rssi) override; 175 int rssi) override;
176 176
177 // Updates |devices_| when there is a change to the CBCentralManager's state. 177 // Updates |devices_| when there is a change to the CBCentralManager's state.
178 void LowEnergyCentralManagerUpdatedState(); 178 void LowEnergyCentralManagerUpdatedState();
179 179
180 // Removes from |devices_| any previously paired, connected or seen devices
181 // which are no longer present. Notifies observers.
182 void RemoveTimedOutDevices();
183
184 // Updates |devices_| to include the currently paired devices and notifies 180 // Updates |devices_| to include the currently paired devices and notifies
185 // observers. 181 // observers.
186 void AddPairedDevices(); 182 void AddPairedDevices();
187 183
188 // Returns the BLE device associated with the CoreBluetooth peripheral. 184 // Returns the BLE device associated with the CoreBluetooth peripheral.
189 BluetoothLowEnergyDeviceMac* GetBluetoothLowEnergyDeviceMac( 185 BluetoothLowEnergyDeviceMac* GetBluetoothLowEnergyDeviceMac(
190 CBPeripheral* peripheral); 186 CBPeripheral* peripheral);
191 187
192 std::string address_; 188 std::string address_;
193 std::string name_; 189 std::string name_;
(...skipping 15 matching lines...) Expand all
209 scoped_refptr<base::SequencedTaskRunner> ui_task_runner_; 205 scoped_refptr<base::SequencedTaskRunner> ui_task_runner_;
210 206
211 base::WeakPtrFactory<BluetoothAdapterMac> weak_ptr_factory_; 207 base::WeakPtrFactory<BluetoothAdapterMac> weak_ptr_factory_;
212 208
213 DISALLOW_COPY_AND_ASSIGN(BluetoothAdapterMac); 209 DISALLOW_COPY_AND_ASSIGN(BluetoothAdapterMac);
214 }; 210 };
215 211
216 } // namespace device 212 } // namespace device
217 213
218 #endif // DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_ 214 #endif // DEVICE_BLUETOOTH_BLUETOOTH_ADAPTER_MAC_H_
OLDNEW
« no previous file with comments | « device/bluetooth/bluetooth_adapter_android.cc ('k') | device/bluetooth/bluetooth_adapter_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698