diff --git a/plugin/src/Caelestia/Models/filesystemmodel.cpp b/plugin/src/Caelestia/Models/filesystemmodel.cpp index eb30fa8b..b7889f0a 100644 --- a/plugin/src/Caelestia/Models/filesystemmodel.cpp +++ b/plugin/src/Caelestia/Models/filesystemmodel.cpp @@ -393,7 +393,7 @@ void FileSystemModel::applyChanges(const QSet& removedPaths, const QSet beginRemoveRows(QModelIndex(), end, start); for (int i = start; i >= end; --i) { emit removed(m_entries[i]->path()); - delete m_entries.takeAt(i); + m_entries.takeAt(i)->deleteLater(); } endRemoveRows(); @@ -405,7 +405,7 @@ void FileSystemModel::applyChanges(const QSet& removedPaths, const QSet beginRemoveRows(QModelIndex(), end, start); for (int i = start; i >= end; --i) { emit removed(m_entries[i]->path()); - delete m_entries.takeAt(i); + m_entries.takeAt(i)->deleteLater(); } endRemoveRows(); } diff --git a/plugin/src/Caelestia/appdb.cpp b/plugin/src/Caelestia/appdb.cpp index 71f71306..f55b4dbc 100644 --- a/plugin/src/Caelestia/appdb.cpp +++ b/plugin/src/Caelestia/appdb.cpp @@ -195,7 +195,7 @@ void AppDb::updateApps() { for (auto id : m_apps.keys()) { if (!newIds.contains(id)) { dirty = true; - delete m_apps.take(id); + m_apps.take(id)->deleteLater(); } }