]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/settings/servicemodel.cpp
Merge branch 'release/21.12'
[dolphin.git] / src / settings / servicemodel.cpp
index 81810b0a03ffe83c58b7422fba2d8b47a116577b..9bfe1dad3e433c8269c0b768004191156d85bec0 100644 (file)
@@ -65,7 +65,7 @@ bool ServiceModel::setData(const QModelIndex& index, const QVariant& value, int
         return false;
     }
 
-    emit dataChanged(index, index);
+    Q_EMIT dataChanged(index, index);
     return true;
 }
 
@@ -92,3 +92,10 @@ int ServiceModel::rowCount(const QModelIndex& parent) const
     return m_items.count();
 }
 
+void ServiceModel::clear()
+{
+    beginRemoveRows(QModelIndex(), 0, m_items.count());
+    m_items.clear();
+    endRemoveRows();
+}
+