Chromium Code Reviews| Index: components/exo/surface.h |
| diff --git a/components/exo/surface.h b/components/exo/surface.h |
| index 016fe113fd6c175dbcb01257c4cceededf6712ea..0822fe56b0e0a3bf264abd94a4100019cf3ea7e9 100644 |
| --- a/components/exo/surface.h |
| +++ b/components/exo/surface.h |
| @@ -219,11 +219,22 @@ class Surface : public aura::Window, |
| void WillDraw(cc::SurfaceId surface_id); |
| + // Check whether this Surface and its children need to create new cc::Surface |
| + // IDs for their contents next time they get new buffer contents. |
| + void CheckForCommittingToNewSurface(); |
| + |
| private: |
| bool needs_commit_surface_hierarchy() const { |
| return needs_commit_surface_hierarchy_; |
| } |
| + // Returns true if any child surface needs a commit and has |
| + // modified_layer_info_ true. |
| + bool HaveChildLayersChanged(); |
| + |
| + // Sets that all children must create new cc::SurfaceIds for their contents. |
| + void SetChildrenCommitToNewSurface(); |
| + |
| // Commit the current attached buffer to a TextureLayer. |
| void CommitTextureContents(); |
| @@ -243,6 +254,16 @@ class Surface : public aura::Window, |
| // rather than a TextureLayer. |
| static bool use_surface_layer_; |
| + // This is true if it's possible that the layer properties (size, opacity, |
| + // etc.) may have been modified since the last commit. Attaching a new |
| + // buffer with the same size as the old shouldn't set this to true. |
| + bool modified_layer_info_ = true; |
| + |
| + // This is true if the next commit to this surface should put its contents |
| + // into a new cc::SurfaceId. This allows for synchronization between Surface |
| + // and layer changes. |
| + bool commit_to_new_surface_ = true; |
| + |
|
reveman
2016/06/09 14:19:29
Check my comments in the .cc file but I'm curious
|
| // This is true when Attach() has been called and new contents should take |
| // effect next time Commit() is called. |
| bool has_pending_contents_; |