Chromium Code Reviews| Index: chromeos/audio/cras_audio_handler.cc |
| diff --git a/chromeos/audio/cras_audio_handler.cc b/chromeos/audio/cras_audio_handler.cc |
| index 1cf03d172d839ca39cce2294492d4dc5e7a9cae5..8b7fdbd469e8c29e56adabdba3720f146c49ce7f 100644 |
| --- a/chromeos/audio/cras_audio_handler.cc |
| +++ b/chromeos/audio/cras_audio_handler.cc |
| @@ -69,8 +69,9 @@ void CrasAudioHandler::AudioObserver::OnInputNodeGainChanged( |
| int /* gain */) { |
| } |
| -void CrasAudioHandler::AudioObserver::OnOutputMuteChanged(bool /* mute_on */) { |
| -} |
| +void CrasAudioHandler::AudioObserver::OnOutputMuteChanged( |
| + bool /* mute_on */, |
| + bool /* system_adjust */) {} |
| void CrasAudioHandler::AudioObserver::OnInputMuteChanged(bool /* mute_on */) { |
| } |
| @@ -371,7 +372,7 @@ void CrasAudioHandler::SetOutputMute(bool mute_on) { |
| } |
| FOR_EACH_OBSERVER(AudioObserver, observers_, |
| - OnOutputMuteChanged(output_mute_on_)); |
| + OnOutputMuteChanged(output_mute_on_, false)); |
|
stevenjb
2015/07/28 21:36:52
false /* system_adjust */
jennyz
2015/07/28 22:40:44
Done.
|
| } |
| void CrasAudioHandler::AdjustOutputVolumeToAudibleLevel() { |
| @@ -1014,8 +1015,13 @@ void CrasAudioHandler::UpdateAudioAfterHDMIRediscoverGracePeriod() { |
| hdmi_rediscovering_ = false; |
| if (!IsOutputMutedForDevice(active_output_node_id_)) { |
| // Unmute the audio output after the HDMI transition period. |
| - VLOG(1) << "Unmute output after HDMI rediscovring grace period."; |
| + VLOG(1) << "Unmute output after HDMI rediscovering grace period."; |
| SetOutputMuteInternal(false); |
| + |
| + // Notify UI about the mute state change. |
| + FOR_EACH_OBSERVER( |
| + AudioObserver, observers_, |
| + OnOutputMuteChanged(output_mute_on_, true)); /* system adjustment */ |
|
stevenjb
2015/07/28 21:36:52
nit: 'true /* system_adjust */' (or put true on a
jennyz
2015/07/28 22:40:44
Done.
|
| } |
| } |