2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-06 17:45:11 +00:00

Update scheme for special export methods.

Export all saved contacts.
This commit is contained in:
John Preston
2018-06-15 00:47:09 +03:00
parent 241fee80a7
commit 9d02e539c8
11 changed files with 159 additions and 50 deletions

View File

@@ -157,9 +157,10 @@ void Controller::startExport(const Settings &settings) {
return;
}
_writer = Output::CreateWriter(_settings.format);
_api.startExport(_settings);
fillExportSteps();
exportNext();
_api.startExport(_settings, [=] {
exportNext();
});
}
bool Controller::normalizePath() {
@@ -207,9 +208,11 @@ void Controller::fillExportSteps() {
_steps.push_back(Step::Sessions);
}
const auto dialogTypes = Type::PersonalChats
| Type::BotChats
| Type::PrivateGroups
| Type::PublicGroups
| Type::MyChannels;
| Type::PrivateChannels
| Type::PublicChannels;
if (_settings.types & dialogTypes) {
_steps.push_back(Step::Dialogs);
}