OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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/pepper/pepper_plugin_delegate_impl.h" | 5 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 #include <cstddef> | 8 #include <cstddef> |
9 #include <map> | 9 #include <map> |
10 #include <queue> | 10 #include <queue> |
(...skipping 816 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
827 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() { | 827 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() { |
828 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize()); | 828 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize()); |
829 } | 829 } |
830 | 830 |
831 webkit::ppapi::PluginDelegate::PlatformAudioOutput* | 831 webkit::ppapi::PluginDelegate::PlatformAudioOutput* |
832 PepperPluginDelegateImpl::CreateAudioOutput( | 832 PepperPluginDelegateImpl::CreateAudioOutput( |
833 uint32_t sample_rate, | 833 uint32_t sample_rate, |
834 uint32_t sample_count, | 834 uint32_t sample_count, |
835 webkit::ppapi::PluginDelegate::PlatformAudioOutputClient* client) { | 835 webkit::ppapi::PluginDelegate::PlatformAudioOutputClient* client) { |
836 return PepperPlatformAudioOutputImpl::Create( | 836 return PepperPlatformAudioOutputImpl::Create( |
| 837 render_view_->GetRoutingID(), |
837 static_cast<int>(sample_rate), static_cast<int>(sample_count), client); | 838 static_cast<int>(sample_rate), static_cast<int>(sample_count), client); |
838 } | 839 } |
839 | 840 |
840 webkit::ppapi::PluginDelegate::PlatformAudioInput* | 841 webkit::ppapi::PluginDelegate::PlatformAudioInput* |
841 PepperPluginDelegateImpl::CreateAudioInput( | 842 PepperPluginDelegateImpl::CreateAudioInput( |
842 const std::string& device_id, | 843 const std::string& device_id, |
843 uint32_t sample_rate, | 844 uint32_t sample_rate, |
844 uint32_t sample_count, | 845 uint32_t sample_count, |
845 webkit::ppapi::PluginDelegate::PlatformAudioInputClient* client) { | 846 webkit::ppapi::PluginDelegate::PlatformAudioInputClient* client) { |
846 return PepperPlatformAudioInputImpl::Create( | 847 return PepperPlatformAudioInputImpl::Create( |
| 848 render_view_->GetRoutingID(), |
847 AsWeakPtr(), device_id, static_cast<int>(sample_rate), | 849 AsWeakPtr(), device_id, static_cast<int>(sample_rate), |
848 static_cast<int>(sample_count), client); | 850 static_cast<int>(sample_count), client); |
849 } | 851 } |
850 | 852 |
851 // If a broker has not already been created for this plugin, creates one. | 853 // If a broker has not already been created for this plugin, creates one. |
852 webkit::ppapi::PluginDelegate::Broker* | 854 webkit::ppapi::PluginDelegate::Broker* |
853 PepperPluginDelegateImpl::ConnectToBroker( | 855 PepperPluginDelegateImpl::ConnectToBroker( |
854 webkit::ppapi::PPB_Broker_Impl* client) { | 856 webkit::ppapi::PPB_Broker_Impl* client) { |
855 DCHECK(client); | 857 DCHECK(client); |
856 | 858 |
(...skipping 1017 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1874 else | 1876 else |
1875 return render_view_->mouse_lock_dispatcher(); | 1877 return render_view_->mouse_lock_dispatcher(); |
1876 } | 1878 } |
1877 | 1879 |
1878 webkit_glue::ClipboardClient* | 1880 webkit_glue::ClipboardClient* |
1879 PepperPluginDelegateImpl::CreateClipboardClient() const { | 1881 PepperPluginDelegateImpl::CreateClipboardClient() const { |
1880 return new RendererClipboardClient; | 1882 return new RendererClipboardClient; |
1881 } | 1883 } |
1882 | 1884 |
1883 } // namespace content | 1885 } // namespace content |
OLD | NEW |