Items can be saved before starting the updater.

This commit is contained in:
2026-01-06 10:15:01 +01:00
parent 99ed398c2f
commit 8d4260b18d
2 changed files with 5 additions and 7 deletions

View File

@ -76,12 +76,10 @@ bool GenericCore::isApplicationUpdateAvailable() {
return true;
}
void GenericCore::triggerApplicationUpdate() {
// TODO include cleaness of undo stack
// if (!m_undoStack->isClean()) {
// saveItems();
// }
// QStringList args("update componentA componentB");
void GenericCore::triggerApplicationUpdate(const bool saveChanges) {
if (saveChanges && !m_modelUndoStack->isClean()) {
saveItems();
}
QStringList args("--start-updater");
QString toolFilePath = getMaintenanceToolFilePath();
QProcess::startDetached(toolFilePath, args);