| Index: chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| diff --git a/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc b/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| index d28de2cdea5c14b194adb08ad9ce6b4d6c2ed509..1b5784d8cc775308b82b53d47a0c3d4a87eb2bd0 100644
|
| --- a/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| +++ b/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| @@ -311,6 +311,9 @@ void SystemTrayDelegateChromeOS::Initialize() {
|
|
|
| if (LoginState::IsInitialized())
|
| LoginState::Get()->AddObserver(this);
|
| +
|
| + if (CrasAudioHandler::IsInitialized())
|
| + CrasAudioHandler::Get()->AddAudioObserver(this);
|
| }
|
|
|
| void SystemTrayDelegateChromeOS::Shutdown() {
|
| @@ -365,7 +368,10 @@ SystemTrayDelegateChromeOS::~SystemTrayDelegateChromeOS() {
|
| ->RemoveSessionStateObserver(this);
|
| LoginState::Get()->RemoveObserver(this);
|
|
|
| - // Stop observing Drive operations.
|
| + if (CrasAudioHandler::IsInitialized())
|
| + CrasAudioHandler::Get()->RemoveAudioObserver(this);
|
| +
|
| +// Stop observing Drive operations.
|
| UnobserveDriveUpdates();
|
|
|
| policy::BrowserPolicyConnectorChromeOS* connector =
|
| @@ -1206,6 +1212,33 @@ void SystemTrayDelegateChromeOS::InputMethodPropertyChanged(
|
| GetSystemTrayNotifier()->NotifyRefreshIME(false);
|
| }
|
|
|
| +// Overridden from CrasAudioHandler::AudioObserver.
|
| +void SystemTrayDelegateChromeOS::OnOutputVolumeChanged() {
|
| + GetSystemTrayNotifier()->NotifyAudioOutputVolumeChanged();
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnOutputMuteChanged() {
|
| + GetSystemTrayNotifier()->NotifyAudioOutputMuteChanged();
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnInputGainChanged() {
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnInputMuteChanged() {
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnAudioNodesChanged() {
|
| + GetSystemTrayNotifier()->NotifyAudioNodesChanged();
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnActiveOutputNodeChanged() {
|
| + GetSystemTrayNotifier()->NotifyAudioActiveOutputNodeChanged();
|
| +}
|
| +
|
| +void SystemTrayDelegateChromeOS::OnActiveInputNodeChanged() {
|
| + GetSystemTrayNotifier()->NotifyAudioActiveInputNodeChanged();
|
| +}
|
| +
|
| // drive::JobListObserver overrides.
|
| void SystemTrayDelegateChromeOS::OnJobAdded(const drive::JobInfo& job_info) {
|
| OnJobUpdated(job_info);
|
|
|