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

Side by Side Diff: chromeos/dbus/cras_audio_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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/cras_audio_client.h" 5 #include "chromeos/dbus/cras_audio_client.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/format_macros.h" 8 #include "base/format_macros.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "dbus/bus.h" 10 #include "dbus/bus.h"
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 } else if (key == cras::kPluggedTimeProperty) { 408 } else if (key == cras::kPluggedTimeProperty) {
409 if (!value_reader.PopUint64(&node->plugged_time)) 409 if (!value_reader.PopUint64(&node->plugged_time))
410 return false; 410 return false;
411 } 411 }
412 } 412 }
413 413
414 return true; 414 return true;
415 } 415 }
416 416
417 dbus::ObjectProxy* cras_proxy_; 417 dbus::ObjectProxy* cras_proxy_;
418 ObserverList<Observer> observers_; 418 base::ObserverList<Observer> observers_;
419 419
420 // Note: This should remain the last member so it'll be destroyed and 420 // Note: This should remain the last member so it'll be destroyed and
421 // invalidate its weak pointers before any other members are destroyed. 421 // invalidate its weak pointers before any other members are destroyed.
422 base::WeakPtrFactory<CrasAudioClientImpl> weak_ptr_factory_; 422 base::WeakPtrFactory<CrasAudioClientImpl> weak_ptr_factory_;
423 423
424 DISALLOW_COPY_AND_ASSIGN(CrasAudioClientImpl); 424 DISALLOW_COPY_AND_ASSIGN(CrasAudioClientImpl);
425 }; 425 };
426 426
427 CrasAudioClient::Observer::~Observer() { 427 CrasAudioClient::Observer::~Observer() {
428 } 428 }
(...skipping 21 matching lines...) Expand all
450 450
451 CrasAudioClient::~CrasAudioClient() { 451 CrasAudioClient::~CrasAudioClient() {
452 } 452 }
453 453
454 // static 454 // static
455 CrasAudioClient* CrasAudioClient::Create() { 455 CrasAudioClient* CrasAudioClient::Create() {
456 return new CrasAudioClientImpl(); 456 return new CrasAudioClientImpl();
457 } 457 }
458 458
459 } // namespace chromeos 459 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/dbus/bluetooth_media_transport_client.cc ('k') | chromeos/dbus/fake_bluetooth_adapter_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698