Fix compile with optional components disabled
This commit is contained in:
@@ -213,9 +213,10 @@ void FileView::UndoCommand::undo() {
|
||||
|
||||
}
|
||||
|
||||
#ifdef HAVE_GSTREAMER
|
||||
void FileView::Delete(const QStringList &filenames) {
|
||||
|
||||
#ifdef HAVE_GSTREAMER
|
||||
|
||||
if (filenames.isEmpty())
|
||||
return;
|
||||
|
||||
@@ -228,19 +229,28 @@ void FileView::Delete(const QStringList &filenames) {
|
||||
connect(delete_files, SIGNAL(Finished(SongList)), SLOT(DeleteFinished(SongList)));
|
||||
delete_files->Start(filenames);
|
||||
|
||||
#else
|
||||
Q_UNUSED(filenames)
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
void FileView::DeleteFinished(const SongList &songs_with_errors) {
|
||||
|
||||
#ifdef HAVE_GSTREAMER
|
||||
|
||||
if (songs_with_errors.isEmpty()) return;
|
||||
|
||||
OrganiseErrorDialog *dialog = new OrganiseErrorDialog(this);
|
||||
dialog->Show(OrganiseErrorDialog::Type_Delete, songs_with_errors);
|
||||
// It deletes itself when the user closes it
|
||||
|
||||
}
|
||||
#else
|
||||
Q_UNUSED(songs_with_errors)
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
void FileView::showEvent(QShowEvent *e) {
|
||||
|
||||
QWidget::showEvent(e);
|
||||
|
||||
Reference in New Issue
Block a user