mirror of
https://github.com/clementine-player/Clementine
synced 2024-12-17 12:02:48 +01:00
Oops, fix another crash in the smart playlist preview view when moodbars are displayed
This commit is contained in:
parent
836a2b0c89
commit
eeb617e892
@ -255,11 +255,12 @@ void MoodbarItemDelegate::ImageLoaded(const QUrl& url, QFutureWatcher<QImage>* w
|
||||
// Update all the indices with the new pixmap.
|
||||
foreach (const QPersistentModelIndex& index, data->indexes_) {
|
||||
if (index.isValid() && index.sibling(index.row(), Playlist::Column_Filename).data().toUrl() == url) {
|
||||
Q_ASSERT(index.model() == filter);
|
||||
QModelIndex source_index(filter->mapToSource(index));
|
||||
QModelIndex source_index = index;
|
||||
if (index.model() == filter) {
|
||||
source_index = filter->mapToSource(source_index);
|
||||
}
|
||||
|
||||
Q_ASSERT(source_index.model() == playlist);
|
||||
|
||||
playlist->MoodbarUpdated(source_index);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user