Use this and watcher instead of =
This commit is contained in:
parent
88874f0dcd
commit
57a5eabd8f
|
@ -397,7 +397,7 @@ bool OrganizeDialog::SetFilenames(const QStringList &filenames) {
|
||||||
#endif
|
#endif
|
||||||
QFutureWatcher<SongList> *watcher = new QFutureWatcher<SongList>();
|
QFutureWatcher<SongList> *watcher = new QFutureWatcher<SongList>();
|
||||||
watcher->setFuture(songs_future_);
|
watcher->setFuture(songs_future_);
|
||||||
QObject::connect(watcher, &QFutureWatcher<SongList>::finished, this, [=]() {
|
QObject::connect(watcher, &QFutureWatcher<SongList>::finished, this, [this, watcher]() {
|
||||||
SetSongs(watcher->result());
|
SetSongs(watcher->result());
|
||||||
watcher->deleteLater();
|
watcher->deleteLater();
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue