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

Side by Side Diff: device/bluetooth/test/mock_bluetooth_gatt_notify_session.cc

Issue 2423793002: Remove usage of FOR_EACH_OBSERVER macro in device/ (Closed)
Patch Set: rebase Created 4 years, 2 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "device/bluetooth/test/mock_bluetooth_gatt_notify_session.h" 5 #include "device/bluetooth/test/mock_bluetooth_gatt_notify_session.h"
6 #include "device/bluetooth/test/mock_bluetooth_adapter.h" 6 #include "device/bluetooth/test/mock_bluetooth_adapter.h"
7 #include "device/bluetooth/test/mock_bluetooth_gatt_characteristic.h" 7 #include "device/bluetooth/test/mock_bluetooth_gatt_characteristic.h"
8 8
9 using testing::Return; 9 using testing::Return;
10 10
(...skipping 22 matching lines...) Expand all
33 } 33 }
34 34
35 void MockBluetoothGattNotifySession::StopTestNotifications() { 35 void MockBluetoothGattNotifySession::StopTestNotifications() {
36 test_notifications_timer_.Stop(); 36 test_notifications_timer_.Stop();
37 } 37 }
38 38
39 void MockBluetoothGattNotifySession::DoNotify( 39 void MockBluetoothGattNotifySession::DoNotify(
40 MockBluetoothAdapter* adapter, 40 MockBluetoothAdapter* adapter,
41 MockBluetoothGattCharacteristic* characteristic, 41 MockBluetoothGattCharacteristic* characteristic,
42 const std::vector<uint8_t>& value) { 42 const std::vector<uint8_t>& value) {
43 FOR_EACH_OBSERVER( 43 for (auto& observer : adapter->GetObservers())
44 BluetoothAdapter::Observer, adapter->GetObservers(), 44 observer.GattCharacteristicValueChanged(adapter, characteristic, value);
45 GattCharacteristicValueChanged(adapter, characteristic, value));
46 } 45 }
47 46
48 } // namespace device 47 } // namespace device
OLDNEW
« no previous file with comments | « device/bluetooth/dbus/fake_bluetooth_media_transport_client.cc ('k') | device/generic_sensor/platform_sensor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698