selected playlist now stored and displayed

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@6310 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
fhemrocks
2014-07-23 11:29:30 +00:00
parent 6c8733be4a
commit b03665e178

View File

@@ -332,6 +332,11 @@ sub SB_PLAYER_Define( $$ ) {
$hash->{READINGS}{favorites}{TIME} = $tn;
}
if( !defined( $hash->{READINGS}{playlists}{VAL} ) ) {
$hash->{READINGS}{playlists}{VAL} = "not";
$hash->{READINGS}{playlists}{TIME} = $tn;
}
# for the FHEM AV Development Guidelinses
# we use this to store the currently playing ID to later on return to
if( !defined( $hash->{READINGS}{currentMedia}{VAL} ) ) {
@@ -1240,6 +1245,7 @@ sub SB_PLAYER_Set( $@ ) {
Log3( $hash, 5, "SB_PLAYER_Set($name): playlists command = " .
$msg . " ........ with $arg[0]" );
IOWrite( $hash, $msg . "\n" );
readingsSingleUpdate( $hash, "playlists", "$arg[ 0 ]", 1 );
SB_PLAYER_GetStatus( $hash );
} else {