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

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

Issue 2702093002: Consistent CopyFromSurface() API, consolidated to RWHV (Closed)
Patch Set: REBASE Created 3 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
« no previous file with comments | « content/public/browser/render_widget_host_view.h ('k') | content/test/test_render_view_host.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_RENDER_VIEW_HOST_H_ 5 #ifndef CONTENT_TEST_TEST_RENDER_VIEW_HOST_H_
6 #define CONTENT_TEST_TEST_RENDER_VIEW_HOST_H_ 6 #define CONTENT_TEST_TEST_RENDER_VIEW_HOST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 // RenderWidgetHostView implementation. 64 // RenderWidgetHostView implementation.
65 void InitAsChild(gfx::NativeView parent_view) override {} 65 void InitAsChild(gfx::NativeView parent_view) override {}
66 RenderWidgetHost* GetRenderWidgetHost() const override; 66 RenderWidgetHost* GetRenderWidgetHost() const override;
67 void SetSize(const gfx::Size& size) override {} 67 void SetSize(const gfx::Size& size) override {}
68 void SetBounds(const gfx::Rect& rect) override {} 68 void SetBounds(const gfx::Rect& rect) override {}
69 gfx::Vector2dF GetLastScrollOffset() const override; 69 gfx::Vector2dF GetLastScrollOffset() const override;
70 gfx::NativeView GetNativeView() const override; 70 gfx::NativeView GetNativeView() const override;
71 gfx::NativeViewAccessible GetNativeViewAccessible() override; 71 gfx::NativeViewAccessible GetNativeViewAccessible() override;
72 ui::TextInputClient* GetTextInputClient() override; 72 ui::TextInputClient* GetTextInputClient() override;
73 bool HasFocus() const override; 73 bool HasFocus() const override;
74 bool IsSurfaceAvailableForCopy() const override;
75 void Show() override; 74 void Show() override;
76 void Hide() override; 75 void Hide() override;
77 bool IsShowing() override; 76 bool IsShowing() override;
78 void WasUnOccluded() override; 77 void WasUnOccluded() override;
79 void WasOccluded() override; 78 void WasOccluded() override;
80 gfx::Rect GetViewBounds() const override; 79 gfx::Rect GetViewBounds() const override;
81 #if defined(OS_MACOSX) 80 #if defined(OS_MACOSX)
82 ui::AcceleratedWidgetMac* GetAcceleratedWidgetMac() const override; 81 ui::AcceleratedWidgetMac* GetAcceleratedWidgetMac() const override;
83 void SetActive(bool active) override; 82 void SetActive(bool active) override;
84 void ShowDefinitionForSelection() override {} 83 void ShowDefinitionForSelection() override {}
(...skipping 11 matching lines...) Expand all
96 void InitAsPopup(RenderWidgetHostView* parent_host_view, 95 void InitAsPopup(RenderWidgetHostView* parent_host_view,
97 const gfx::Rect& bounds) override {} 96 const gfx::Rect& bounds) override {}
98 void InitAsFullscreen(RenderWidgetHostView* reference_host_view) override {} 97 void InitAsFullscreen(RenderWidgetHostView* reference_host_view) override {}
99 void Focus() override {} 98 void Focus() override {}
100 void SetIsLoading(bool is_loading) override {} 99 void SetIsLoading(bool is_loading) override {}
101 void UpdateCursor(const WebCursor& cursor) override {} 100 void UpdateCursor(const WebCursor& cursor) override {}
102 void RenderProcessGone(base::TerminationStatus status, 101 void RenderProcessGone(base::TerminationStatus status,
103 int error_code) override; 102 int error_code) override;
104 void Destroy() override; 103 void Destroy() override;
105 void SetTooltipText(const base::string16& tooltip_text) override {} 104 void SetTooltipText(const base::string16& tooltip_text) override {}
106 void CopyFromCompositingSurface(
107 const gfx::Rect& src_subrect,
108 const gfx::Size& dst_size,
109 const ReadbackRequestCallback& callback,
110 const SkColorType preferred_color_type) override;
111 void CopyFromCompositingSurfaceToVideoFrame(
112 const gfx::Rect& src_subrect,
113 const scoped_refptr<media::VideoFrame>& target,
114 const base::Callback<void(const gfx::Rect&, bool)>& callback) override;
115 bool CanCopyToVideoFrame() const override;
116 bool HasAcceleratedSurface(const gfx::Size& desired_size) override; 105 bool HasAcceleratedSurface(const gfx::Size& desired_size) override;
117 gfx::Rect GetBoundsInRootWindow() override; 106 gfx::Rect GetBoundsInRootWindow() override;
118 bool LockMouse() override; 107 bool LockMouse() override;
119 void UnlockMouse() override; 108 void UnlockMouse() override;
120 cc::FrameSinkId GetFrameSinkId() override; 109 cc::FrameSinkId GetFrameSinkId() override;
121 110
122 bool is_showing() const { return is_showing_; } 111 bool is_showing() const { return is_showing_; }
123 bool is_occluded() const { return is_occluded_; } 112 bool is_occluded() const { return is_occluded_; }
124 bool did_swap_compositor_frame() const { return did_swap_compositor_frame_; } 113 bool did_swap_compositor_frame() const { return did_swap_compositor_frame_; }
125 114
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 private: 291 private:
303 typedef std::unique_ptr<ui::test::ScopedSetSupportedScaleFactors> 292 typedef std::unique_ptr<ui::test::ScopedSetSupportedScaleFactors>
304 ScopedSetSupportedScaleFactors; 293 ScopedSetSupportedScaleFactors;
305 ScopedSetSupportedScaleFactors scoped_set_supported_scale_factors_; 294 ScopedSetSupportedScaleFactors scoped_set_supported_scale_factors_;
306 DISALLOW_COPY_AND_ASSIGN(RenderViewHostImplTestHarness); 295 DISALLOW_COPY_AND_ASSIGN(RenderViewHostImplTestHarness);
307 }; 296 };
308 297
309 } // namespace content 298 } // namespace content
310 299
311 #endif // CONTENT_TEST_TEST_RENDER_VIEW_HOST_H_ 300 #endif // CONTENT_TEST_TEST_RENDER_VIEW_HOST_H_
OLDNEW
« no previous file with comments | « content/public/browser/render_widget_host_view.h ('k') | content/test/test_render_view_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698