diff options
author | Adam Cohen <adamcohen@google.com> | 2015-07-30 13:03:56 -0700 |
---|---|---|
committer | Adam Cohen <adamcohen@google.com> | 2015-07-30 13:04:54 -0700 |
commit | 0ff535eabbdf27ec5a790adbc64f27f8c63e7399 (patch) | |
tree | 704320ff7501361ba4566b860896de11ff0c793e /src/com/android | |
parent | 249a510ab318db461ce1ac86baca01021fe41a2c (diff) | |
download | android_packages_apps_Trebuchet-0ff535eabbdf27ec5a790adbc64f27f8c63e7399.tar.gz android_packages_apps_Trebuchet-0ff535eabbdf27ec5a790adbc64f27f8c63e7399.tar.bz2 android_packages_apps_Trebuchet-0ff535eabbdf27ec5a790adbc64f27f8c63e7399.zip |
Remove references to FloatMath, deprecated in M
-> Allows us to build against M SDK
issue 22822360
Change-Id: I1178eb6bafc348699c5be8c29858eb3dff093e11
Diffstat (limited to 'src/com/android')
-rw-r--r-- | src/com/android/launcher3/LauncherScroller.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/com/android/launcher3/LauncherScroller.java b/src/com/android/launcher3/LauncherScroller.java index 3bd0a78c4..bbc7e4cab 100644 --- a/src/com/android/launcher3/LauncherScroller.java +++ b/src/com/android/launcher3/LauncherScroller.java @@ -20,7 +20,6 @@ import android.animation.TimeInterpolator; import android.content.Context; import android.hardware.SensorManager; import android.os.Build; -import android.util.FloatMath; import android.view.ViewConfiguration; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; @@ -409,7 +408,7 @@ public class LauncherScroller { float dx = (float) (mFinalX - mStartX); float dy = (float) (mFinalY - mStartY); - float hyp = FloatMath.sqrt(dx * dx + dy * dy); + float hyp = (float) Math.sqrt(dx * dx + dy * dy); float ndx = dx / hyp; float ndy = dy / hyp; @@ -426,7 +425,7 @@ public class LauncherScroller { mMode = FLING_MODE; mFinished = false; - float velocity = FloatMath.sqrt(velocityX * velocityX + velocityY * velocityY); + float velocity = (float) Math.sqrt(velocityX * velocityX + velocityY * velocityY); mVelocity = velocity; mDuration = getSplineFlingDuration(velocity); |