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

Side by Side Diff: webkit/tools/test_shell/drop_delegate.cc

Issue 6576020: Remove Gears from Chrome (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: windows fixes Created 9 years, 9 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "webkit/tools/test_shell/drop_delegate.h" 5 #include "webkit/tools/test_shell/drop_delegate.h"
6 6
7 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragData.h" 7 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragData.h"
8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPoint.h" 8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPoint.h"
9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h" 9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
10 #include "webkit/glue/webdropdata.h" 10 #include "webkit/glue/webdropdata.h"
(...skipping 11 matching lines...) Expand all
22 DWORD TestDropDelegate::OnDragEnter(IDataObject* data_object, 22 DWORD TestDropDelegate::OnDragEnter(IDataObject* data_object,
23 DWORD key_state, 23 DWORD key_state,
24 POINT cursor_position, 24 POINT cursor_position,
25 DWORD effect) { 25 DWORD effect) {
26 WebDropData drop_data; 26 WebDropData drop_data;
27 WebDropData::PopulateWebDropData(data_object, &drop_data); 27 WebDropData::PopulateWebDropData(data_object, &drop_data);
28 28
29 POINT client_pt = cursor_position; 29 POINT client_pt = cursor_position;
30 ScreenToClient(GetHWND(), &client_pt); 30 ScreenToClient(GetHWND(), &client_pt);
31 WebDragOperation op = webview_->dragTargetDragEnter( 31 WebDragOperation op = webview_->dragTargetDragEnter(
32 drop_data.ToDragData(), drop_data.identity, 32 drop_data.ToDragData(), 0, // web drag identity, unused.
33 WebPoint(client_pt.x, client_pt.y), 33 WebPoint(client_pt.x, client_pt.y),
34 WebPoint(cursor_position.x, cursor_position.y), 34 WebPoint(cursor_position.x, cursor_position.y),
35 WebDragOperationCopy); 35 WebDragOperationCopy);
36 // TODO(snej): Pass the real drag operation instead 36 // TODO(snej): Pass the real drag operation instead
37 return op ? DROPEFFECT_COPY : DROPEFFECT_NONE; 37 return op ? DROPEFFECT_COPY : DROPEFFECT_NONE;
38 // TODO(snej): Return the real drop effect constant matching 'op' 38 // TODO(snej): Return the real drop effect constant matching 'op'
39 } 39 }
40 40
41 DWORD TestDropDelegate::OnDragOver(IDataObject* data_object, 41 DWORD TestDropDelegate::OnDragOver(IDataObject* data_object,
42 DWORD key_state, 42 DWORD key_state,
(...skipping 20 matching lines...) Expand all
63 DWORD effect) { 63 DWORD effect) {
64 POINT client_pt = cursor_position; 64 POINT client_pt = cursor_position;
65 ScreenToClient(GetHWND(), &client_pt); 65 ScreenToClient(GetHWND(), &client_pt);
66 webview_->dragTargetDrop( 66 webview_->dragTargetDrop(
67 WebPoint(client_pt.x, client_pt.y), 67 WebPoint(client_pt.x, client_pt.y),
68 WebPoint(cursor_position.x, cursor_position.y)); 68 WebPoint(cursor_position.x, cursor_position.y));
69 69
70 // webkit win port always returns DROPEFFECT_NONE 70 // webkit win port always returns DROPEFFECT_NONE
71 return DROPEFFECT_NONE; 71 return DROPEFFECT_NONE;
72 } 72 }
OLDNEW
« no previous file with comments | « webkit/support/test_webplugin_page_delegate.h ('k') | webkit/tools/test_shell/test_shell_webkit_init.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698