Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 // | |
|
scherkus (not reviewing)
2012/08/03 21:12:52
remove extra //
| |
| 5 | |
| 6 #include "content/renderer/media/audio_output_ipc_impl.h" | |
| 7 | |
| 8 #include "content/common/media/audio_messages.h" | |
| 9 #include "content/renderer/media/audio_message_filter.h" | |
| 10 | |
| 11 AudioOutputIPCImpl::AudioOutputIPCImpl(int render_view_id) | |
| 12 : render_view_id_(render_view_id) { | |
| 13 } | |
| 14 | |
| 15 AudioOutputIPCImpl::~AudioOutputIPCImpl() { | |
| 16 } | |
| 17 | |
| 18 int AudioOutputIPCImpl::AddDelegate( | |
| 19 media::AudioOutputIPCDelegate* delegate) { | |
| 20 return AudioMessageFilter::Get()->AddDelegate(delegate); | |
| 21 } | |
| 22 | |
| 23 void AudioOutputIPCImpl::RemoveDelegate(int id) { | |
| 24 AudioMessageFilter::Get()->RemoveDelegate(id); | |
| 25 } | |
| 26 | |
| 27 void AudioOutputIPCImpl::CreateStream(int stream_id, | |
| 28 const media::AudioParameters& params) { | |
| 29 Send(new AudioHostMsg_CreateStream(render_view_id_, stream_id, params)); | |
| 30 } | |
| 31 | |
| 32 void AudioOutputIPCImpl::PlayStream(int stream_id) { | |
| 33 Send(new AudioHostMsg_PlayStream(stream_id)); | |
| 34 } | |
| 35 | |
| 36 void AudioOutputIPCImpl::PauseStream(int stream_id) { | |
| 37 Send(new AudioHostMsg_PauseStream(stream_id)); | |
| 38 } | |
| 39 | |
| 40 void AudioOutputIPCImpl::FlushStream(int stream_id) { | |
| 41 Send(new AudioHostMsg_FlushStream(stream_id)); | |
| 42 } | |
| 43 | |
| 44 void AudioOutputIPCImpl::CloseStream(int stream_id) { | |
| 45 Send(new AudioHostMsg_CloseStream(stream_id)); | |
| 46 } | |
| 47 | |
| 48 void AudioOutputIPCImpl::SetVolume(int stream_id, double volume) { | |
| 49 Send(new AudioHostMsg_SetVolume(stream_id, volume)); | |
| 50 } | |
| 51 | |
| 52 bool AudioOutputIPCImpl::Send(IPC::Message* message) { | |
| 53 return AudioMessageFilter::Get()->Send(message); | |
| 54 } | |
| OLD | NEW |