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

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

Issue 2514033002: Introducing SurfaceReferenceFactory (Closed)
Patch Set: up Created 4 years 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
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_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 1540 matching lines...) Expand 10 before | Expand all | Expand 10 after
1551 !OuterViewportScrollLayer()->user_scrollable_vertical(); 1551 !OuterViewportScrollLayer()->user_scrollable_vertical();
1552 } 1552 }
1553 1553
1554 if (GetDrawMode() == DRAW_MODE_RESOURCELESS_SOFTWARE) { 1554 if (GetDrawMode() == DRAW_MODE_RESOURCELESS_SOFTWARE) {
1555 metadata.is_resourceless_software_draw_with_scroll_or_animation = 1555 metadata.is_resourceless_software_draw_with_scroll_or_animation =
1556 IsActivelyScrolling() || mutator_host_->NeedsTickAnimations(); 1556 IsActivelyScrolling() || mutator_host_->NeedsTickAnimations();
1557 } 1557 }
1558 1558
1559 for (LayerImpl* surface_layer : active_tree_->SurfaceLayers()) { 1559 for (LayerImpl* surface_layer : active_tree_->SurfaceLayers()) {
1560 metadata.referenced_surfaces.push_back( 1560 metadata.referenced_surfaces.push_back(
1561 static_cast<SurfaceLayerImpl*>(surface_layer)->surface_id()); 1561 static_cast<SurfaceLayerImpl*>(surface_layer)->surface_info().id);
1562 } 1562 }
1563 if (!InnerViewportScrollLayer()) 1563 if (!InnerViewportScrollLayer())
1564 return metadata; 1564 return metadata;
1565 1565
1566 metadata.root_overflow_x_hidden |= 1566 metadata.root_overflow_x_hidden |=
1567 !InnerViewportScrollLayer()->user_scrollable_horizontal(); 1567 !InnerViewportScrollLayer()->user_scrollable_horizontal();
1568 metadata.root_overflow_y_hidden |= 1568 metadata.root_overflow_y_hidden |=
1569 !InnerViewportScrollLayer()->user_scrollable_vertical(); 1569 !InnerViewportScrollLayer()->user_scrollable_vertical();
1570 1570
1571 // TODO(miletus) : Change the metadata to hold ScrollOffset. 1571 // TODO(miletus) : Change the metadata to hold ScrollOffset.
(...skipping 2511 matching lines...) Expand 10 before | Expand all | Expand 10 after
4083 worker_context_visibility_ = 4083 worker_context_visibility_ =
4084 worker_context->CacheController()->ClientBecameVisible(); 4084 worker_context->CacheController()->ClientBecameVisible();
4085 } else { 4085 } else {
4086 worker_context->CacheController()->ClientBecameNotVisible( 4086 worker_context->CacheController()->ClientBecameNotVisible(
4087 std::move(worker_context_visibility_)); 4087 std::move(worker_context_visibility_));
4088 } 4088 }
4089 } 4089 }
4090 } 4090 }
4091 4091
4092 } // namespace cc 4092 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698