Skip to content

Commit

Permalink
Improve sync status text.
Browse files Browse the repository at this point in the history
Signed-off-by: Camila Ayres <[email protected]>
  • Loading branch information
camilasan committed Apr 24, 2024
1 parent 8c81539 commit c6da2f6
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/gui/folderstatusmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1176,7 +1176,7 @@ void FolderStatusModel::slotFolderSyncStateChange(Folder *folder)
}

auto &pi = _folders[folderIndex]._progress;

const auto shortFolderPath = folder->shortGuiRemotePathOrAppName();
const auto state = folder->syncResult().status();
if (!folder->canSync() || state == SyncResult::Problem || state == SyncResult::Success || state == SyncResult::Error) {
// Reset progress info.
Expand All @@ -1188,12 +1188,13 @@ void FolderStatusModel::slotFolderSyncStateChange(Folder *folder)
if (other != folder && other->isSyncRunning())
pos += 1;
}
const auto message = pos <= 0 ? tr("Waiting …") : tr("Waiting for %n other folder(s) …", "", pos);
const auto message = pos <= 0 ? tr("Processing changes in folder %1 …").arg(shortFolderPath)
: tr("Processing changes in %n folder(s) …", "", pos);
pi = SubFolderInfo::Progress();
pi._overallSyncString = message;
} else if (state == SyncResult::SyncPrepare) {
pi = SubFolderInfo::Progress();
pi._overallSyncString = tr("Preparing to sync ");
pi._overallSyncString = tr("Preparing to sync folder %1 …").arg(shortFolderPath);
}

// update the icon etc. now
Expand Down

0 comments on commit c6da2f6

Please sign in to comment.