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

Side by Side Diff: cc/layers/layer_impl.cc

Issue 2140783002: services/ui: Detect when a video is playing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tot merge Created 4 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
« no previous file with comments | « cc/layers/layer_impl.h ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/layers/layer_impl.h" 5 #include "cc/layers/layer_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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 : layer_id_(id), 52 : layer_id_(id),
53 layer_tree_impl_(tree_impl), 53 layer_tree_impl_(tree_impl),
54 test_properties_(nullptr), 54 test_properties_(nullptr),
55 scroll_clip_layer_id_(Layer::INVALID_ID), 55 scroll_clip_layer_id_(Layer::INVALID_ID),
56 main_thread_scrolling_reasons_( 56 main_thread_scrolling_reasons_(
57 MainThreadScrollingReason::kNotScrollingOnMain), 57 MainThreadScrollingReason::kNotScrollingOnMain),
58 user_scrollable_horizontal_(true), 58 user_scrollable_horizontal_(true),
59 user_scrollable_vertical_(true), 59 user_scrollable_vertical_(true),
60 should_flatten_transform_from_property_tree_(false), 60 should_flatten_transform_from_property_tree_(false),
61 layer_property_changed_(false), 61 layer_property_changed_(false),
62 may_contain_video_(false),
62 masks_to_bounds_(false), 63 masks_to_bounds_(false),
63 contents_opaque_(false), 64 contents_opaque_(false),
64 use_parent_backface_visibility_(false), 65 use_parent_backface_visibility_(false),
65 use_local_transform_for_backface_visibility_(false), 66 use_local_transform_for_backface_visibility_(false),
66 should_check_backface_visibility_(false), 67 should_check_backface_visibility_(false),
67 draws_content_(false), 68 draws_content_(false),
68 is_drawn_render_surface_layer_list_member_(false), 69 is_drawn_render_surface_layer_list_member_(false),
69 was_ever_ready_since_last_transform_animation_(true), 70 was_ever_ready_since_last_transform_animation_(true),
70 background_color_(0), 71 background_color_(0),
71 safe_opaque_background_color_(0), 72 safe_opaque_background_color_(0),
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 DCHECK(layer->IsActive()); 321 DCHECK(layer->IsActive());
321 322
322 layer->offset_to_transform_parent_ = offset_to_transform_parent_; 323 layer->offset_to_transform_parent_ = offset_to_transform_parent_;
323 layer->main_thread_scrolling_reasons_ = main_thread_scrolling_reasons_; 324 layer->main_thread_scrolling_reasons_ = main_thread_scrolling_reasons_;
324 layer->user_scrollable_horizontal_ = user_scrollable_horizontal_; 325 layer->user_scrollable_horizontal_ = user_scrollable_horizontal_;
325 layer->user_scrollable_vertical_ = user_scrollable_vertical_; 326 layer->user_scrollable_vertical_ = user_scrollable_vertical_;
326 layer->should_flatten_transform_from_property_tree_ = 327 layer->should_flatten_transform_from_property_tree_ =
327 should_flatten_transform_from_property_tree_; 328 should_flatten_transform_from_property_tree_;
328 layer->masks_to_bounds_ = masks_to_bounds_; 329 layer->masks_to_bounds_ = masks_to_bounds_;
329 layer->contents_opaque_ = contents_opaque_; 330 layer->contents_opaque_ = contents_opaque_;
331 layer->may_contain_video_ = may_contain_video_;
330 layer->use_parent_backface_visibility_ = use_parent_backface_visibility_; 332 layer->use_parent_backface_visibility_ = use_parent_backface_visibility_;
331 layer->use_local_transform_for_backface_visibility_ = 333 layer->use_local_transform_for_backface_visibility_ =
332 use_local_transform_for_backface_visibility_; 334 use_local_transform_for_backface_visibility_;
333 layer->should_check_backface_visibility_ = should_check_backface_visibility_; 335 layer->should_check_backface_visibility_ = should_check_backface_visibility_;
334 layer->draws_content_ = draws_content_; 336 layer->draws_content_ = draws_content_;
335 layer->non_fast_scrollable_region_ = non_fast_scrollable_region_; 337 layer->non_fast_scrollable_region_ = non_fast_scrollable_region_;
336 layer->touch_event_handler_region_ = touch_event_handler_region_; 338 layer->touch_event_handler_region_ = touch_event_handler_region_;
337 layer->background_color_ = background_color_; 339 layer->background_color_ = background_color_;
338 layer->safe_opaque_background_color_ = safe_opaque_background_color_; 340 layer->safe_opaque_background_color_ = safe_opaque_background_color_;
339 layer->draw_blend_mode_ = draw_blend_mode_; 341 layer->draw_blend_mode_ = draw_blend_mode_;
(...skipping 854 matching lines...) Expand 10 before | Expand all | Expand 10 after
1194 .layer_transforms_should_scale_layer_contents) { 1196 .layer_transforms_should_scale_layer_contents) {
1195 return default_scale; 1197 return default_scale;
1196 } 1198 }
1197 1199
1198 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents( 1200 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents(
1199 ScreenSpaceTransform(), default_scale); 1201 ScreenSpaceTransform(), default_scale);
1200 return std::max(transform_scales.x(), transform_scales.y()); 1202 return std::max(transform_scales.x(), transform_scales.y());
1201 } 1203 }
1202 1204
1203 } // namespace cc 1205 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/layer_impl.h ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698