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

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_base.h

Issue 374633002: SkBitmap::Config is deprecated, use SkColorType instead (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments from #4 Created 6 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 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_
7 7
8 #if defined(OS_MACOSX) 8 #if defined(OS_MACOSX)
9 #include <OpenGL/OpenGL.h> 9 #include <OpenGL/OpenGL.h>
10 #endif 10 #endif
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 153
154 // Create a BrowserAccessibilityManager for this view if it's possible to 154 // Create a BrowserAccessibilityManager for this view if it's possible to
155 // create one and if one doesn't exist already. Some ports may not create 155 // create one and if one doesn't exist already. Some ports may not create
156 // one depending on the current state. 156 // one depending on the current state.
157 virtual void CreateBrowserAccessibilityManagerIfNeeded(); 157 virtual void CreateBrowserAccessibilityManagerIfNeeded();
158 158
159 virtual void OnAccessibilitySetFocus(int acc_obj_id); 159 virtual void OnAccessibilitySetFocus(int acc_obj_id);
160 virtual void AccessibilityShowMenu(int acc_obj_id); 160 virtual void AccessibilityShowMenu(int acc_obj_id);
161 virtual gfx::Point AccessibilityOriginInScreen(const gfx::Rect& bounds); 161 virtual gfx::Point AccessibilityOriginInScreen(const gfx::Rect& bounds);
162 162
163 virtual SkBitmap::Config PreferredReadbackFormat(); 163 virtual SkColorType PreferredReadbackFormat();
164 164
165 // Informs that the focused DOM node has changed. 165 // Informs that the focused DOM node has changed.
166 virtual void FocusedNodeChanged(bool is_editable_node) {} 166 virtual void FocusedNodeChanged(bool is_editable_node) {}
167 167
168 virtual void OnSwapCompositorFrame(uint32 output_surface_id, 168 virtual void OnSwapCompositorFrame(uint32 output_surface_id,
169 scoped_ptr<cc::CompositorFrame> frame) {} 169 scoped_ptr<cc::CompositorFrame> frame) {}
170 170
171 // Because the associated remote WebKit instance can asynchronously 171 // Because the associated remote WebKit instance can asynchronously
172 // prevent-default on a dispatched touch event, the touch events are queued in 172 // prevent-default on a dispatched touch event, the touch events are queued in
173 // the GestureRecognizer until invocation of ProcessAckedTouchEvent releases 173 // the GestureRecognizer until invocation of ProcessAckedTouchEvent releases
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 // contents, scaled to |dst_size|, and written to |output|. 253 // contents, scaled to |dst_size|, and written to |output|.
254 // |callback| is invoked with true on success, false otherwise. |output| can 254 // |callback| is invoked with true on success, false otherwise. |output| can
255 // be initialized even on failure. 255 // be initialized even on failure.
256 // A smaller region than |src_subrect| may be copied if the underlying surface 256 // A smaller region than |src_subrect| may be copied if the underlying surface
257 // is smaller than |src_subrect|. 257 // is smaller than |src_subrect|.
258 // NOTE: |callback| is called asynchronously. 258 // NOTE: |callback| is called asynchronously.
259 virtual void CopyFromCompositingSurface( 259 virtual void CopyFromCompositingSurface(
260 const gfx::Rect& src_subrect, 260 const gfx::Rect& src_subrect,
261 const gfx::Size& dst_size, 261 const gfx::Size& dst_size,
262 const base::Callback<void(bool, const SkBitmap&)>& callback, 262 const base::Callback<void(bool, const SkBitmap&)>& callback,
263 const SkBitmap::Config config) = 0; 263 const SkColorType color_type) = 0;
264 264
265 // Copies a given subset of the compositing surface's content into a YV12 265 // Copies a given subset of the compositing surface's content into a YV12
266 // VideoFrame, and invokes a callback with a success/fail parameter. |target| 266 // VideoFrame, and invokes a callback with a success/fail parameter. |target|
267 // must contain an allocated, YV12 video frame of the intended size. If the 267 // must contain an allocated, YV12 video frame of the intended size. If the
268 // copy rectangle does not match |target|'s size, the copied content will be 268 // copy rectangle does not match |target|'s size, the copied content will be
269 // scaled and letterboxed with black borders. The copy will happen 269 // scaled and letterboxed with black borders. The copy will happen
270 // asynchronously. This operation will fail if there is no available 270 // asynchronously. This operation will fail if there is no available
271 // compositing surface. 271 // compositing surface.
272 virtual void CopyFromCompositingSurfaceToVideoFrame( 272 virtual void CopyFromCompositingSurfaceToVideoFrame(
273 const gfx::Rect& src_subrect, 273 const gfx::Rect& src_subrect,
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
434 uint32 renderer_frame_number_; 434 uint32 renderer_frame_number_;
435 435
436 base::OneShotTimer<RenderWidgetHostViewBase> flush_input_timer_; 436 base::OneShotTimer<RenderWidgetHostViewBase> flush_input_timer_;
437 437
438 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase); 438 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase);
439 }; 439 };
440 440
441 } // namespace content 441 } // namespace content
442 442
443 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ 443 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698