EditTagDialog: Initialize cover_menu_

This commit is contained in:
Jonas Kvinge 2024-06-12 18:12:08 +02:00
parent 57fb52e8f0
commit 241a6c5818
2 changed files with 3 additions and 5 deletions

View File

@ -116,6 +116,7 @@ EditTagDialog::EditTagDialog(Application *app, QWidget *parent)
results_dialog_(new TrackSelectionDialog(this)),
#endif
lyrics_fetcher_(new LyricsFetcher(app->lyrics_providers(), this)),
cover_menu_(new QMenu(this)),
image_no_cover_thumbnail_(ImageUtils::GenerateNoCoverImage(QSize(128, 128), devicePixelRatioF())),
loading_(false),
ignore_edits_(false),
@ -205,9 +206,6 @@ EditTagDialog::EditTagDialog(Application *app, QWidget *parent)
#endif
QObject::connect(ui_->fetch_lyrics, &QPushButton::clicked, this, &EditTagDialog::FetchLyrics);
// Set up the album cover menu
cover_menu_ = new QMenu(this);
QList<QAction*> actions = album_cover_choice_controller_->GetAllActions();
QObject::connect(album_cover_choice_controller_, &AlbumCoverChoiceController::Error, this, &EditTagDialog::Error);

View File

@ -185,6 +185,8 @@ class EditTagDialog : public QDialog {
#endif
LyricsFetcher *lyrics_fetcher_;
QMenu *cover_menu_;
const QImage image_no_cover_thumbnail_;
bool loading_;
@ -199,8 +201,6 @@ class EditTagDialog : public QDialog {
quint64 tags_cover_art_id_;
bool cover_art_is_set_;
QMenu *cover_menu_;
QPushButton *previous_button_;
QPushButton *next_button_;