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

Unified Diff: remoting/client/ui/fling_animation.cc

Issue 2882653004: [CRD iOS] Injecting scroll events w/ fling animation (Closed)
Patch Set: Rebase 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/client/ui/direct_input_strategy.cc ('k') | remoting/client/ui/gesture_interpreter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/ui/fling_animation.cc
diff --git a/remoting/client/ui/fling_animation.cc b/remoting/client/ui/fling_animation.cc
index 8b8e6691ce43d827b6fba9e6fe210cbfacaad4e3..e51300633c8b93e640a59a897f6278813c0f16e0 100644
--- a/remoting/client/ui/fling_animation.cc
+++ b/remoting/client/ui/fling_animation.cc
@@ -26,6 +26,10 @@ bool FlingAnimation::IsAnimationInProgress() const {
}
void FlingAnimation::Tick() {
+ if (!IsAnimationInProgress()) {
+ return;
+ }
+
float dx, dy;
bool in_progress = fling_tracker_.TrackMovement(
clock_->NowTicks() - fling_start_time_, &dx, &dy);
« no previous file with comments | « remoting/client/ui/direct_input_strategy.cc ('k') | remoting/client/ui/gesture_interpreter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698