| 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 5b6ec0add74368210ac8e62e79d4b30079800d65..2c320e9f66297c8f0832906c41e6373c0a7af2d6 100644
|
| --- a/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| +++ b/chrome/browser/ui/ash/system_tray_delegate_chromeos.cc
|
| @@ -314,6 +314,9 @@ void SystemTrayDelegateChromeOS::Initialize() {
|
|
|
| if (LoginState::IsInitialized())
|
| LoginState::Get()->AddObserver(this);
|
| +
|
| + if (CrasAudioHandler::IsInitialized())
|
| + CrasAudioHandler::Get()->AddAudioObserver(this);
|
| }
|
|
|
| void SystemTrayDelegateChromeOS::Shutdown() {
|
| @@ -369,7 +372,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 =
|
| @@ -1210,6 +1216,33 @@ void SystemTrayDelegateChromeOS::InputMethodMenuItemChanged(
|
| 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);
|
|
|