Avoid running into Qt assertion when destructing TagFieldEdit
This commit is contained in:
parent
488684a318
commit
1e45722ea1
|
@ -81,6 +81,14 @@ TagFieldEdit::TagFieldEdit(const QList<TagParser::Tag *> &tags, TagParser::Known
|
||||||
updateValue();
|
updateValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TagFieldEdit::~TagFieldEdit()
|
||||||
|
{
|
||||||
|
// delete those actions before entering base class destructors as we connect signal handlers when those actions are
|
||||||
|
// destructed and calling those handlers is gonna break otherwise
|
||||||
|
delete m_lockAction;
|
||||||
|
delete m_restoreAction;
|
||||||
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Assigns the specified \a tags and sets the specified \a fields using the given \a previousValueHandling.
|
* \brief Assigns the specified \a tags and sets the specified \a fields using the given \a previousValueHandling.
|
||||||
*
|
*
|
||||||
|
|
|
@ -39,6 +39,7 @@ class TagFieldEdit : public QWidget {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit TagFieldEdit(const QList<TagParser::Tag *> &tags, TagParser::KnownField field, QWidget *parent = nullptr);
|
explicit TagFieldEdit(const QList<TagParser::Tag *> &tags, TagParser::KnownField field, QWidget *parent = nullptr);
|
||||||
|
~TagFieldEdit() override;
|
||||||
|
|
||||||
const QList<TagParser::Tag *> &tags() const;
|
const QList<TagParser::Tag *> &tags() const;
|
||||||
TagParser::KnownField field() const;
|
TagParser::KnownField field() const;
|
||||||
|
|
Loading…
Reference in New Issue