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

Side by Side Diff: cc/animation/animation_player.cc

Issue 2860293002: Change cc::ElementId to be a uint64_t (Closed)
Patch Set: none Created 3 years, 7 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
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/animation/animation_player.h" 5 #include "cc/animation/animation_player.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "cc/animation/animation_delegate.h" 10 #include "cc/animation/animation_delegate.h"
11 #include "cc/animation/animation_events.h" 11 #include "cc/animation/animation_events.h"
12 #include "cc/animation/animation_host.h" 12 #include "cc/animation/animation_host.h"
13 #include "cc/animation/animation_timeline.h" 13 #include "cc/animation/animation_timeline.h"
14 #include "cc/animation/scroll_offset_animation_curve.h" 14 #include "cc/animation/scroll_offset_animation_curve.h"
15 #include "cc/trees/property_animation_state.h" 15 #include "cc/trees/property_animation_state.h"
16 16
17 namespace cc { 17 namespace cc {
18 18
19 scoped_refptr<AnimationPlayer> AnimationPlayer::Create(int id) { 19 scoped_refptr<AnimationPlayer> AnimationPlayer::Create(int id) {
20 return make_scoped_refptr(new AnimationPlayer(id)); 20 return make_scoped_refptr(new AnimationPlayer(id));
21 } 21 }
22 22
23 AnimationPlayer::AnimationPlayer(int id) 23 AnimationPlayer::AnimationPlayer(int id)
24 : animation_host_(), 24 : animation_host_(),
25 animation_timeline_(), 25 animation_timeline_(),
26 element_animations_(), 26 element_animations_(),
27 animation_delegate_(), 27 animation_delegate_(),
28 id_(id), 28 id_(id),
29 element_id_(kInvalidElementId),
29 needs_push_properties_(false), 30 needs_push_properties_(false),
30 needs_to_start_animations_(false), 31 needs_to_start_animations_(false),
31 is_ticking_(false), 32 is_ticking_(false),
32 scroll_offset_animation_was_interrupted_(false) { 33 scroll_offset_animation_was_interrupted_(false) {
33 DCHECK(id_); 34 DCHECK(id_);
34 } 35 }
35 36
36 AnimationPlayer::~AnimationPlayer() { 37 AnimationPlayer::~AnimationPlayer() {
37 DCHECK(!animation_timeline_); 38 DCHECK(!animation_timeline_);
38 DCHECK(!element_animations_); 39 DCHECK(!element_animations_);
(...skipping 1166 matching lines...) Expand 10 before | Expand all | Expand 10 after
1205 if (current_impl) 1206 if (current_impl)
1206 animations_[i]->PushPropertiesTo(current_impl); 1207 animations_[i]->PushPropertiesTo(current_impl);
1207 } 1208 }
1208 1209
1209 animation_player_impl->scroll_offset_animation_was_interrupted_ = 1210 animation_player_impl->scroll_offset_animation_was_interrupted_ =
1210 scroll_offset_animation_was_interrupted_; 1211 scroll_offset_animation_was_interrupted_;
1211 scroll_offset_animation_was_interrupted_ = false; 1212 scroll_offset_animation_was_interrupted_ = false;
1212 } 1213 }
1213 1214
1214 } // namespace cc 1215 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698