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

Side by Side Diff: chromeos/dbus/bluetooth_device_client.cc

Issue 1162943002: Replace more ObserverList with base::ObserverList. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@observer
Patch Set: Created 5 years, 6 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 #include "chromeos/dbus/bluetooth_device_client.h" 5 #include "chromeos/dbus/bluetooth_device_client.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "dbus/bus.h" 10 #include "dbus/bus.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 } else { 369 } else {
370 error_name = kNoResponseError; 370 error_name = kNoResponseError;
371 error_message = ""; 371 error_message = "";
372 } 372 }
373 error_callback.Run(error_name, error_message); 373 error_callback.Run(error_name, error_message);
374 } 374 }
375 375
376 dbus::ObjectManager* object_manager_; 376 dbus::ObjectManager* object_manager_;
377 377
378 // List of observers interested in event notifications from us. 378 // List of observers interested in event notifications from us.
379 ObserverList<BluetoothDeviceClient::Observer> observers_; 379 base::ObserverList<BluetoothDeviceClient::Observer> observers_;
380 380
381 // Weak pointer factory for generating 'this' pointers that might live longer 381 // Weak pointer factory for generating 'this' pointers that might live longer
382 // than we do. 382 // than we do.
383 // Note: This should remain the last member so it'll be destroyed and 383 // Note: This should remain the last member so it'll be destroyed and
384 // invalidate its weak pointers before any other members are destroyed. 384 // invalidate its weak pointers before any other members are destroyed.
385 base::WeakPtrFactory<BluetoothDeviceClientImpl> weak_ptr_factory_; 385 base::WeakPtrFactory<BluetoothDeviceClientImpl> weak_ptr_factory_;
386 386
387 DISALLOW_COPY_AND_ASSIGN(BluetoothDeviceClientImpl); 387 DISALLOW_COPY_AND_ASSIGN(BluetoothDeviceClientImpl);
388 }; 388 };
389 389
390 BluetoothDeviceClient::BluetoothDeviceClient() { 390 BluetoothDeviceClient::BluetoothDeviceClient() {
391 } 391 }
392 392
393 BluetoothDeviceClient::~BluetoothDeviceClient() { 393 BluetoothDeviceClient::~BluetoothDeviceClient() {
394 } 394 }
395 395
396 BluetoothDeviceClient* BluetoothDeviceClient::Create() { 396 BluetoothDeviceClient* BluetoothDeviceClient::Create() {
397 return new BluetoothDeviceClientImpl(); 397 return new BluetoothDeviceClientImpl();
398 } 398 }
399 399
400 } // namespace chromeos 400 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/dbus/bluetooth_adapter_client.cc ('k') | chromeos/dbus/bluetooth_gatt_characteristic_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698