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

Unified Diff: cc/top_controls_manager.cc

Issue 12517003: cc: Chromify the Animation and LayerAnimationController classes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/timing_function_unittest.cc ('k') | cc/tree_synchronizer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/top_controls_manager.cc
diff --git a/cc/top_controls_manager.cc b/cc/top_controls_manager.cc
index 98fddb849d2f3d8dbde7bf9f14aa97751fe8b7aa..626afb539c35a5eb6020bd88d289df72f5b0f851 100644
--- a/cc/top_controls_manager.cc
+++ b/cc/top_controls_manager.cc
@@ -141,7 +141,7 @@ void TopControlsManager::Animate(base::TimeTicks monotonic_time) {
return;
double time = (monotonic_time - base::TimeTicks()).InMillisecondsF();
- float new_offset = top_controls_animation_->getValue(time);
+ float new_offset = top_controls_animation_->GetValue(time);
gfx::Vector2dF scroll_vector(0.f, -(new_offset - controls_top_offset_));
ScrollInternal(scroll_vector);
client_->setNeedsRedraw();
@@ -162,16 +162,16 @@ float TopControlsManager::RootScrollLayerTotalScrollY() {
}
void TopControlsManager::SetupAnimation(AnimationDirection direction) {
- top_controls_animation_ = KeyframedFloatAnimationCurve::create();
+ top_controls_animation_ = KeyframedFloatAnimationCurve::Create();
double start_time =
(base::TimeTicks::Now() - base::TimeTicks()).InMillisecondsF();
- top_controls_animation_->addKeyframe(
- FloatKeyframe::create(start_time, controls_top_offset_,
+ top_controls_animation_->AddKeyframe(
+ FloatKeyframe::Create(start_time, controls_top_offset_,
scoped_ptr<TimingFunction>()));
float max_ending_offset =
(direction == SHOWING_CONTROLS ? 1 : -1) * top_controls_height_;
- top_controls_animation_->addKeyframe(
- FloatKeyframe::create(start_time + kShowHideMaxDurationMs,
+ top_controls_animation_->AddKeyframe(
+ FloatKeyframe::Create(start_time + kShowHideMaxDurationMs,
controls_top_offset_ + max_ending_offset,
EaseTimingFunction::create()));
animation_direction_ = direction;
@@ -209,7 +209,7 @@ bool TopControlsManager::IsAnimationCompleteAtTime(base::TimeTicks time) {
return true;
double time_ms = (time - base::TimeTicks()).InMillisecondsF();
- float new_offset = top_controls_animation_->getValue(time_ms);
+ float new_offset = top_controls_animation_->GetValue(time_ms);
if ((animation_direction_ == SHOWING_CONTROLS && new_offset >= 0) ||
(animation_direction_ == HIDING_CONTROLS
« no previous file with comments | « cc/timing_function_unittest.cc ('k') | cc/tree_synchronizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698