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

Unified Diff: cc/tile.cc

Issue 12289020: cc: Make the TileManager operate on ManagedTileState directly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix clang dtor nits Created 7 years, 10 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
« no previous file with comments | « cc/tile.h ('k') | cc/tile_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/tile.cc
diff --git a/cc/tile.cc b/cc/tile.cc
index 1f750cbde7fb9fad9b9145fc1560c8320a887825..7c6a58fbbbf68c5aa56e8bdc7634db8583925745 100644
--- a/cc/tile.cc
+++ b/cc/tile.cc
@@ -23,12 +23,12 @@ Tile::Tile(TileManager* tile_manager,
format_(format),
content_rect_(content_rect),
opaque_rect_(opaque_rect),
- contents_scale_(contents_scale) {
- tile_manager_->RegisterTile(this);
+ contents_scale_(contents_scale),
+ managed_state_(NULL) {
}
Tile::~Tile() {
- tile_manager_->UnregisterTile(this);
+ DCHECK(!managed_state_);
}
scoped_ptr<base::Value> Tile::AsValue() const {
@@ -39,7 +39,7 @@ scoped_ptr<base::Value> Tile::AsValue() const {
res->SetDouble("contents_scale", contents_scale_);
res->Set("priority.0", priority_[ACTIVE_TREE].AsValue().release());
res->Set("priority.1", priority_[PENDING_TREE].AsValue().release());
- res->Set("managed_state", managed_state_.AsValue().release());
+ res->Set("managed_state", managed_state_->AsValue().release());
return res.PassAs<base::Value>();
}
« no previous file with comments | « cc/tile.h ('k') | cc/tile_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698