diff options
author | Scott Jackson <daneren2005@gmail.com> | 2013-02-04 19:27:58 -0800 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2013-02-04 19:27:58 -0800 |
commit | ec16db138219bc8d5cb56ebc4ba8361d85eeb392 (patch) | |
tree | ef14f6eea4cc66416b458405c39834b5e80dba34 | |
parent | 703e6987a90fb20854b3b50240f5002823efee9d (diff) | |
download | dsub-ec16db138219bc8d5cb56ebc4ba8361d85eeb392.tar.gz dsub-ec16db138219bc8d5cb56ebc4ba8361d85eeb392.tar.bz2 dsub-ec16db138219bc8d5cb56ebc4ba8361d85eeb392.zip |
Add track # to song details
-rw-r--r-- | subsonic-android/src/github/daneren2005/dsub/activity/SubsonicTabActivity.java | 3 | ||||
-rw-r--r-- | subsonic-android/src/github/daneren2005/dsub/service/OfflineMusicService.java | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/activity/SubsonicTabActivity.java b/subsonic-android/src/github/daneren2005/dsub/activity/SubsonicTabActivity.java index d2c61b59..398b0e65 100644 --- a/subsonic-android/src/github/daneren2005/dsub/activity/SubsonicTabActivity.java +++ b/subsonic-android/src/github/daneren2005/dsub/activity/SubsonicTabActivity.java @@ -508,6 +508,9 @@ public class SubsonicTabActivity extends SherlockActivity { if(!song.isVideo()) {
msg += "Artist: " + song.getArtist() + "\nAlbum: " + song.getAlbum();
}
+ if(song.getTrack() != null && song.getTrack() != 0) {
+ msg += "\nTrack: " + song.getTrack();
+ }
if(song.getGenre() != null && !"".equals(song.getGenre())) {
msg += "\nGenre: " + song.getGenre();
}
diff --git a/subsonic-android/src/github/daneren2005/dsub/service/OfflineMusicService.java b/subsonic-android/src/github/daneren2005/dsub/service/OfflineMusicService.java index 1ac8e9cc..89492687 100644 --- a/subsonic-android/src/github/daneren2005/dsub/service/OfflineMusicService.java +++ b/subsonic-android/src/github/daneren2005/dsub/service/OfflineMusicService.java @@ -167,6 +167,7 @@ public class OfflineMusicService extends RESTMusicService { Log.i(TAG, "Device doesn't properly support MediaMetadataRetreiver"); } + entry.setTrack(Integer.parseInt(name.substring(0, name.indexOf('-')))); title = title.substring(title.indexOf('-') + 1); } |