Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "content/renderer/media/media_stream_audio_source.h" | 5 #include "content/renderer/media/media_stream_audio_source.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/single_thread_task_runner.h" | 8 #include "base/single_thread_task_runner.h" |
| 9 #include "base/threading/thread_task_runner_handle.h" | 9 #include "base/threading/thread_task_runner_handle.h" |
| 10 #include "content/renderer/media/media_stream_audio_track.h" | 10 #include "content/renderer/media/media_stream_audio_track.h" |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 140 } | 140 } |
| 141 | 141 |
| 142 void MediaStreamAudioSource::StopSourceOnError(const std::string& why) { | 142 void MediaStreamAudioSource::StopSourceOnError(const std::string& why) { |
| 143 VLOG(1) << why; | 143 VLOG(1) << why; |
| 144 | 144 |
| 145 // Stop source when error occurs. | 145 // Stop source when error occurs. |
| 146 task_runner_->PostTask( | 146 task_runner_->PostTask( |
| 147 FROM_HERE, base::Bind(&MediaStreamSource::StopSource, GetWeakPtr())); | 147 FROM_HERE, base::Bind(&MediaStreamSource::StopSource, GetWeakPtr())); |
| 148 } | 148 } |
| 149 | 149 |
| 150 void MediaStreamAudioSource::SetMutedState(bool muted_state) { | |
| 151 DVLOG(3) << "MediaStreamAudioSource::SetMutedState state=" << muted_state; | |
| 152 task_runner_->PostTask( | |
| 153 FROM_HERE, base::Bind(&MediaStreamSource::SetSourceMuted, GetWeakPtr(), | |
|
ossu-chromium
2017/06/01 15:56:59
I've put SetSourceMuted directly in MediaStreamSou
Max Morin
2017/06/02 09:56:04
I think someone with experience in this layer shou
ossu-chromium
2017/06/02 10:47:59
Sounds good. I'll add him!
| |
| 154 muted_state)); | |
| 155 } | |
| 156 | |
| 150 } // namespace content | 157 } // namespace content |
| OLD | NEW |