From afd99a0c6ccf59fbb4d01d947f8945834222ede4 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Sun, 31 May 2015 00:38:14 -0700 Subject: [PATCH] Media Player and cast improvements --- homeassistant/components/frontend/version.py | 2 +- .../frontend/www_static/frontend.html | 21 +++++++++++-------- .../cards/state-card-media_player.html | 17 ++++++++------- .../more-infos/more-info-media_player.html | 6 +++--- .../components/media_player/__init__.py | 5 +++++ homeassistant/components/media_player/cast.py | 18 +++++++++++++++- requirements.txt | 2 +- 7 files changed, 49 insertions(+), 22 deletions(-) diff --git a/homeassistant/components/frontend/version.py b/homeassistant/components/frontend/version.py index 93571ba7d39..b69400142e0 100644 --- a/homeassistant/components/frontend/version.py +++ b/homeassistant/components/frontend/version.py @@ -1,2 +1,2 @@ """ DO NOT MODIFY. Auto-generated by build_frontend script """ -VERSION = "d9e860658bd8d9767b748b1b193776e6" +VERSION = "6fb0e76d325bb7472fa25355e60539cd" diff --git a/homeassistant/components/frontend/www_static/frontend.html b/homeassistant/components/frontend/www_static/frontend.html index d18421cfc90..1a23b706988 100644 --- a/homeassistant/components/frontend/www_static/frontend.html +++ b/homeassistant/components/frontend/www_static/frontend.html @@ -22208,13 +22208,8 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
- - +
[[computePrimaryText(stateObj)]]
+
[[computeSecondaryText(stateObj)]]
@@ -22230,6 +22225,14 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN type: Object, }, }, + + computePrimaryText: function(stateObj) { + return stateObj.attributes.media_title || stateObj.stateDisplay; + }, + + computeSecondaryText: function(stateObj) { + return stateObj.attributes.media_title ? stateObj.stateDisplay : ''; + }, }); })(); @@ -25726,9 +25729,9 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN