dd0e665...
by
Marinus Schraal <email address hidden>
grltrackerwrapper: Improve artist query
The artist query was only taking into account the artist tag. The
album-artist tag however is preferrable if available.
Use the album-artist tag if available and use the artist tag as fallback
for artist retrieval.
Closes #331
0ba494b...
by
Marinus Schraal <email address hidden>
grltrackerwrapper: Batch listmodel updates
Grilo provides Music query results one at a time, this results in a lot
of signal traffic adding songs, albums and artists to the different
listmodels.
This patch adds batch update functionality to the initial fill queries,
reducing the amount of signals and improve loading times.
1dce8f8...
by
Marinus Schraal <email address hidden>
songliststore: Fix incorrect liststore addition
Adding more than one item at a time resulted in the same item being
added multiple times. This was not noticed because all the additions
were single adds at a time. With batch additions however this becomes an
obvious bug.
Correct adding multiple items at a time to SongListStore.
This is a follow up and fix of commit
a65f4439e007a9e0202565afb13ce7ae3447f495.
The MPRIS tracklist (and some other properties) need to be updated in
two cases:
- the current song changes
- the player playlist changes (some songs are added or removed)
Commit a65f4439e007a9e0202565afb13ce7ae3447f495 added the possibility
to handle the latter case.
However, when a new player playlist is loaded (the user clicks on an
other album or artist for example), the player playlist is completely
refreshed. In that corner case, the MPRIS tracklist cannot be updated
because the player position has not been updated yet. The MPRIS
tracklist (and the other properties) will be correctly updated once a
new song is playing (by the _on_current_song_changed method).
mpris: Listen to the player model changes once a song is playing
If the "items-changed" signal from the player model is connected
before the model is populated, the MPRIS tracklist will be populated
with a list of empty track the first time it is filled. Indeed, the
current song property from the player has not been set yet.
Fix the issue by connecting this signal once the first song starts
playing.