Use split ranges to export all messages.

This commit is contained in:
John Preston
2018-06-21 15:01:27 +01:00
parent 36fb6dac89
commit d056c00c67
8 changed files with 231 additions and 97 deletions
@@ -465,7 +465,9 @@ void Controller::exportNextDialog() {
return false;
}
_messagesWritten = 0;
_messagesCount = info.messagesCount;
_messagesCount = ranges::accumulate(
info.messagesCountPerSplit,
0);
setState(stateDialogs(DownloadProgress()));
return true;
}, [=](DownloadProgress progress) {
@@ -509,7 +511,9 @@ void Controller::exportNextLeftChannel() {
return false;
}
_messagesWritten = 0;
_messagesCount = info.messagesCount;
_messagesCount = ranges::accumulate(
info.messagesCountPerSplit,
0);
setState(stateLeftChannels(DownloadProgress()));
return true;
}, [=](DownloadProgress progress) {