ui->bigFolderUi->setVisible(false);
} else {
ConfigFile cfg;
- QString info =
- !cfg.confirmExternalStorage() ? tr("There are folders that were not synchronized because they are too big: ") :
- !cfg.newBigFolderSizeLimit().first ? tr("There are folders that were not synchronized because they are external storages: ") :
- tr("There are folders that were not synchronized because they are too big or external storages: ");
+ QString info = !cfg.confirmExternalStorage()
+ ? tr("There are folders that were not synchronized because they are too big: ")
+ : !cfg.newBigFolderSizeLimit().first
+ ? tr("There are folders that were not synchronized because they are external storages: ")
+ : tr("There are folders that were not synchronized because they are too big or external storages: ");
ui->selectiveSyncNotification->setText(info + msg);
ui->selectiveSyncButtons->setVisible(false);
msg += QLatin1String("<br>") + reqTxt + QLatin1String("<br>");
}
if (!_fetchErrorString.isEmpty()) {
- msg += QLatin1String("<br>") + tr("Reading from keychain failed with error: '%1'").arg(
- Utility::escape(_fetchErrorString)) + QLatin1String("<br>");
+ msg += QLatin1String("<br>")
+ + tr("Reading from keychain failed with error: '%1'")
+ .arg(Utility::escape(_fetchErrorString)) + QLatin1String("<br>");
}
QInputDialog dialog;
if(renTarget != renSource) {
status = LogStatusMove;
}
- createGuiLog( _syncResult.firstItemRenamed()->_originalFile, status, _syncResult.numRenamedItems(), _syncResult.firstItemRenamed()->_renameTarget );
+ createGuiLog( _syncResult.firstItemRenamed()->_originalFile, status,
+ _syncResult.numRenamedItems(), _syncResult.firstItemRenamed()->_renameTarget );
}
if( _syncResult.firstConflictItem() ) {
if (f) {
// do only send UPDATE_VIEW for a couple of status
- if( f->syncResult().status() == SyncResult::SyncPrepare ||
- f->syncResult().status() == SyncResult::Success ||
- f->syncResult().status() == SyncResult::Paused ||
- f->syncResult().status() == SyncResult::Problem ||
- f->syncResult().status() == SyncResult::Error ||
- f->syncResult().status() == SyncResult::SetupError ) {
+ if( f->syncResult().status() == SyncResult::SyncPrepare
+ || f->syncResult().status() == SyncResult::Success
+ || f->syncResult().status() == SyncResult::Paused
+ || f->syncResult().status() == SyncResult::Problem
+ || f->syncResult().status() == SyncResult::Error
+ || f->syncResult().status() == SyncResult::SetupError ) {
QString rootPath = removeTrailingSlash(f->path());
broadcastStatusPushMessage(rootPath, f->syncEngine().syncFileStatusTracker().fileStatus(""));
// necessary indication only, not sufficient for primary validation!
static bool isSelfSigned(const QSslCertificate &certificate)
{
- return certificate.issuerInfo(QSslCertificate::CommonName) == certificate.subjectInfo(QSslCertificate::CommonName) &&
- certificate.issuerInfo(QSslCertificate::OrganizationalUnitName) == certificate.subjectInfo(QSslCertificate::OrganizationalUnitName);
+ return certificate.issuerInfo(QSslCertificate::CommonName) == certificate.subjectInfo(QSslCertificate::CommonName)
+ && certificate.issuerInfo(QSslCertificate::OrganizationalUnitName) == certificate.subjectInfo(QSslCertificate::OrganizationalUnitName);
}
QMenu* SslButton::buildCertMenu(QMenu *parent, const QSslCertificate& cert,
#else
QByteArray sha265hash = cert.digest(QCryptographicHash::Sha256).toHex();
QString sha256escaped =
- Utility::escape(Utility::formatFingerprint(sha265hash.left(sha265hash.length()/2), false)) +
- QLatin1String("<br/>") +
- Utility::escape(Utility::formatFingerprint(sha265hash.mid(sha265hash.length()/2), false));
+ Utility::escape(Utility::formatFingerprint(sha265hash.left(sha265hash.length()/2), false))
+ + QLatin1String("<br/>")
+ + Utility::escape(Utility::formatFingerprint(sha265hash.mid(sha265hash.length()/2), false));
#endif
QString serial = QString::fromUtf8(cert.serialNumber());
QString effectiveDate = cert.effectiveDate().date().toString();
// find trust anchor (informational only, verification is done by QSslSocket!)
foreach(QSslCertificate rootCA, QSslSocket::systemCaCertificates()) {
- if (rootCA.issuerInfo(QSslCertificate::CommonName) == chain.last().issuerInfo(QSslCertificate::CommonName) &&
- rootCA.issuerInfo(QSslCertificate::Organization) == chain.last().issuerInfo(QSslCertificate::Organization)) {
+ if (rootCA.issuerInfo(QSslCertificate::CommonName) == chain.last().issuerInfo(QSslCertificate::CommonName)
+ && rootCA.issuerInfo(QSslCertificate::Organization) == chain.last().issuerInfo(QSslCertificate::Organization)) {
chain.append(rootCA);
break;
}
// Normally we expect "204 No Content"
// If it is not the case, it might be because of a proxy or gateway intercepting the request, so we must
// throw an error.
- done(SyncFileItem::NormalError, tr("Wrong HTTP code returned by server. Expected 204, but received \"%1 %2\".")
- .arg(_item->_httpErrorCode).arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
+ done(SyncFileItem::NormalError,
+ tr("Wrong HTTP code returned by server. Expected 204, but received \"%1 %2\".")
+ .arg(_item->_httpErrorCode)
+ .arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
return;
}
// Normally we expect "201 Created"
// If it is not the case, it might be because of a proxy or gateway intercepting the request, so we must
// throw an error.
- done(SyncFileItem::NormalError, tr("Wrong HTTP code returned by server. Expected 201, but received \"%1 %2\".")
- .arg(_item->_httpErrorCode).arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
+ done(SyncFileItem::NormalError,
+ tr("Wrong HTTP code returned by server. Expected 201, but received \"%1 %2\".")
+ .arg(_item->_httpErrorCode)
+ .arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
return;
}
// Normally we expect "201 Created"
// If it is not the case, it might be because of a proxy or gateway intercepting the request, so we must
// throw an error.
- done(SyncFileItem::NormalError, tr("Wrong HTTP code returned by server. Expected 201, but received \"%1 %2\".")
- .arg(_item->_httpErrorCode).arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
+ done(SyncFileItem::NormalError,
+ tr("Wrong HTTP code returned by server. Expected 201, but received \"%1 %2\".")
+ .arg(_item->_httpErrorCode)
+ .arg(_job->reply()->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toString()));
return;
}
// Fixme: the file that is the reason for the clash could be named here,
// it would have to come out the localFileNameClash function
- done(SyncFileItem::NormalError, tr( "File %1 can not be renamed to %2 because of a local file name clash")
- .arg(QDir::toNativeSeparators(_item->_file)).arg(QDir::toNativeSeparators(_item->_renameTarget)) );
+ done(SyncFileItem::NormalError,
+ tr( "File %1 can not be renamed to %2 because of a local file name clash")
+ .arg(QDir::toNativeSeparators(_item->_file))
+ .arg(QDir::toNativeSeparators(_item->_renameTarget)) );
return;
}