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

Side by Side Diff: ui/gfx/animation/linear_animation.cc

Issue 1445003002: Use std::default_delete as the default deleter for scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Windows maybe Created 5 years, 1 month 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "ui/gfx/animation/linear_animation.h" 5 #include "ui/gfx/animation/linear_animation.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 #include <algorithm>
danakj 2015/11/17 19:09:27 +whitespace
dcheng 2015/11/17 20:21:03 Done.
8 9
9 #include "ui/gfx/animation/animation_container.h" 10 #include "ui/gfx/animation/animation_container.h"
10 #include "ui/gfx/animation/animation_delegate.h" 11 #include "ui/gfx/animation/animation_delegate.h"
11 12
12 using base::Time; 13 using base::Time;
13 using base::TimeDelta; 14 using base::TimeDelta;
14 15
15 namespace gfx { 16 namespace gfx {
16 17
17 static TimeDelta CalculateInterval(int frame_rate) { 18 static TimeDelta CalculateInterval(int frame_rate) {
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 // Set state_ to ensure we send ended to delegate and not canceled. 100 // Set state_ to ensure we send ended to delegate and not canceled.
100 state_ = 1; 101 state_ = 1;
101 AnimateToState(1.0); 102 AnimateToState(1.0);
102 } 103 }
103 104
104 bool LinearAnimation::ShouldSendCanceledFromStop() { 105 bool LinearAnimation::ShouldSendCanceledFromStop() {
105 return state_ != 1; 106 return state_ != 1;
106 } 107 }
107 108
108 } // namespace gfx 109 } // namespace gfx
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698