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

Side by Side Diff: content/test/test_web_contents_view.h

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
« no previous file with comments | « content/renderer/webclipboard_impl.cc ('k') | content/test/test_web_contents_view.cc » ('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) 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 #ifndef CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_ 5 #ifndef CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_
6 #define CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_ 6 #define CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "content/port/browser/render_view_host_delegate_view.h" 9 #include "content/port/browser/render_view_host_delegate_view.h"
10 #include "content/port/browser/web_contents_view_port.h" 10 #include "content/port/browser/web_contents_view_port.h"
11 11
12 namespace content { 12 namespace content {
13 13
14 class TestWebContentsView : public WebContentsViewPort, 14 class TestWebContentsView : public WebContentsViewPort,
15 public RenderViewHostDelegateView { 15 public RenderViewHostDelegateView {
16 public: 16 public:
17 TestWebContentsView(); 17 TestWebContentsView();
18 virtual ~TestWebContentsView(); 18 virtual ~TestWebContentsView();
19 19
20 // RenderViewHostDelegateView: 20 // RenderViewHostDelegateView:
21 virtual void ShowPopupMenu(const gfx::Rect& bounds, 21 virtual void ShowPopupMenu(const gfx::Rect& bounds,
22 int item_height, 22 int item_height,
23 double item_font_size, 23 double item_font_size,
24 int selected_item, 24 int selected_item,
25 const std::vector<WebMenuItem>& items, 25 const std::vector<WebMenuItem>& items,
26 bool right_aligned, 26 bool right_aligned,
27 bool allow_multiple_selection) OVERRIDE; 27 bool allow_multiple_selection) OVERRIDE;
28 virtual void StartDragging(const WebDropData& drop_data, 28 virtual void StartDragging(const DropData& drop_data,
29 WebKit::WebDragOperationsMask allowed_ops, 29 WebKit::WebDragOperationsMask allowed_ops,
30 const gfx::ImageSkia& image, 30 const gfx::ImageSkia& image,
31 const gfx::Vector2d& image_offset, 31 const gfx::Vector2d& image_offset,
32 const DragEventSourceInfo& event_info) OVERRIDE; 32 const DragEventSourceInfo& event_info) OVERRIDE;
33 virtual void UpdateDragCursor(WebKit::WebDragOperation operation) OVERRIDE; 33 virtual void UpdateDragCursor(WebKit::WebDragOperation operation) OVERRIDE;
34 virtual void GotFocus() OVERRIDE; 34 virtual void GotFocus() OVERRIDE;
35 virtual void TakeFocus(bool reverse) OVERRIDE; 35 virtual void TakeFocus(bool reverse) OVERRIDE;
36 36
37 // WebContentsView: 37 // WebContentsView:
38 virtual gfx::NativeView GetNativeView() const OVERRIDE; 38 virtual gfx::NativeView GetNativeView() const OVERRIDE;
39 virtual gfx::NativeView GetContentNativeView() const OVERRIDE; 39 virtual gfx::NativeView GetContentNativeView() const OVERRIDE;
40 virtual gfx::NativeWindow GetTopLevelNativeWindow() const OVERRIDE; 40 virtual gfx::NativeWindow GetTopLevelNativeWindow() const OVERRIDE;
41 virtual void GetContainerBounds(gfx::Rect *out) const OVERRIDE; 41 virtual void GetContainerBounds(gfx::Rect *out) const OVERRIDE;
42 virtual void OnTabCrashed(base::TerminationStatus status, 42 virtual void OnTabCrashed(base::TerminationStatus status,
43 int error_code) OVERRIDE; 43 int error_code) OVERRIDE;
44 virtual void SizeContents(const gfx::Size& size) OVERRIDE; 44 virtual void SizeContents(const gfx::Size& size) OVERRIDE;
45 virtual void Focus() OVERRIDE; 45 virtual void Focus() OVERRIDE;
46 virtual void SetInitialFocus() OVERRIDE; 46 virtual void SetInitialFocus() OVERRIDE;
47 virtual void StoreFocus() OVERRIDE; 47 virtual void StoreFocus() OVERRIDE;
48 virtual void RestoreFocus() OVERRIDE; 48 virtual void RestoreFocus() OVERRIDE;
49 virtual WebDropData* GetDropData() const OVERRIDE; 49 virtual DropData* GetDropData() const OVERRIDE;
50 virtual gfx::Rect GetViewBounds() const OVERRIDE; 50 virtual gfx::Rect GetViewBounds() const OVERRIDE;
51 #if defined(OS_MACOSX) 51 #if defined(OS_MACOSX)
52 virtual void SetAllowOverlappingViews(bool overlapping) OVERRIDE; 52 virtual void SetAllowOverlappingViews(bool overlapping) OVERRIDE;
53 virtual bool GetAllowOverlappingViews() const OVERRIDE; 53 virtual bool GetAllowOverlappingViews() const OVERRIDE;
54 #endif 54 #endif
55 55
56 // WebContentsViewPort: 56 // WebContentsViewPort:
57 virtual void CreateView(const gfx::Size& initial_size, 57 virtual void CreateView(const gfx::Size& initial_size,
58 gfx::NativeView context) OVERRIDE; 58 gfx::NativeView context) OVERRIDE;
59 virtual RenderWidgetHostView* CreateViewForWidget( 59 virtual RenderWidgetHostView* CreateViewForWidget(
60 RenderWidgetHost* render_widget_host) OVERRIDE; 60 RenderWidgetHost* render_widget_host) OVERRIDE;
61 virtual RenderWidgetHostView* CreateViewForPopupWidget( 61 virtual RenderWidgetHostView* CreateViewForPopupWidget(
62 RenderWidgetHost* render_widget_host) OVERRIDE; 62 RenderWidgetHost* render_widget_host) OVERRIDE;
63 virtual void SetPageTitle(const string16& title) OVERRIDE; 63 virtual void SetPageTitle(const string16& title) OVERRIDE;
64 virtual void RenderViewCreated(RenderViewHost* host) OVERRIDE; 64 virtual void RenderViewCreated(RenderViewHost* host) OVERRIDE;
65 virtual void RenderViewSwappedIn(RenderViewHost* host) OVERRIDE; 65 virtual void RenderViewSwappedIn(RenderViewHost* host) OVERRIDE;
66 virtual void SetOverscrollControllerEnabled(bool enabled) OVERRIDE; 66 virtual void SetOverscrollControllerEnabled(bool enabled) OVERRIDE;
67 #if defined(OS_MACOSX) 67 #if defined(OS_MACOSX)
68 virtual bool IsEventTracking() const OVERRIDE; 68 virtual bool IsEventTracking() const OVERRIDE;
69 virtual void CloseTabAfterEventTracking() OVERRIDE; 69 virtual void CloseTabAfterEventTracking() OVERRIDE;
70 #endif 70 #endif
71 71
72 private: 72 private:
73 DISALLOW_COPY_AND_ASSIGN(TestWebContentsView); 73 DISALLOW_COPY_AND_ASSIGN(TestWebContentsView);
74 }; 74 };
75 75
76 } // namespace content 76 } // namespace content
77 77
78 #endif // CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_ 78 #endif // CONTENT_TEST_TEST_WEB_CONTENTS_VIEW_H_
OLDNEW
« no previous file with comments | « content/renderer/webclipboard_impl.cc ('k') | content/test/test_web_contents_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698