Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Side by Side Diff: content/renderer/pepper_plugin_delegate_impl.cc

Issue 7826017: Add PPB_Fullscreen;0.5. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/test/ui/ppapi_uitest.cc ('k') | ppapi/api/dev/ppb_fullscreen_dev.idl » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 1392 matching lines...) Expand 10 before | Expand all | Expand 10 after
1403 1403
1404 ContextMenuParams params; 1404 ContextMenuParams params;
1405 params.x = position.x(); 1405 params.x = position.x();
1406 params.y = position.y(); 1406 params.y = position.y();
1407 params.custom_context.is_pepper_menu = true; 1407 params.custom_context.is_pepper_menu = true;
1408 params.custom_context.request_id = request_id; 1408 params.custom_context.request_id = request_id;
1409 params.custom_context.render_widget_id = render_widget_id; 1409 params.custom_context.render_widget_id = render_widget_id;
1410 params.custom_items = menu->menu_data(); 1410 params.custom_items = menu->menu_data();
1411 1411
1412 // Transform the position to be in render view's coordinates. 1412 // Transform the position to be in render view's coordinates.
1413 if (instance->FlashIsFullscreen(instance->pp_instance())) { 1413 if (instance->IsFullscreen(instance->pp_instance()) ||
1414 instance->FlashIsFullscreen(instance->pp_instance())) {
1414 WebKit::WebRect rect = render_view_->windowRect(); 1415 WebKit::WebRect rect = render_view_->windowRect();
1415 params.x -= rect.x; 1416 params.x -= rect.x;
1416 params.y -= rect.y; 1417 params.y -= rect.y;
1417 } else { 1418 } else {
1418 params.x += instance->position().x(); 1419 params.x += instance->position().x();
1419 params.y += instance->position().y(); 1420 params.y += instance->position().y();
1420 } 1421 }
1421 1422
1422 IPC::Message* msg = new ViewHostMsg_ContextMenu(render_view_->routing_id(), 1423 IPC::Message* msg = new ViewHostMsg_ContextMenu(render_view_->routing_id(),
1423 params); 1424 params);
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
1614 1615
1615 int PepperPluginDelegateImpl::GetRoutingId() const { 1616 int PepperPluginDelegateImpl::GetRoutingId() const {
1616 return render_view_->routing_id(); 1617 return render_view_->routing_id();
1617 } 1618 }
1618 1619
1619 void PepperPluginDelegateImpl::PublishInitialPolicy( 1620 void PepperPluginDelegateImpl::PublishInitialPolicy(
1620 scoped_refptr<webkit::ppapi::PluginInstance> instance, 1621 scoped_refptr<webkit::ppapi::PluginInstance> instance,
1621 const std::string& policy) { 1622 const std::string& policy) {
1622 instance->HandlePolicyUpdate(policy); 1623 instance->HandlePolicyUpdate(policy);
1623 } 1624 }
OLDNEW
« no previous file with comments | « chrome/test/ui/ppapi_uitest.cc ('k') | ppapi/api/dev/ppb_fullscreen_dev.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698