[Android] Remove dead code

Geoffrey Métais git at videolan.org
Thu Jan 24 10:26:49 CET 2019


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Jan 24 09:35:50 2019 +0100| [56f761cbe6c596a7646deac3afdc857fa6621644] | committer: Geoffrey Métais

Remove dead code

> https://code.videolan.org/videolan/vlc-android/commit/56f761cbe6c596a7646deac3afdc857fa6621644
---

 .../src/org/videolan/vlc/gui/helpers/BitmapUtil.java      | 15 ---------------
 1 file changed, 15 deletions(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/helpers/BitmapUtil.java b/vlc-android/src/org/videolan/vlc/gui/helpers/BitmapUtil.java
index 951c54ccd..2690930ff 100644
--- a/vlc-android/src/org/videolan/vlc/gui/helpers/BitmapUtil.java
+++ b/vlc-android/src/org/videolan/vlc/gui/helpers/BitmapUtil.java
@@ -70,21 +70,6 @@ public class BitmapUtil {
                 (width - (2 * left)), (height - (2 * top)));
     }
 
-    public static Bitmap scaleDownBitmap(Context context, Bitmap bitmap, int width) {
-        /*
-         * This method can lead to OutOfMemoryError!
-         * If the source size is more than twice the target size use
-         * the optimized version available in AudioUtil::readCoverBitmap
-         */
-        if (bitmap != null) {
-            final float densityMultiplier = context.getResources().getDisplayMetrics().density;
-            int w = (int) (width * densityMultiplier);
-            int h = (int) (w * bitmap.getHeight() / ((double) bitmap.getWidth()));
-            bitmap = Bitmap.createScaledBitmap(bitmap, w, h, true);
-        }
-        return bitmap;
-    }
-
     public static Bitmap getPictureFromCache(MediaWrapper media) {
         // mPicture is not null only if passed through
         // the ctor which is deprecated by now.



More information about the Android mailing list