Index: cc/layers/layer.cc |
diff --git a/cc/layers/layer.cc b/cc/layers/layer.cc |
index face433a808db2c90727fb0b55880b4d3bddcf8e..b69cadb468ccdab72db33adb9e6400a130663197 100644 |
--- a/cc/layers/layer.cc |
+++ b/cc/layers/layer.cc |
@@ -71,6 +71,7 @@ Layer::Layer() |
force_render_surface_(false), |
transform_is_invertible_(true), |
has_render_surface_(false), |
+ scroll_blocks_on_(ScrollBlocksOnNone), |
jdduke (slow)
2015/02/03 16:43:35
I wonder if it's worth a static assert for ScrollB
Rick Byers
2015/02/05 04:35:53
Sure, done. I also updated my COMPILE_ASSERTs to
|
background_color_(0), |
opacity_(1.f), |
blend_mode_(SkXfermode::kSrcOver_Mode), |
@@ -758,6 +759,14 @@ void Layer::SetTouchEventHandlerRegion(const Region& region) { |
SetNeedsCommit(); |
} |
+void Layer::SetScrollBlocksOn(ScrollBlocksOn scroll_blocks_on) { |
+ DCHECK(IsPropertyChangeAllowed()); |
+ if (scroll_blocks_on_ == scroll_blocks_on) |
+ return; |
+ scroll_blocks_on_ = scroll_blocks_on; |
+ SetNeedsCommit(); |
+} |
+ |
void Layer::SetDrawCheckerboardForMissingTiles(bool checkerboard) { |
DCHECK(IsPropertyChangeAllowed()); |
if (draw_checkerboard_for_missing_tiles_ == checkerboard) |
@@ -911,6 +920,7 @@ void Layer::PushPropertiesTo(LayerImpl* layer) { |
layer->SetHaveScrollEventHandlers(have_scroll_event_handlers_); |
layer->SetNonFastScrollableRegion(non_fast_scrollable_region_); |
layer->SetTouchEventHandlerRegion(touch_event_handler_region_); |
+ layer->SetScrollBlocksOn(scroll_blocks_on_); |
layer->SetContentsOpaque(contents_opaque_); |
if (!layer->OpacityIsAnimatingOnImplOnly() && !OpacityIsAnimating()) |
layer->SetOpacity(opacity_); |