aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2015-10-07 17:00:01 -0700
committerScott Jackson <daneren2005@gmail.com>2015-10-07 17:00:01 -0700
commit5d400cd4b2b698e1477b813d5dc70e29f3799d2f (patch)
tree52069c54160ea946acb6fc08017522ea4b07feab /app
parente8f5ba112767fee1d8f0a6e2a72d475373e72c7e (diff)
downloaddsub-5d400cd4b2b698e1477b813d5dc70e29f3799d2f.tar.gz
dsub-5d400cd4b2b698e1477b813d5dc70e29f3799d2f.tar.bz2
dsub-5d400cd4b2b698e1477b813d5dc70e29f3799d2f.zip
Don't send cover art to Chromecast Audio
Diffstat (limited to 'app')
-rw-r--r--app/src/main/java/github/daneren2005/dsub/service/ChromeCastController.java24
1 files changed, 13 insertions, 11 deletions
diff --git a/app/src/main/java/github/daneren2005/dsub/service/ChromeCastController.java b/app/src/main/java/github/daneren2005/dsub/service/ChromeCastController.java
index 77b0395b..2f6ecd90 100644
--- a/app/src/main/java/github/daneren2005/dsub/service/ChromeCastController.java
+++ b/app/src/main/java/github/daneren2005/dsub/service/ChromeCastController.java
@@ -319,20 +319,22 @@ public class ChromeCastController extends RemoteController {
meta.putString(MediaMetadata.KEY_ALBUM_ARTIST, song.getArtist());
meta.putString(MediaMetadata.KEY_ALBUM_TITLE, song.getAlbum());
- if (proxy == null || proxy instanceof WebProxy) {
- String coverArt = musicService.getCoverArtUrl(downloadService, song);
+ if(castDevice.hasCapability(CastDevice.CAPABILITY_VIDEO_OUT)) {
+ if (proxy == null || proxy instanceof WebProxy) {
+ String coverArt = musicService.getCoverArtUrl(downloadService, song);
- // If proxy is going, it is a web proxy
- if (proxy != null) {
- coverArt = proxy.getPublicAddress(coverArt);
- }
+ // If proxy is going, it is a web proxy
+ if (proxy != null) {
+ coverArt = proxy.getPublicAddress(coverArt);
+ }
- meta.addImage(new WebImage(Uri.parse(coverArt)));
- } else {
- File coverArtFile = FileUtil.getAlbumArtFile(downloadService, song);
- if (coverArtFile != null && coverArtFile.exists()) {
- String coverArt = proxy.getPublicAddress(coverArtFile.getPath());
meta.addImage(new WebImage(Uri.parse(coverArt)));
+ } else {
+ File coverArtFile = FileUtil.getAlbumArtFile(downloadService, song);
+ if (coverArtFile != null && coverArtFile.exists()) {
+ String coverArt = proxy.getPublicAddress(coverArtFile.getPath());
+ meta.addImage(new WebImage(Uri.parse(coverArt)));
+ }
}
}
}