From 8c4bd2bb5286bbafbba1c5c45ae0b625257d5f88 Mon Sep 17 00:00:00 2001 From: Kevin Ottens Date: Tue, 15 Dec 2020 09:50:26 +0100 Subject: [PATCH] Ensure a sync happens after a conflict resolution You'd expect that after a conflict resolution the file watcher would pick up the change and trigger a sync. For some reason it doesn't seem to happen on at least some Ubuntu systems. In such cases the user would then still have a stale conflict entry in the activity list and wouldn't be able to do anything with it. Signed-off-by: Kevin Ottens --- src/gui/socketapi.cpp | 4 +++- src/gui/tray/ActivityListModel.cpp | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/gui/socketapi.cpp b/src/gui/socketapi.cpp index 8aafd0395..67d815788 100644 --- a/src/gui/socketapi.cpp +++ b/src/gui/socketapi.cpp @@ -711,7 +711,9 @@ void SocketApi::command_RESOLVE_CONFLICT(const QString &localFile, SocketListene dialog.setBaseFilename(baseName); dialog.setLocalVersionFilename(conflictedPath); dialog.setRemoteVersionFilename(basePath); - dialog.exec(); + if (dialog.exec() == ConflictDialog::Accepted) { + fileData.folder->scheduleThisFolderSoon(); + } #endif } diff --git a/src/gui/tray/ActivityListModel.cpp b/src/gui/tray/ActivityListModel.cpp index a2d39252d..053d725f4 100644 --- a/src/gui/tray/ActivityListModel.cpp +++ b/src/gui/tray/ActivityListModel.cpp @@ -448,7 +448,9 @@ void ActivityListModel::triggerDefaultAction(int activityIndex) const dialog.setBaseFilename(baseName); dialog.setLocalVersionFilename(conflictedPath); dialog.setRemoteVersionFilename(basePath); - dialog.exec(); + if (dialog.exec() == ConflictDialog::Accepted) { + folder->scheduleThisFolderSoon(); + } return; } -- 2.30.2