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 841 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
852 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() { | 852 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() { |
853 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize()); | 853 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize()); |
854 } | 854 } |
855 | 855 |
856 webkit::ppapi::PluginDelegate::PlatformAudioOutput* | 856 webkit::ppapi::PluginDelegate::PlatformAudioOutput* |
857 PepperPluginDelegateImpl::CreateAudioOutput( | 857 PepperPluginDelegateImpl::CreateAudioOutput( |
858 uint32_t sample_rate, | 858 uint32_t sample_rate, |
859 uint32_t sample_count, | 859 uint32_t sample_count, |
860 webkit::ppapi::PluginDelegate::PlatformAudioOutputClient* client) { | 860 webkit::ppapi::PluginDelegate::PlatformAudioOutputClient* client) { |
861 return PepperPlatformAudioOutputImpl::Create( | 861 return PepperPlatformAudioOutputImpl::Create( |
| 862 render_view_->GetRoutingID(), |
862 static_cast<int>(sample_rate), static_cast<int>(sample_count), client); | 863 static_cast<int>(sample_rate), static_cast<int>(sample_count), client); |
863 } | 864 } |
864 | 865 |
865 webkit::ppapi::PluginDelegate::PlatformAudioInput* | 866 webkit::ppapi::PluginDelegate::PlatformAudioInput* |
866 PepperPluginDelegateImpl::CreateAudioInput( | 867 PepperPluginDelegateImpl::CreateAudioInput( |
867 const std::string& device_id, | 868 const std::string& device_id, |
868 uint32_t sample_rate, | 869 uint32_t sample_rate, |
869 uint32_t sample_count, | 870 uint32_t sample_count, |
870 webkit::ppapi::PluginDelegate::PlatformAudioInputClient* client) { | 871 webkit::ppapi::PluginDelegate::PlatformAudioInputClient* client) { |
871 return PepperPlatformAudioInputImpl::Create( | 872 return PepperPlatformAudioInputImpl::Create( |
| 873 render_view_->GetRoutingID(), |
872 AsWeakPtr(), device_id, static_cast<int>(sample_rate), | 874 AsWeakPtr(), device_id, static_cast<int>(sample_rate), |
873 static_cast<int>(sample_count), client); | 875 static_cast<int>(sample_count), client); |
874 } | 876 } |
875 | 877 |
876 // If a broker has not already been created for this plugin, creates one. | 878 // If a broker has not already been created for this plugin, creates one. |
877 webkit::ppapi::PluginDelegate::Broker* | 879 webkit::ppapi::PluginDelegate::Broker* |
878 PepperPluginDelegateImpl::ConnectToBroker( | 880 PepperPluginDelegateImpl::ConnectToBroker( |
879 webkit::ppapi::PPB_Broker_Impl* client) { | 881 webkit::ppapi::PPB_Broker_Impl* client) { |
880 DCHECK(client); | 882 DCHECK(client); |
881 | 883 |
(...skipping 978 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1860 else | 1862 else |
1861 return render_view_->mouse_lock_dispatcher(); | 1863 return render_view_->mouse_lock_dispatcher(); |
1862 } | 1864 } |
1863 | 1865 |
1864 webkit_glue::ClipboardClient* | 1866 webkit_glue::ClipboardClient* |
1865 PepperPluginDelegateImpl::CreateClipboardClient() const { | 1867 PepperPluginDelegateImpl::CreateClipboardClient() const { |
1866 return new RendererClipboardClient; | 1868 return new RendererClipboardClient; |
1867 } | 1869 } |
1868 | 1870 |
1869 } // namespace content | 1871 } // namespace content |
OLD | NEW |