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

Side by Side Diff: cc/test/animation_timelines_test_common.cc

Issue 1222243005: Fix unused variables errors in cc/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@nacl_private_fields
Patch Set: review comments Created 5 years, 5 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/test/animation_timelines_test_common.h ('k') | cc/trees/layer_tree_host.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/test/animation_timelines_test_common.h" 5 #include "cc/test/animation_timelines_test_common.h"
6 6
7 #include "cc/animation/animation_events.h" 7 #include "cc/animation/animation_events.h"
8 #include "cc/animation/animation_id_provider.h" 8 #include "cc/animation/animation_id_provider.h"
9 #include "cc/animation/animation_player.h" 9 #include "cc/animation/animation_player.h"
10 #include "cc/animation/animation_registrar.h" 10 #include "cc/animation/animation_registrar.h"
(...skipping 17 matching lines...) Expand all
28 transform_x_ = 0; 28 transform_x_ = 0;
29 transform_y_ = 0; 29 transform_y_ = 0;
30 30
31 opacity_ = 0; 31 opacity_ = 0;
32 brightness_ = 0; 32 brightness_ = 0;
33 33
34 for (int i = 0; i <= Animation::LAST_TARGET_PROPERTY; ++i) 34 for (int i = 0; i <= Animation::LAST_TARGET_PROPERTY; ++i)
35 mutated_properties_[i] = false; 35 mutated_properties_[i] = false;
36 } 36 }
37 37
38 TestHostClient::TestHostClient(ThreadInstance thread_instance) 38 TestHostClient::TestHostClient()
39 : host_(AnimationHost::Create(thread_instance)), 39 : host_(AnimationHost::Create()), mutators_need_commit_(false) {
40 mutators_need_commit_(false) {
41 host_->SetMutatorHostClient(this); 40 host_->SetMutatorHostClient(this);
42 } 41 }
43 42
44 TestHostClient::~TestHostClient() { 43 TestHostClient::~TestHostClient() {
45 host_->SetMutatorHostClient(nullptr); 44 host_->SetMutatorHostClient(nullptr);
46 } 45 }
47 46
48 void TestHostClient::ClearMutatedProperties() { 47 void TestHostClient::ClearMutatedProperties() {
49 for (auto& kv : layers_in_pending_tree_) 48 for (auto& kv : layers_in_pending_tree_)
50 kv.second->ClearMutatedProperties(); 49 kv.second->ClearMutatedProperties();
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 started_ = true; 185 started_ = true;
187 } 186 }
188 void TestAnimationDelegate::NotifyAnimationFinished( 187 void TestAnimationDelegate::NotifyAnimationFinished(
189 base::TimeTicks monotonic_time, 188 base::TimeTicks monotonic_time,
190 Animation::TargetProperty target_property, 189 Animation::TargetProperty target_property,
191 int group) { 190 int group) {
192 finished_ = true; 191 finished_ = true;
193 } 192 }
194 193
195 AnimationTimelinesTest::AnimationTimelinesTest() 194 AnimationTimelinesTest::AnimationTimelinesTest()
196 : client_(ThreadInstance::MAIN), 195 : timeline_id_(AnimationIdProvider::NextTimelineId()),
197 client_impl_(ThreadInstance::IMPL),
198 timeline_id_(AnimationIdProvider::NextTimelineId()),
199 player_id_(AnimationIdProvider::NextPlayerId()), 196 player_id_(AnimationIdProvider::NextPlayerId()),
200 layer_id_(1) { 197 layer_id_(1) {
201 host_ = client_.host(); 198 host_ = client_.host();
202 host_impl_ = client_impl_.host(); 199 host_impl_ = client_impl_.host();
203 } 200 }
204 201
205 AnimationTimelinesTest::~AnimationTimelinesTest() { 202 AnimationTimelinesTest::~AnimationTimelinesTest() {
206 } 203 }
207 204
208 void AnimationTimelinesTest::SetUp() { 205 void AnimationTimelinesTest::SetUp() {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
247 } 244 }
248 245
249 AnimationPlayer* AnimationTimelinesTest::GetImplPlayerForLayerId(int layer_id) { 246 AnimationPlayer* AnimationTimelinesTest::GetImplPlayerForLayerId(int layer_id) {
250 const ElementAnimations* element_animations = 247 const ElementAnimations* element_animations =
251 host_impl_->GetElementAnimationsForLayerId(layer_id); 248 host_impl_->GetElementAnimationsForLayerId(layer_id);
252 return element_animations ? element_animations->players_list().head()->value() 249 return element_animations ? element_animations->players_list().head()->value()
253 : nullptr; 250 : nullptr;
254 } 251 }
255 252
256 } // namespace cc 253 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/animation_timelines_test_common.h ('k') | cc/trees/layer_tree_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698