[email protected] | 79a4c1e | 2010-10-17 20:44:38 | [diff] [blame] | 1 | // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
license.bot | bf09a50 | 2008-08-24 00:55:55 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 4 | // |
| 5 | // A class that implements BaseDropTarget for the test shell webview delegate. |
| 6 | |
[email protected] | 79a4c1e | 2010-10-17 20:44:38 | [diff] [blame] | 7 | #ifndef WEBKIT_TOOLS_TEST_SHELL_DROP_DELEGATE_H_ |
| 8 | #define WEBKIT_TOOLS_TEST_SHELL_DROP_DELEGATE_H_ |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 9 | |
[email protected] | 02bae0f | 2011-01-19 20:22:00 | [diff] [blame] | 10 | #include "ui/base/dragdrop/drop_target.h" |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 11 | |
[email protected] | 50ae00ef | 2009-10-19 05:11:03 | [diff] [blame] | 12 | namespace WebKit { |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 13 | class WebView; |
[email protected] | 50ae00ef | 2009-10-19 05:11:03 | [diff] [blame] | 14 | } |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 15 | |
[email protected] | 02bae0f | 2011-01-19 20:22:00 | [diff] [blame] | 16 | class TestDropDelegate : public ui::DropTarget { |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 17 | public: |
[email protected] | 79a4c1e | 2010-10-17 20:44:38 | [diff] [blame] | 18 | TestDropDelegate(HWND source_hwnd, WebKit::WebView* webview); |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 19 | |
| 20 | protected: |
[email protected] | 79a4c1e | 2010-10-17 20:44:38 | [diff] [blame] | 21 | // BaseDropTarget methods |
| 22 | virtual DWORD OnDragEnter(IDataObject* data_object, |
| 23 | DWORD key_state, |
| 24 | POINT cursor_position, |
| 25 | DWORD effect); |
| 26 | virtual DWORD OnDragOver(IDataObject* data_object, |
| 27 | DWORD key_state, |
| 28 | POINT cursor_position, |
| 29 | DWORD effect); |
| 30 | virtual void OnDragLeave(IDataObject* data_object); |
| 31 | virtual DWORD OnDrop(IDataObject* data_object, |
| 32 | DWORD key_state, |
| 33 | POINT cursor_position, |
| 34 | DWORD effect); |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 35 | |
| 36 | private: |
[email protected] | 50ae00ef | 2009-10-19 05:11:03 | [diff] [blame] | 37 | WebKit::WebView* webview_; |
initial.commit | f5b16fe | 2008-07-27 00:20:51 | [diff] [blame] | 38 | }; |
| 39 | |
[email protected] | 79a4c1e | 2010-10-17 20:44:38 | [diff] [blame] | 40 | #endif // WEBKIT_TOOLS_TEST_SHELL_DROP_DELEGATE_H_ |