diff options
author | chriszero <zerov83@gmail.com> | 2015-05-10 18:41:24 +0200 |
---|---|---|
committer | chriszero <zerov83@gmail.com> | 2015-05-10 18:41:24 +0200 |
commit | 80d1c613e8055567644abab38707378960b5d809 (patch) | |
tree | e66ff9ee64d91f6d6e6f0722dc86fc353ee63f28 | |
parent | 56c8a3fbaa9530c17d3a4bbb1852ef5e4b0f3f30 (diff) | |
download | vdr-plugin-plex-80d1c613e8055567644abab38707378960b5d809.tar.gz vdr-plugin-plex-80d1c613e8055567644abab38707378960b5d809.tar.bz2 |
New token: {ratingstring}
-rw-r--r-- | PVideo.cpp | 1 | ||||
-rw-r--r-- | templates/plug-plex-root.xml | 3 |
2 files changed, 3 insertions, 1 deletions
@@ -219,6 +219,7 @@ void Video::AddTokens(std::shared_ptr<skindesignerapi::cOsdElement> grid, bool c grid->AddStringToken("summary", m_sSummary); grid->AddStringToken("contentrating", m_sContentRating); grid->AddIntToken("rating", m_dRating*10); + grid->AddStringToken("ratingstring", Poco::format("%.1f", m_dRating)); grid->AddStringToken("studio", m_sStudio); grid->AddIntToken("viewCount", m_iViewCount); grid->AddIntToken("viewoffset", m_lViewoffset/1000/60); diff --git a/templates/plug-plex-root.xml b/templates/plug-plex-root.xml index be631f8..506449e 100644 --- a/templates/plug-plex-root.xml +++ b/templates/plug-plex-root.xml @@ -81,7 +81,8 @@ If the item is a video following tokens are avaliable The item is a video if one of the following tokens are set: {ismovie}, {isepisode} {contentrating} string, FSK, PEGI - {rating} int, starrating 0.0 - 10.0 multiplied by 10 -> 0 - 100, use sprintf and divide by 10 + {rating} int, starrating 0.0 - 10.0 multiplied by 10 -> 0 - 100 + {ratingstring} string, rating formated as double %.1f {viewoffset} int, minutes, last viewed position {duration} int, minutes, total duration {orginaltitle} original title |