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

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

Issue 2375363002: cc/blimp: Set up the framework for state serialization. (Closed)
Patch Set: test update Created 4 years, 2 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/solid_color_scrollbar_layer.h ('k') | cc/proto/compositor_message.proto » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/solid_color_scrollbar_layer.h" 5 #include "cc/layers/solid_color_scrollbar_layer.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "cc/layers/layer_impl.h" 9 #include "cc/layers/layer_impl.h"
10 #include "cc/layers/solid_color_scrollbar_layer_impl.h" 10 #include "cc/layers/solid_color_scrollbar_layer_impl.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 ScrollbarOrientation SolidColorScrollbarLayer::orientation() const { 112 ScrollbarOrientation SolidColorScrollbarLayer::orientation() const {
113 return solid_color_scrollbar_layer_inputs_.orientation; 113 return solid_color_scrollbar_layer_inputs_.orientation;
114 } 114 }
115 115
116 void SolidColorScrollbarLayer::SetTypeForProtoSerialization( 116 void SolidColorScrollbarLayer::SetTypeForProtoSerialization(
117 proto::LayerNode* proto) const { 117 proto::LayerNode* proto) const {
118 proto->set_type(proto::LayerNode::SOLID_COLOR_SCROLLBAR_LAYER); 118 proto->set_type(proto::LayerNode::SOLID_COLOR_SCROLLBAR_LAYER);
119 } 119 }
120 120
121 void SolidColorScrollbarLayer::LayerSpecificPropertiesToProto( 121 void SolidColorScrollbarLayer::LayerSpecificPropertiesToProto(
122 proto::LayerProperties* proto) { 122 proto::LayerProperties* proto,
123 Layer::LayerSpecificPropertiesToProto(proto); 123 bool inputs_only) {
124 Layer::LayerSpecificPropertiesToProto(proto, inputs_only);
124 125
125 proto::SolidColorScrollbarLayerProperties* scrollbar = 126 proto::SolidColorScrollbarLayerProperties* scrollbar =
126 proto->mutable_solid_scrollbar(); 127 proto->mutable_solid_scrollbar();
127 scrollbar->set_scroll_layer_id( 128 scrollbar->set_scroll_layer_id(
128 solid_color_scrollbar_layer_inputs_.scroll_layer_id); 129 solid_color_scrollbar_layer_inputs_.scroll_layer_id);
129 scrollbar->set_thumb_thickness( 130 scrollbar->set_thumb_thickness(
130 solid_color_scrollbar_layer_inputs_.thumb_thickness); 131 solid_color_scrollbar_layer_inputs_.thumb_thickness);
131 scrollbar->set_track_start(solid_color_scrollbar_layer_inputs_.track_start); 132 scrollbar->set_track_start(solid_color_scrollbar_layer_inputs_.track_start);
132 scrollbar->set_is_left_side_vertical_scrollbar( 133 scrollbar->set_is_left_side_vertical_scrollbar(
133 solid_color_scrollbar_layer_inputs_.is_left_side_vertical_scrollbar); 134 solid_color_scrollbar_layer_inputs_.is_left_side_vertical_scrollbar);
(...skipping 12 matching lines...) Expand all
146 solid_color_scrollbar_layer_inputs_.thumb_thickness = 147 solid_color_scrollbar_layer_inputs_.thumb_thickness =
147 scrollbar.thumb_thickness(); 148 scrollbar.thumb_thickness();
148 solid_color_scrollbar_layer_inputs_.track_start = scrollbar.track_start(); 149 solid_color_scrollbar_layer_inputs_.track_start = scrollbar.track_start();
149 solid_color_scrollbar_layer_inputs_.is_left_side_vertical_scrollbar = 150 solid_color_scrollbar_layer_inputs_.is_left_side_vertical_scrollbar =
150 scrollbar.is_left_side_vertical_scrollbar(); 151 scrollbar.is_left_side_vertical_scrollbar();
151 solid_color_scrollbar_layer_inputs_.orientation = 152 solid_color_scrollbar_layer_inputs_.orientation =
152 ScrollbarOrientationFromProto(scrollbar.orientation()); 153 ScrollbarOrientationFromProto(scrollbar.orientation());
153 } 154 }
154 155
155 } // namespace cc 156 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/solid_color_scrollbar_layer.h ('k') | cc/proto/compositor_message.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698