Make static
This commit is contained in:
@@ -190,7 +190,7 @@ QString About::ContributorsHtml() const {
|
||||
|
||||
}
|
||||
|
||||
QString About::PersonToHtml(const Person &person) const {
|
||||
QString About::PersonToHtml(const Person &person) {
|
||||
|
||||
if (person.email.isNull())
|
||||
return person.name;
|
||||
|
||||
@@ -49,7 +49,7 @@ class About : public QDialog {
|
||||
|
||||
QString MainHtml() const;
|
||||
QString ContributorsHtml() const;
|
||||
QString PersonToHtml(const Person &person) const;
|
||||
static QString PersonToHtml(const Person &person) ;
|
||||
|
||||
private:
|
||||
Ui::About ui_;
|
||||
|
||||
@@ -379,7 +379,7 @@ bool EditTagDialog::SetLoading(const QString &message) {
|
||||
|
||||
}
|
||||
|
||||
QList<EditTagDialog::Data> EditTagDialog::LoadData(const SongList &songs) const {
|
||||
QList<EditTagDialog::Data> EditTagDialog::LoadData(const SongList &songs) {
|
||||
|
||||
QList<Data> ret;
|
||||
|
||||
@@ -410,11 +410,7 @@ void EditTagDialog::SetSongs(const SongList &s, const PlaylistItemList &items) {
|
||||
collection_songs_.clear();
|
||||
|
||||
// Reload tags in the background
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
QFuture<QList<Data>> future = QtConcurrent::run(&EditTagDialog::LoadData, this, s);
|
||||
#else
|
||||
QFuture<QList<Data>> future = QtConcurrent::run(this, &EditTagDialog::LoadData, s);
|
||||
#endif
|
||||
QFuture<QList<Data>> future = QtConcurrent::run(&EditTagDialog::LoadData, s);
|
||||
QFutureWatcher<QList<Data>> *watcher = new QFutureWatcher<QList<Data>>();
|
||||
QObject::connect(watcher, &QFutureWatcher<QList<Data>>::finished, this, &EditTagDialog::SetSongsFinished);
|
||||
watcher->setFuture(future);
|
||||
|
||||
@@ -160,7 +160,7 @@ class EditTagDialog : public QDialog {
|
||||
void UpdateSummaryTab(const Song &song, const UpdateCoverAction cover_action);
|
||||
void UpdateStatisticsTab(const Song &song);
|
||||
|
||||
QString GetArtSummary(const Song &song, const UpdateCoverAction cover_action);
|
||||
static QString GetArtSummary(const Song &song, const UpdateCoverAction cover_action);
|
||||
|
||||
void UpdateUI(const QModelIndexList &indexes);
|
||||
|
||||
@@ -168,7 +168,7 @@ class EditTagDialog : public QDialog {
|
||||
void SetSongListVisibility(bool visible);
|
||||
|
||||
// Called by QtConcurrentRun
|
||||
QList<Data> LoadData(const SongList &songs) const;
|
||||
static QList<Data> LoadData(const SongList &songs);
|
||||
void SaveData();
|
||||
|
||||
static void SetText(QLabel *label, const int value, const QString &suffix, const QString &def = QString());
|
||||
|
||||
@@ -228,7 +228,7 @@ void TrackSelectionDialog::AddDivider(const QString &text, QTreeWidget *parent)
|
||||
|
||||
}
|
||||
|
||||
void TrackSelectionDialog::AddSong(const Song &song, int result_index, QTreeWidget *parent) const {
|
||||
void TrackSelectionDialog::AddSong(const Song &song, int result_index, QTreeWidget *parent) {
|
||||
|
||||
QStringList values;
|
||||
values << ((song.track() > 0) ? QString::number(song.track()) : QString()) << ((song.year() > 0) ? QString::number(song.year()) : QString()) << song.title() << song.artist() << song.album();
|
||||
|
||||
@@ -80,7 +80,7 @@ class TrackSelectionDialog : public QDialog {
|
||||
};
|
||||
|
||||
void AddDivider(const QString &text, QTreeWidget *parent) const;
|
||||
void AddSong(const Song &song, int result_index, QTreeWidget *parent) const;
|
||||
static void AddSong(const Song &song, int result_index, QTreeWidget *parent) ;
|
||||
|
||||
void SetLoading(const QString &message);
|
||||
static void SaveData(const QList<Data> &data);
|
||||
|
||||
Reference in New Issue
Block a user