1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-16 19:31:02 +01:00

Connect signal to signal

This commit is contained in:
Krzysztof Sobiecki 2014-11-05 17:35:14 +01:00
parent 5045f9b870
commit 978a91442c
4 changed files with 4 additions and 9 deletions

View File

@ -192,7 +192,7 @@ void Organise::ProcessSomeFiles() {
} }
else { else {
if(job.mark_as_listened_) { if(job.mark_as_listened_) {
emit FileCopied_(job.metadata_.id()); emit FileCopied(job.metadata_.id());
} }
} }

View File

@ -54,7 +54,7 @@ class Organise : public QObject {
signals: signals:
void Finished(const QStringList& files_with_errors); void Finished(const QStringList& files_with_errors);
void FileCopied_(int database_id); void FileCopied(int database_id);
protected: protected:
void timerEvent(QTimerEvent* e); void timerEvent(QTimerEvent* e);

View File

@ -353,17 +353,13 @@ void OrganiseDialog::accept() {
new_songs_info_, ui_->eject_after->isChecked()); new_songs_info_, ui_->eject_after->isChecked());
connect(organise, SIGNAL(Finished(QStringList)), connect(organise, SIGNAL(Finished(QStringList)),
SLOT(OrganiseFinished(QStringList))); SLOT(OrganiseFinished(QStringList)));
connect(organise, SIGNAL(FileCopied_(int)), connect(organise, SIGNAL(FileCopied(int)),
this, SLOT(FileCopied_(int))); this, SIGNAL(FileCopied(int)));
organise->Start(); organise->Start();
QDialog::accept(); QDialog::accept();
} }
void OrganiseDialog::FileCopied_(int database_id) {
emit FileCopied(database_id);
}
void OrganiseDialog::OrganiseFinished(const QStringList& files_with_errors) { void OrganiseDialog::OrganiseFinished(const QStringList& files_with_errors) {
if (files_with_errors.isEmpty()) return; if (files_with_errors.isEmpty()) return;

View File

@ -65,7 +65,6 @@ class OrganiseDialog : public QDialog {
public slots: public slots:
void accept(); void accept();
void FileCopied_(int);
protected: protected:
void showEvent(QShowEvent*); void showEvent(QShowEvent*);