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

Unified Diff: cc/layer_tree_host_impl.h

Issue 11552009: Add support for calculating the position of the top controls in the cc layer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: cc/layer_tree_host_impl.h
diff --git a/cc/layer_tree_host_impl.h b/cc/layer_tree_host_impl.h
index 5f46811dcfadba9a078cfc61b5c8745c5334c8fd..a2b6b5b5cb9cf870bc7dfb442110e9df771ff5ee 100644
--- a/cc/layer_tree_host_impl.h
+++ b/cc/layer_tree_host_impl.h
@@ -17,6 +17,7 @@
#include "cc/render_pass_sink.h"
#include "cc/renderer.h"
#include "cc/tile_manager.h"
+#include "cc/top_controls_manager_client.h"
#include "third_party/skia/include/core/SkColor.h"
#include "ui/gfx/rect.h"
@@ -32,6 +33,7 @@ class LayerTreeImpl;
class PageScaleAnimation;
class RenderPassDrawQuad;
class ResourceProvider;
+class TopControlsManager;
struct RendererCapabilities;
struct RenderingStats;
@@ -115,7 +117,8 @@ private:
class CC_EXPORT LayerTreeHostImpl : public InputHandlerClient,
public RendererClient,
public TileManagerClient,
- public OutputSurfaceClient {
+ public OutputSurfaceClient,
+ public TopControlsManagerClient {
typedef std::vector<LayerImpl*> LayerList;
public:
@@ -207,7 +210,7 @@ public:
void readback(void* pixels, const gfx::Rect&);
- LayerTreeImpl* activeTree() { return m_activeTree.get(); }
+ virtual LayerTreeImpl* activeTree() OVERRIDE; // TopControlsManagerClient implementation.
jamesr 2013/01/08 02:26:48 put this comment on the previous line
Ted C 2013/01/08 18:17:33 Done. (moved them all up as suggested below)
const LayerTreeImpl* activeTree() const { return m_activeTree.get(); }
LayerTreeImpl* pendingTree() { return m_pendingTree.get(); }
const LayerTreeImpl* pendingTree() const { return m_pendingTree.get(); }
@@ -244,9 +247,9 @@ public:
bool needsAnimateLayers() const { return !m_animationRegistrar->active_animation_controllers().empty(); }
bool needsUpdateDrawProperties() const { return m_needsUpdateDrawProperties; }
- void setNeedsUpdateDrawProperties() { m_needsUpdateDrawProperties = true; }
+ virtual void setNeedsUpdateDrawProperties() OVERRIDE; // TopControlsManagerClient implementation.
jamesr 2013/01/08 02:26:48 put the comment on the previous line and just have
enne (OOO) 2013/01/08 06:23:05 You should also group all these functions, like In
Ted C 2013/01/08 18:17:33 Done.
- void setNeedsRedraw();
+ virtual void setNeedsRedraw() OVERRIDE; // TopControlsManagerClient implementation.
void renderingStats(RenderingStats*) const;
@@ -368,6 +371,8 @@ private:
bool m_pinchGestureActive;
gfx::Point m_previousPinchAnchor;
+ scoped_ptr<TopControlsManager> m_topControlsManager;
+
scoped_ptr<PageScaleAnimation> m_pageScaleAnimation;
// This is used for ticking animations slowly when hidden.

Powered by Google App Engine
This is Rietveld 408576698