Use std::bind in QtConcurrent::run() to fix compile with Qt 6
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
#include "config.h"
|
||||
|
||||
#include <memory>
|
||||
#include <functional>
|
||||
#include <algorithm>
|
||||
|
||||
#include <QtGlobal>
|
||||
@@ -344,7 +345,7 @@ bool OrganiseDialog::SetUrls(const QList<QUrl> &urls) {
|
||||
|
||||
bool OrganiseDialog::SetFilenames(const QStringList &filenames) {
|
||||
|
||||
songs_future_ = QtConcurrent::run(this, &OrganiseDialog::LoadSongsBlocking, filenames);
|
||||
songs_future_ = QtConcurrent::run(std::bind(&OrganiseDialog::LoadSongsBlocking, this, filenames));
|
||||
NewClosure(songs_future_, [=]() { SetSongs(songs_future_.result()); });
|
||||
|
||||
SetLoadingSongs(true);
|
||||
|
||||
Reference in New Issue
Block a user