[Android] Show 'nowplaying' as title when available
Geoffrey Métais
git at videolan.org
Tue Jan 26 14:35:55 CET 2016
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Tue Jan 26 14:34:57 2016 +0100| [ac996a6636a71dfee9613287b8bce1fc02bbebf0] | committer: Geoffrey Métais
Show 'nowplaying' as title when available
> https://code.videolan.org/videolan/vlc-android/commit/ac996a6636a71dfee9613287b8bce1fc02bbebf0
---
vlc-android/src/org/videolan/vlc/PlaybackService.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/PlaybackService.java b/vlc-android/src/org/videolan/vlc/PlaybackService.java
index 50179d1..3381893 100644
--- a/vlc-android/src/org/videolan/vlc/PlaybackService.java
+++ b/vlc-android/src/org/videolan/vlc/PlaybackService.java
@@ -1429,8 +1429,8 @@ public class PlaybackService extends Service implements IVLCVout.Callback {
public String getArtist() {
if (hasCurrentMedia()) {
final MediaWrapper media = getCurrentMedia();
- return media.isArtistUnknown() && media.getNowPlaying() != null ?
- media.getNowPlaying()
+ return media.getNowPlaying() != null ?
+ media.getTitle()
: MediaUtils.getMediaArtist(PlaybackService.this, media);
} else
return null;
@@ -1455,7 +1455,7 @@ public class PlaybackService extends Service implements IVLCVout.Callback {
@MainThread
public String getTitle() {
if (hasCurrentMedia())
- return getCurrentMedia().getTitle();
+ return getCurrentMedia().getNowPlaying() != null ? getCurrentMedia().getNowPlaying() : getCurrentMedia().getTitle();
else
return null;
}
More information about the Android
mailing list