2023-02-10, 02:26
I've made a script to set a song's user-rating to a value that is predefined in skin settings. This acts as a sort of threshold for a Like/Unlike binary rating system that can be overlayed on top of the normal /10 ratings without removing existing user ratings. So if the threshold is set to 8, the script will set a song's user-rating to 8 when it is executed. And a widget will also use this threshold value as a filter, in effect working as a Liked songs smart playlist.
This all works fine, and I 'unlike' a song by running the script to set the user rating to 0, effectively removing it altogether.
I wanted to incorporate the scripit into my player controls to give the option to 'like' the currently playing song, or 'unlike' the song if it is already liked.
Here I run into problems because the infolabel MusicPlayer.UserRating appears not to update dynamically during song playback. So you have to stop and start or go next and then previous before it will show the value that it was set to via the script. @DaveBlake do you know if this is expected behaviour?
This all works fine, and I 'unlike' a song by running the script to set the user rating to 0, effectively removing it altogether.
I wanted to incorporate the scripit into my player controls to give the option to 'like' the currently playing song, or 'unlike' the song if it is already liked.
Here I run into problems because the infolabel MusicPlayer.UserRating appears not to update dynamically during song playback. So you have to stop and start or go next and then previous before it will show the value that it was set to via the script. @DaveBlake do you know if this is expected behaviour?