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

Side by Side Diff: content/browser/browser_plugin/browser_plugin_guest.cc

Issue 18281002: Move WebDropData to content::DropData and split off conversion function. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Mac build error. Created 7 years, 5 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
OLDNEW
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/browser/browser_plugin/browser_plugin_guest.h" 5 #include "content/browser/browser_plugin/browser_plugin_guest.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 21 matching lines...) Expand all
32 #include "content/public/browser/content_browser_client.h" 32 #include "content/public/browser/content_browser_client.h"
33 #include "content/public/browser/geolocation_permission_context.h" 33 #include "content/public/browser/geolocation_permission_context.h"
34 #include "content/public/browser/notification_service.h" 34 #include "content/public/browser/notification_service.h"
35 #include "content/public/browser/notification_types.h" 35 #include "content/public/browser/notification_types.h"
36 #include "content/public/browser/render_process_host.h" 36 #include "content/public/browser/render_process_host.h"
37 #include "content/public/browser/render_widget_host_view.h" 37 #include "content/public/browser/render_widget_host_view.h"
38 #include "content/public/browser/resource_request_details.h" 38 #include "content/public/browser/resource_request_details.h"
39 #include "content/public/browser/user_metrics.h" 39 #include "content/public/browser/user_metrics.h"
40 #include "content/public/browser/web_contents_view.h" 40 #include "content/public/browser/web_contents_view.h"
41 #include "content/public/common/content_switches.h" 41 #include "content/public/common/content_switches.h"
42 #include "content/public/common/drop_data.h"
42 #include "content/public/common/media_stream_request.h" 43 #include "content/public/common/media_stream_request.h"
43 #include "content/public/common/result_codes.h" 44 #include "content/public/common/result_codes.h"
44 #include "net/base/net_errors.h" 45 #include "net/base/net_errors.h"
45 #include "net/url_request/url_request.h" 46 #include "net/url_request/url_request.h"
46 #include "third_party/WebKit/public/web/WebCursorInfo.h" 47 #include "third_party/WebKit/public/web/WebCursorInfo.h"
47 #include "ui/base/keycodes/keyboard_codes.h" 48 #include "ui/base/keycodes/keyboard_codes.h"
48 #include "ui/surface/transport_dib.h" 49 #include "ui/surface/transport_dib.h"
49 #include "webkit/common/webdropdata.h"
50 #include "webkit/glue/resource_type.h" 50 #include "webkit/glue/resource_type.h"
51 51
52 #if defined(OS_MACOSX) 52 #if defined(OS_MACOSX)
53 #include "content/browser/browser_plugin/browser_plugin_popup_menu_helper_mac.h" 53 #include "content/browser/browser_plugin/browser_plugin_popup_menu_helper_mac.h"
54 #endif 54 #endif
55 55
56 namespace content { 56 namespace content {
57 57
58 // static 58 // static
59 BrowserPluginHostFactory* BrowserPluginGuest::factory_ = NULL; 59 BrowserPluginHostFactory* BrowserPluginGuest::factory_ = NULL;
(...skipping 1065 matching lines...) Expand 10 before | Expand all | Expand 10 after
1125 int route_id, 1125 int route_id,
1126 int renderer_host_id, 1126 int renderer_host_id,
1127 const cc::CompositorFrameAck& ack) { 1127 const cc::CompositorFrameAck& ack) {
1128 RenderWidgetHostImpl::SendSwapCompositorFrameAck(route_id, 1128 RenderWidgetHostImpl::SendSwapCompositorFrameAck(route_id,
1129 renderer_host_id, 1129 renderer_host_id,
1130 ack); 1130 ack);
1131 } 1131 }
1132 1132
1133 void BrowserPluginGuest::OnDragStatusUpdate(int instance_id, 1133 void BrowserPluginGuest::OnDragStatusUpdate(int instance_id,
1134 WebKit::WebDragStatus drag_status, 1134 WebKit::WebDragStatus drag_status,
1135 const WebDropData& drop_data, 1135 const DropData& drop_data,
1136 WebKit::WebDragOperationsMask mask, 1136 WebKit::WebDragOperationsMask mask,
1137 const gfx::Point& location) { 1137 const gfx::Point& location) {
1138 RenderViewHost* host = GetWebContents()->GetRenderViewHost(); 1138 RenderViewHost* host = GetWebContents()->GetRenderViewHost();
1139 switch (drag_status) { 1139 switch (drag_status) {
1140 case WebKit::WebDragStatusEnter: 1140 case WebKit::WebDragStatusEnter:
1141 embedder_web_contents_->GetBrowserPluginEmbedder()->DragEnteredGuest( 1141 embedder_web_contents_->GetBrowserPluginEmbedder()->DragEnteredGuest(
1142 this); 1142 this);
1143 host->DragTargetDragEnter(drop_data, location, location, mask, 0); 1143 host->DragTargetDragEnter(drop_data, location, location, mask, 0);
1144 break; 1144 break;
1145 case WebKit::WebDragStatusOver: 1145 case WebKit::WebDragStatusOver:
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after
1595 base::Value::CreateStringValue(request_method)); 1595 base::Value::CreateStringValue(request_method));
1596 request_info.Set(browser_plugin::kURL, base::Value::CreateStringValue(url)); 1596 request_info.Set(browser_plugin::kURL, base::Value::CreateStringValue(url));
1597 1597
1598 SendMessageToEmbedder( 1598 SendMessageToEmbedder(
1599 new BrowserPluginMsg_RequestPermission(instance_id(), 1599 new BrowserPluginMsg_RequestPermission(instance_id(),
1600 BrowserPluginPermissionTypeDownload, permission_request_id, 1600 BrowserPluginPermissionTypeDownload, permission_request_id,
1601 request_info)); 1601 request_info));
1602 } 1602 }
1603 1603
1604 } // namespace content 1604 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698