OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_plugin_delegate_impl.h" | 5 #include "content/renderer/pepper_plugin_delegate_impl.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 #include <queue> | 8 #include <queue> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 1426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1437 void PepperPluginDelegateImpl::SetContentRestriction(int restrictions) { | 1437 void PepperPluginDelegateImpl::SetContentRestriction(int restrictions) { |
1438 render_view_->Send(new ViewHostMsg_UpdateContentRestrictions( | 1438 render_view_->Send(new ViewHostMsg_UpdateContentRestrictions( |
1439 render_view_->routing_id(), restrictions)); | 1439 render_view_->routing_id(), restrictions)); |
1440 } | 1440 } |
1441 | 1441 |
1442 void PepperPluginDelegateImpl::SaveURLAs(const GURL& url) { | 1442 void PepperPluginDelegateImpl::SaveURLAs(const GURL& url) { |
1443 render_view_->Send(new ViewHostMsg_SaveURLAs( | 1443 render_view_->Send(new ViewHostMsg_SaveURLAs( |
1444 render_view_->routing_id(), url)); | 1444 render_view_->routing_id(), url)); |
1445 } | 1445 } |
1446 | 1446 |
1447 content::P2PSocketDispatcher* | |
1448 PepperPluginDelegateImpl::GetP2PSocketDispatcher() { | |
1449 return render_view_->p2p_socket_dispatcher(); | |
1450 } | |
1451 | |
1452 webkit_glue::P2PTransport* PepperPluginDelegateImpl::CreateP2PTransport() { | 1447 webkit_glue::P2PTransport* PepperPluginDelegateImpl::CreateP2PTransport() { |
1453 #if defined(ENABLE_P2P_APIS) | 1448 #if defined(ENABLE_P2P_APIS) |
1454 return new content::P2PTransportImpl(render_view_->p2p_socket_dispatcher()); | 1449 return new content::P2PTransportImpl(render_view_->p2p_socket_dispatcher()); |
1455 #else | 1450 #else |
1456 return NULL; | 1451 return NULL; |
1457 #endif | 1452 #endif |
1458 } | 1453 } |
1459 | 1454 |
1460 double PepperPluginDelegateImpl::GetLocalTimeZoneOffset(base::Time t) { | 1455 double PepperPluginDelegateImpl::GetLocalTimeZoneOffset(base::Time t) { |
1461 double result = 0.0; | 1456 double result = 0.0; |
(...skipping 30 matching lines...) Expand all Loading... |
1492 | 1487 |
1493 int PepperPluginDelegateImpl::GetRoutingId() const { | 1488 int PepperPluginDelegateImpl::GetRoutingId() const { |
1494 return render_view_->routing_id(); | 1489 return render_view_->routing_id(); |
1495 } | 1490 } |
1496 | 1491 |
1497 void PepperPluginDelegateImpl::PublishInitialPolicy( | 1492 void PepperPluginDelegateImpl::PublishInitialPolicy( |
1498 scoped_refptr<webkit::ppapi::PluginInstance> instance, | 1493 scoped_refptr<webkit::ppapi::PluginInstance> instance, |
1499 const std::string& policy) { | 1494 const std::string& policy) { |
1500 instance->HandlePolicyUpdate(policy); | 1495 instance->HandlePolicyUpdate(policy); |
1501 } | 1496 } |
OLD | NEW |