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

Side by Side Diff: app/animation.cc

Issue 5588004: [gtk] Add fade-commit to instant suggestion for predictive instant. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review comments Created 10 years 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | app/multi_animation.h » ('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 (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "app/animation.h" 5 #include "app/animation.h"
6 6
7 #include "app/animation_container.h" 7 #include "app/animation_container.h"
8 #include "app/animation_delegate.h" 8 #include "app/animation_delegate.h"
9 #include "app/tween.h" 9 #include "app/tween.h"
10 #include "gfx/rect.h" 10 #include "gfx/rect.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 delegate_->AnimationEnded(this); 58 delegate_->AnimationEnded(this);
59 } 59 }
60 } 60 }
61 61
62 double Animation::CurrentValueBetween(double start, double target) const { 62 double Animation::CurrentValueBetween(double start, double target) const {
63 return Tween::ValueBetween(GetCurrentValue(), start, target); 63 return Tween::ValueBetween(GetCurrentValue(), start, target);
64 } 64 }
65 65
66 int Animation::CurrentValueBetween(int start, int target) const { 66 int Animation::CurrentValueBetween(int start, int target) const {
67 return Tween::ValueBetween(GetCurrentValue(), start, target); 67 return Tween::ValueBetween(GetCurrentValue(), start, target);
68
69 } 68 }
70 69
71 gfx::Rect Animation::CurrentValueBetween(const gfx::Rect& start_bounds, 70 gfx::Rect Animation::CurrentValueBetween(const gfx::Rect& start_bounds,
72 const gfx::Rect& target_bounds) const { 71 const gfx::Rect& target_bounds) const {
73 return Tween::ValueBetween(GetCurrentValue(), start_bounds, target_bounds); 72 return Tween::ValueBetween(GetCurrentValue(), start_bounds, target_bounds);
74 } 73 }
75 74
76 void Animation::SetContainer(AnimationContainer* container) { 75 void Animation::SetContainer(AnimationContainer* container) {
77 if (container == container_.get()) 76 if (container == container_.get())
78 return; 77 return;
(...skipping 25 matching lines...) Expand all
104 } 103 }
105 } 104 }
106 return !::GetSystemMetrics(SM_REMOTESESSION); 105 return !::GetSystemMetrics(SM_REMOTESESSION);
107 #endif 106 #endif
108 return true; 107 return true;
109 } 108 }
110 109
111 void Animation::SetStartTime(base::TimeTicks start_time) { 110 void Animation::SetStartTime(base::TimeTicks start_time) {
112 start_time_ = start_time; 111 start_time_ = start_time;
113 } 112 }
OLDNEW
« no previous file with comments | « no previous file | app/multi_animation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698