Try to detect DLNA streams (e.g. when using upmpdcli), and show as regular albums in grouped view.
This commit is contained in:
committed by
Craig Drummond
parent
9d21ec6761
commit
f190ec8eb4
@@ -1,6 +1,8 @@
|
||||
2.1.0
|
||||
-----
|
||||
1. Re-add all album sorts from Cantata 1.x
|
||||
2. Try to detect DLNA streams (e.g. when using upmpdcli), and show as regular
|
||||
albums in grouped view.
|
||||
|
||||
2.0.0
|
||||
-----
|
||||
|
||||
@@ -197,7 +197,8 @@ struct Song
|
||||
static QString capitalize(const QString &s);
|
||||
bool capitalise();
|
||||
bool isStream() const { return Stream==type || CantataStream==type; }
|
||||
bool isStandardStream() const { return Stream==type; }
|
||||
bool isStandardStream() const { return Stream==type && !isDlnaStream(); }
|
||||
bool isDlnaStream() const { return Stream==type && !albumArtist().isEmpty() && !album.isEmpty() && track>0; }
|
||||
bool isNonMPD() const { return isStream() || OnlineSvrTrack==type || Cdda==type || (!file.isEmpty() && file.startsWith(Utils::constDirSep)); }
|
||||
bool isCantataStream() const { return CantataStream==type; }
|
||||
bool isCdda() const { return Cdda==type; }
|
||||
|
||||
@@ -317,7 +317,7 @@ void NowPlayingWidget::update(const Song &song)
|
||||
if (song.isEmpty()) {
|
||||
track->setText(" ");
|
||||
artist->setText(" ");
|
||||
} else if (song.isStream() && !song.isCantataStream() && !song.isCdda()) {
|
||||
} else if (song.isStream() && !song.isCantataStream() && !song.isCdda() && !song.isDlnaStream()) {
|
||||
track->setText(name.isEmpty() ? Song::unknown() : name);
|
||||
if (song.artist.isEmpty() && song.title.isEmpty() && !name.isEmpty()) {
|
||||
artist->setText(i18n("(Stream)"));
|
||||
|
||||
Reference in New Issue
Block a user