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

Side by Side Diff: ui/compositor/layer.h

Issue 10700028: Prepare for WebContentLayerClient API change (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | « no previous file | ui/compositor/layer.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 UI_COMPOSITOR_LAYER_H_ 5 #ifndef UI_COMPOSITOR_LAYER_H_
6 #define UI_COMPOSITOR_LAYER_H_ 6 #define UI_COMPOSITOR_LAYER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 // Returns true if the layer scales its content. 222 // Returns true if the layer scales its content.
223 bool scale_content() const { return scale_content_; } 223 bool scale_content() const { return scale_content_; }
224 224
225 // Sometimes the Layer is being updated by something other than SetCanvas 225 // Sometimes the Layer is being updated by something other than SetCanvas
226 // (e.g. the GPU process on UI_COMPOSITOR_IMAGE_TRANSPORT). 226 // (e.g. the GPU process on UI_COMPOSITOR_IMAGE_TRANSPORT).
227 bool layer_updated_externally() const { return layer_updated_externally_; } 227 bool layer_updated_externally() const { return layer_updated_externally_; }
228 228
229 // WebContentLayerClient 229 // WebContentLayerClient
230 virtual void paintContents(WebKit::WebCanvas*, 230 virtual void paintContents(WebKit::WebCanvas*,
231 const WebKit::WebRect& clip, 231 const WebKit::WebRect& clip,
232 #if defined(WEBCONTENTLAYERCLIENT_FLOAT_OPAQUE_RECT)
233 WebKit::WebFloatRect& opaque);
234 #else
232 WebKit::WebRect& opaque); 235 WebKit::WebRect& opaque);
236 #endif
233 237
234 WebKit::WebLayer web_layer() { return web_layer_; } 238 WebKit::WebLayer web_layer() { return web_layer_; }
235 239
236 float device_scale_factor() const { return device_scale_factor_; } 240 float device_scale_factor() const { return device_scale_factor_; }
237 241
238 // Forces a render surface to be used on this layer. This has no positive 242 // Forces a render surface to be used on this layer. This has no positive
239 // impact, and is only used for benchmarking/testing purpose. 243 // impact, and is only used for benchmarking/testing purpose.
240 void SetForceRenderSurface(bool force); 244 void SetForceRenderSurface(bool force);
241 bool force_render_surface() const { return force_render_surface_; } 245 bool force_render_surface() const { return force_render_surface_; }
242 246
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 346
343 // A cached copy of |Compositor::device_scale_factor()|. 347 // A cached copy of |Compositor::device_scale_factor()|.
344 float device_scale_factor_; 348 float device_scale_factor_;
345 349
346 DISALLOW_COPY_AND_ASSIGN(Layer); 350 DISALLOW_COPY_AND_ASSIGN(Layer);
347 }; 351 };
348 352
349 } // namespace ui 353 } // namespace ui
350 354
351 #endif // UI_COMPOSITOR_LAYER_H_ 355 #endif // UI_COMPOSITOR_LAYER_H_
OLDNEW
« no previous file with comments | « no previous file | ui/compositor/layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698