});
_folderForFile->setSilenceErrorsUntilNextSync(true);
_folderForFile->slotTerminateSync();
+ _shouldScheduleFolderSyncAfterFileIsOpened = true;
return;
}
void EditLocallyJob::openFile()
{
+ Q_ASSERT(_folderForFile);
+
if(_localFilePath.isEmpty()) {
qCWarning(lcEditLocallyJob) << "Could not edit locally. Invalid local file path.";
return;
}
Systray::instance()->destroyEditFileLocallyLoadingDialog();
+
+ if (_shouldScheduleFolderSyncAfterFileIsOpened) {
+ _folderForFile->startSync();
+ }
+
emit finished();
});
}
bool _tokenVerified = false;
+ bool _shouldScheduleFolderSyncAfterFileIsOpened = false;
+
AccountStatePtr _accountState;
QString _userId;
QString _relPath; // full remote path for a file (as on the server)