New context with albums and lyrics +++ much more
* Added new lyrics provider with lyrics from AudD and API Seeds * New improved context widget with albums and lyrics * Fixed playing and context widget getting stuck in play mode when there was an error * Changed icons for artists in collection, tidal and cover manager * Removed "search" icon from "Search automatically" checkbox (right click) that looked ugly * Removed some unused widgets from the src/widgets directory * Fixed initial size of window and side panel * Fixed saving window size correctly
This commit is contained in:
@@ -219,10 +219,6 @@ bool TidalSearch::FindCachedPixmap(const TidalSearch::Result &result, QPixmap *p
|
||||
return pixmap_cache_.find(result.pixmap_cache_key_, pixmap);
|
||||
}
|
||||
|
||||
void TidalSearch::LoadArtAsync(int id, const Result &result) {
|
||||
emit ArtLoaded(id, QImage());
|
||||
}
|
||||
|
||||
int TidalSearch::LoadArtAsync(const TidalSearch::Result &result) {
|
||||
|
||||
const int id = art_searches_next_id_++;
|
||||
@@ -246,6 +242,7 @@ void TidalSearch::AlbumArtLoaded(quint64 id, const QImage &image) {
|
||||
int orig_id = cover_loader_tasks_.take(id);
|
||||
|
||||
HandleLoadedArt(orig_id, image);
|
||||
|
||||
}
|
||||
|
||||
void TidalSearch::HandleLoadedArt(int id, const QImage &image) {
|
||||
|
||||
@@ -118,7 +118,6 @@ class TidalSearch : public QObject {
|
||||
void HandleLoadedArt(int id, const QImage &image);
|
||||
bool FindCachedPixmap(const TidalSearch::Result &result, QPixmap *pixmap) const;
|
||||
QString PixmapCacheKey(const TidalSearch::Result &result) const;
|
||||
void LoadArtAsync(int id, const Result &result);
|
||||
void MaybeSearchFinished(int id);
|
||||
void ShowConfig() {}
|
||||
static QImage ScaleAndPad(const QImage &image);
|
||||
|
||||
@@ -40,13 +40,16 @@ TidalSearchModel::TidalSearchModel(TidalSearch *engine, QObject *parent)
|
||||
engine_(engine),
|
||||
proxy_(nullptr),
|
||||
use_pretty_covers_(true),
|
||||
artist_icon_(IconLoader::Load("guitar")) {
|
||||
artist_icon_(IconLoader::Load("folder-sound")) {
|
||||
|
||||
group_by_[0] = CollectionModel::GroupBy_Artist;
|
||||
group_by_[1] = CollectionModel::GroupBy_Album;
|
||||
group_by_[2] = CollectionModel::GroupBy_None;
|
||||
|
||||
QIcon nocover = IconLoader::Load("cdcase");
|
||||
no_cover_icon_ = nocover.pixmap(nocover.availableSizes().last()).scaled(CollectionModel::kPrettyCoverSize, CollectionModel::kPrettyCoverSize, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
||||
|
||||
no_cover_icon_ = QPixmap(":/pictures/noalbumart.png").scaled(CollectionModel::kPrettyCoverSize, CollectionModel::kPrettyCoverSize, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
||||
//no_cover_icon_ = QPixmap(":/pictures/noalbumart.png").scaled(CollectionModel::kPrettyCoverSize, CollectionModel::kPrettyCoverSize, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
||||
album_icon_ = no_cover_icon_;
|
||||
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>437</width>
|
||||
<width>400</width>
|
||||
<height>633</height>
|
||||
</rect>
|
||||
</property>
|
||||
@@ -82,14 +82,14 @@
|
||||
<item>
|
||||
<widget class="QRadioButton" name="radiobutton_searchbyalbums">
|
||||
<property name="text">
|
||||
<string>albu&ms</string>
|
||||
<string>a&lbums</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QRadioButton" name="radiobutton_searchbysongs">
|
||||
<property name="text">
|
||||
<string>songs</string>
|
||||
<string>son&gs</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -186,7 +186,7 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>435</width>
|
||||
<width>398</width>
|
||||
<height>533</height>
|
||||
</rect>
|
||||
</property>
|
||||
@@ -195,7 +195,7 @@
|
||||
<rect>
|
||||
<x>9</x>
|
||||
<y>109</y>
|
||||
<width>420</width>
|
||||
<width>336</width>
|
||||
<height>100</height>
|
||||
</rect>
|
||||
</property>
|
||||
@@ -214,12 +214,6 @@
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_helptext">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>80</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enter search terms above to find music</string>
|
||||
</property>
|
||||
|
||||
@@ -741,7 +741,8 @@ Song *TidalService::ParseSong(TidalSearchContext *search_ctx, const int album_id
|
||||
//if (i > 1) song.set_compilation_detected(true);
|
||||
|
||||
cover = cover.replace("-", "/");
|
||||
QUrl cover_url (QString("%1/images/%2/750x750.jpg").arg(kResourcesUrl).arg(cover));
|
||||
//QUrl cover_url (QString("%1/images/%2/750x750.jpg").arg(kResourcesUrl).arg(cover));
|
||||
QUrl cover_url (QString("%1/images/%2/320x320.jpg").arg(kResourcesUrl).arg(cover));
|
||||
song.set_art_automatic(cover_url.toEncoded());
|
||||
|
||||
if (search_ctx->requests_song_.contains(id)) return search_ctx->requests_song_.value(id);
|
||||
|
||||
Reference in New Issue
Block a user