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

Side by Side Diff: cc/trees/layer_tree_host.cc

Issue 21839004: cc: Push valid property values when CalcDrawProps skips layer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: pushpaintprops: Simpler to dcheck in TiledLayer Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/trees/layer_tree_host.h" 5 #include "cc/trees/layer_tree_host.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <stack> 8 #include <stack>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after
671 return !output_surface_lost_; 671 return !output_surface_lost_;
672 } 672 }
673 673
674 bool LayerTreeHost::UpdateLayers(ResourceUpdateQueue* queue, 674 bool LayerTreeHost::UpdateLayers(ResourceUpdateQueue* queue,
675 size_t memory_allocation_limit_bytes) { 675 size_t memory_allocation_limit_bytes) {
676 DCHECK(!output_surface_lost_); 676 DCHECK(!output_surface_lost_);
677 677
678 if (!root_layer()) 678 if (!root_layer())
679 return false; 679 return false;
680 680
681 if (device_viewport_size().IsEmpty())
enne (OOO) 2013/08/02 17:00:48 This is wrong for WebView. You can't just add it
boliu 2013/08/02 17:44:50 Not commenting on correctness, just a question: I
enne (OOO) 2013/08/02 17:47:41 It is possible, but in that case the compositor th
danakj 2013/08/02 18:35:11 I think checkerboards should be fine in this case.
enne (OOO) 2013/08/02 18:41:49 Checkerboarding would be wrong for software raster
danakj 2013/08/02 21:49:13 Ah, okie.
682 return false;
683
681 if (contents_texture_manager_ && memory_allocation_limit_bytes) { 684 if (contents_texture_manager_ && memory_allocation_limit_bytes) {
682 contents_texture_manager_->SetMaxMemoryLimitBytes( 685 contents_texture_manager_->SetMaxMemoryLimitBytes(
683 memory_allocation_limit_bytes); 686 memory_allocation_limit_bytes);
684 } 687 }
685 688
686 return UpdateLayers(root_layer(), queue); 689 return UpdateLayers(root_layer(), queue);
687 } 690 }
688 691
689 static Layer* FindFirstScrollableLayer(Layer* layer) { 692 static Layer* FindFirstScrollableLayer(Layer* layer) {
690 if (!layer) 693 if (!layer)
(...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after
1168 void LayerTreeHost::DidLoseUIResources() { 1171 void LayerTreeHost::DidLoseUIResources() {
1169 // When output surface is lost, we need to recreate the resource. 1172 // When output surface is lost, we need to recreate the resource.
1170 for (UIResourceClientMap::iterator iter = ui_resource_client_map_.begin(); 1173 for (UIResourceClientMap::iterator iter = ui_resource_client_map_.begin();
1171 iter != ui_resource_client_map_.end(); 1174 iter != ui_resource_client_map_.end();
1172 ++iter) { 1175 ++iter) {
1173 UIResourceLost(iter->first); 1176 UIResourceLost(iter->first);
1174 } 1177 }
1175 } 1178 }
1176 1179
1177 } // namespace cc 1180 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698