[Android] Use view rcontext instead of application one

Geoffrey Métais git at videolan.org
Thu May 3 11:25:27 CEST 2018


vlc-android | branch: 3.0.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu May  3 11:06:07 2018 +0200| [6cf341d550c332bb2c3f04a2535e7208efdddc47] | committer: Geoffrey Métais

Use view rcontext instead of application one

> https://code.videolan.org/videolan/vlc-android/commit/6cf341d550c332bb2c3f04a2535e7208efdddc47
---

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

diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoListAdapter.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoListAdapter.java
index 2a00b19f2..43c7200a5 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoListAdapter.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoListAdapter.java
@@ -222,7 +222,7 @@ public class VideoListAdapter extends SortableAdapter<MediaWrapper, VideoListAda
         if (media.getType() == MediaWrapper.TYPE_GROUP) {
             MediaGroup mediaGroup = (MediaGroup) media;
             final int size = mediaGroup.size();
-            text = VLCApplication.getAppResources().getQuantityString(R.plurals.videos_quantity, size, size);
+            text = holder.itemView.getResources().getQuantityString(R.plurals.videos_quantity, size, size);
         } else {
             /* Time / Duration */
             if (media.getLength() > 0) {



More information about the Android mailing list