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

Unified Diff: cc/surfaces/surface.h

Issue 432093003: Enqueuing new frames in a Surface should cause Displays to reaggregate it (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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/surfaces/surface.h
diff --git a/cc/surfaces/surface.h b/cc/surfaces/surface.h
index 403d2e56baf6f8a575509050152fb4bc90bccbc8..9ab823cc50cf3626863a4a393a10b6df41dbe26a 100644
--- a/cc/surfaces/surface.h
+++ b/cc/surfaces/surface.h
@@ -5,6 +5,8 @@
#ifndef CC_SURFACES_SURFACE_H_
#define CC_SURFACES_SURFACE_H_
+#include <set>
+
#include "base/containers/hash_tables.h"
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
@@ -14,6 +16,7 @@
namespace cc {
class CompositorFrame;
+class Display;
class SurfaceManager;
class SurfaceFactory;
class SurfaceResourceHolder;
@@ -31,6 +34,7 @@ class CC_SURFACES_EXPORT Surface {
const CompositorFrame* GetEligibleFrame();
SurfaceFactory* factory() { return factory_; }
+ std::set<Display*>& containing_displays() { return containing_displays_; }
private:
SurfaceId surface_id_;
@@ -39,6 +43,10 @@ class CC_SURFACES_EXPORT Surface {
// TODO(jamesr): Support multiple frames in flight.
scoped_ptr<CompositorFrame> current_frame_;
+ // This is the set of Displays that used this surface the last time they
+ // drew.
+ std::set<Display*> containing_displays_;
+
DISALLOW_COPY_AND_ASSIGN(Surface);
};

Powered by Google App Engine
This is Rietveld 408576698