2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

Several working accounts together.

This commit is contained in:
John Preston
2020-06-16 10:42:47 +04:00
parent 6fc5e22882
commit ab5796c117
14 changed files with 97 additions and 60 deletions

View File

@@ -50,11 +50,10 @@ using Database = Storage::Cache::Database;
QString _basePath, _userBasePath, _userDbPath;
bool _started = false;
internal::Manager *_manager = nullptr;
TaskQueue *_localLoader = nullptr;
bool _working() {
return _manager && !_basePath.isEmpty();
return !_basePath.isEmpty();
}
bool CheckStreamStatus(QDataStream &stream) {
@@ -290,12 +289,7 @@ bool _readOldMtpData(bool remove, ReadSettingsContext &context) {
} // namespace
void finish() {
if (_manager) {
_manager->finish();
_manager->deleteLater();
_manager = nullptr;
delete base::take(_localLoader);
}
delete base::take(_localLoader);
}
void InitialLoadTheme();
@@ -303,9 +297,8 @@ bool ApplyDefaultNightMode();
void readLangPack();
void start() {
Expects(!_manager);
Expects(_basePath.isEmpty());
_manager = new internal::Manager();
_localLoader = new TaskQueue(kFileLoaderQueueStopTimeout);
_basePath = cWorkingDir() + qsl("tdata/");
@@ -1081,13 +1074,4 @@ void ClearManager::onStart() {
}
}
namespace internal {
Manager::Manager() {
}
void Manager::finish() {
}
} // namespace internal
} // namespace Local