mirror of https://github.com/KDE/kasts.git
Call destructors for authors and entries
This commit is contained in:
parent
b76d1d81d1
commit
70393521f3
|
@ -28,6 +28,11 @@ EntriesModel::EntriesModel(Feed *feed)
|
|||
});
|
||||
}
|
||||
|
||||
EntriesModel::~EntriesModel()
|
||||
{
|
||||
qDeleteAll(m_entries);
|
||||
}
|
||||
|
||||
QVariant EntriesModel::data(const QModelIndex &index, int role) const
|
||||
{
|
||||
if (role != 0)
|
||||
|
|
|
@ -22,6 +22,7 @@ class EntriesModel : public QAbstractListModel
|
|||
|
||||
public:
|
||||
explicit EntriesModel(Feed *feed);
|
||||
~EntriesModel() override;
|
||||
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
|
||||
QHash<int, QByteArray> roleNames() const override;
|
||||
int rowCount(const QModelIndex &parent) const override;
|
||||
|
|
|
@ -45,6 +45,7 @@ Entry::Entry(Feed *feed, int index)
|
|||
|
||||
Entry::~Entry()
|
||||
{
|
||||
qDeleteAll(m_authors);
|
||||
}
|
||||
|
||||
QString Entry::id() const
|
||||
|
|
Loading…
Reference in New Issue