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

Unified Diff: cc/picture_layer_tiling_set.cc

Issue 11418108: cc: Make the ScopedPtrVector and ScopedPtrDeque containers act like STL vector and deque. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: android!! 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
« no previous file with comments | « cc/layer_tree_impl.cc ('k') | cc/quad_culler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/picture_layer_tiling_set.cc
diff --git a/cc/picture_layer_tiling_set.cc b/cc/picture_layer_tiling_set.cc
index 9edf8479d7352583cc1effdc2e4139d884dcbb6d..e4bbd57d8280fbd38d35133db325b92f051e57d0 100644
--- a/cc/picture_layer_tiling_set.cc
+++ b/cc/picture_layer_tiling_set.cc
@@ -20,10 +20,10 @@ void PictureLayerTilingSet::CloneAll(
tilings_.clear();
tilings_.reserve(other.tilings_.size());
for (size_t i = 0; i < other.tilings_.size(); ++i) {
- tilings_.append(other.tilings_[i]->Clone());
- tilings_.last()->SetLayerBounds(LayerBounds());
- tilings_.last()->SetClient(client_);
- tilings_.last()->Invalidate(invalidation);
+ tilings_.push_back(other.tilings_[i]->Clone());
+ tilings_.back()->SetLayerBounds(LayerBounds());
+ tilings_.back()->SetClient(client_);
+ tilings_.back()->Invalidate(invalidation);
}
}
@@ -34,9 +34,9 @@ void PictureLayerTilingSet::Clone(
for (size_t i = 0; i < tilings_.size(); ++i)
DCHECK_NE(tilings_[i]->contents_scale(), tiling->contents_scale());
- tilings_.append(tiling->Clone());
- tilings_.last()->SetClient(client_);
- tilings_.last()->Invalidate(invalidation);
+ tilings_.push_back(tiling->Clone());
+ tilings_.back()->SetClient(client_);
+ tilings_.back()->Invalidate(invalidation);
}
void PictureLayerTilingSet::SetLayerBounds(gfx::Size layer_bounds) {
@@ -54,10 +54,10 @@ gfx::Size PictureLayerTilingSet::LayerBounds() const {
const PictureLayerTiling* PictureLayerTilingSet::AddTiling(
float contents_scale,
gfx::Size tile_size) {
- tilings_.append(PictureLayerTiling::Create(contents_scale, tile_size));
- tilings_.last()->SetClient(client_);
- tilings_.last()->SetLayerBounds(layer_bounds_);
- return tilings_.last();
+ tilings_.push_back(PictureLayerTiling::Create(contents_scale, tile_size));
+ tilings_.back()->SetClient(client_);
+ tilings_.back()->SetLayerBounds(layer_bounds_);
+ return tilings_.back();
}
void PictureLayerTilingSet::Reset() {
« no previous file with comments | « cc/layer_tree_impl.cc ('k') | cc/quad_culler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698