[Android] AudioPlaylistView: do the computation in float

Jean-Baptiste Kempf git at videolan.org
Fri Jul 18 21:32:13 CEST 2014


vlc-ports/android | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Jul 18 21:31:34 2014 +0200| [1820f9d9a1f86c651f4d9f677efbdfc1e0139e4f] | committer: Jean-Baptiste Kempf

AudioPlaylistView: do the computation in float

> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=1820f9d9a1f86c651f4d9f677efbdfc1e0139e4f
---

 vlc-android/src/org/videolan/vlc/gui/audio/AudioPlaylistView.java |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlaylistView.java b/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlaylistView.java
index 16bb591..8ef552e 100644
--- a/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlaylistView.java
+++ b/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlaylistView.java
@@ -134,7 +134,7 @@ public class AudioPlaylistView extends ListView {
         if (mIsDragging) {
             canvas.save();
             // Position the drag shadow.
-            float posY = mTouchY - mDragShadow.getMeasuredHeight() / 2;
+            float posY = mTouchY - (float)mDragShadow.getMeasuredHeight() / 2;
             canvas.translate(0, posY);
             mDragShadow.draw(canvas);
             canvas.restore();



More information about the Android mailing list