suffix_number++;
}
if (!file.rename(f.absoluteFilePath(), path + QString::number(suffix_number))) { // rename(file old path, file trash path)
- *errorString = QCoreApplication::translate("FileSystem", "Could not move '%1' to '%2'")
+ *errorString = QCoreApplication::translate("FileSystem", "Could not move \"%1\" to \"%1\"")
.arg(f.absoluteFilePath(), path + QString::number(suffix_number));
return false;
}
} else {
if (!file.rename(f.absoluteFilePath(), trashFilePath + f.fileName())) { // rename(file old path, file trash path)
- *errorString = QCoreApplication::translate("FileSystem", "Could not move '%1' to '%2'")
+ *errorString = QCoreApplication::translate("FileSystem", "Could not move \"%1\" to \"%1\"")
.arg(f.absoluteFilePath(), trashFilePath + f.fileName());
return false;
}
{
setWindowTitle(tr("Authentication Required"));
auto *lay = new QVBoxLayout(this);
- auto *label = new QLabel(tr("Enter username and password for '%1' at %2.").arg(realm, domain));
+ auto *label = new QLabel(tr("Enter username and password for \"%1\" at %2.").arg(realm, domain));
label->setTextFormat(Qt::PlainText);
lay->addWidget(label);
// Build status details text
QString msg;
if (!progress._currentDiscoveredRemoteFolder.isEmpty()) {
- msg = tr("Checking for changes in '%1'").arg(progress._currentDiscoveredRemoteFolder);
+ msg = tr("Checking for changes in \"%1\"").arg(progress._currentDiscoveredRemoteFolder);
} else if (progress.totalSize() == 0) {
qint64 currentFile = progress.currentFile();
qint64 totalFileCount = qMax(progress.totalFiles(), currentFile);
errorReason = tr("Error returned from the server: <em>%1</em>")
.arg(errorFromJson.toHtmlEscaped());
} else if (reply->error() != QNetworkReply::NoError) {
- errorReason = tr("There was an error accessing the 'token' endpoint: <br><em>%1</em>")
+ errorReason = tr("There was an error accessing the \"token\" endpoint: <br><em>%1</em>")
.arg(reply->errorString().toHtmlEscaped());
} else if (jsonParseError.error != QJsonParseError::NoError) {
errorReason = tr("Could not parse the JSON returned from the server: <br><em>%1</em>")
errorReason = tr("Error returned from the server: <em>%1</em>")
.arg(errorFromJson.toHtmlEscaped());
} else if (reply->error() != QNetworkReply::NoError) {
- errorReason = tr("There was an error accessing the 'token' endpoint: <br><em>%1</em>")
+ errorReason = tr("There was an error accessing the \"token\" endpoint: <br><em>%1</em>")
.arg(reply->errorString().toHtmlEscaped());
} else if (jsonParseError.error != QJsonParseError::NoError) {
errorReason = tr("Could not parse the JSON returned from the server: <br><em>%1</em>")
}
if (!_fetchErrorString.isEmpty()) {
msg += QLatin1String("<br>")
- + tr("Reading from keychain failed with error: '%1'")
+ + tr("Reading from keychain failed with error: \"%1\"")
.arg(Utility::escape(_fetchErrorString))
+ QLatin1String("<br>");
}
return;
}
- const QString msg = dir == SyncFileItem::Down ? tr("All files in the sync folder '%1' folder were deleted on the server.\n"
+ const QString msg = dir == SyncFileItem::Down ? tr("All files in the sync folder \"%1\" folder were deleted on the server.\n"
"These deletes will be synchronized to your local sync folder, making such files "
"unavailable unless you have a right to restore. \n"
"If you decide to restore the files, they will be re-synced with the server if you have rights to do so.\n"
"If you decide to delete the files, they will be unavailable to you, unless you are the owner.")
- : tr("All the files in your local sync folder '%1' were deleted. These deletes will be "
+ : tr("All the files in your local sync folder \"%1\" were deleted. These deletes will be "
"synchronized with your server, making such files unavailable unless restored.\n"
"Are you sure you want to sync those actions with the server?\n"
"If this was an accident and you decide to keep your files, they will be re-synced from the server.");
while (QFile::exists(journalDbFile) && !QFile::remove(journalDbFile)) {
qCWarning(lcFolderMan) << "Could not remove old db file at" << journalDbFile;
int ret = QMessageBox::warning(nullptr, tr("Could not reset folder state"),
- tr("An old sync journal '%1' was found, "
+ tr("An old sync journal \"%1\" was found, "
"but could not be removed. Please make sure "
"that no application is currently using it.")
.arg(QDir::fromNativeSeparators(QDir::cleanPath(journalDbFile))),
if (progress.status() == ProgressInfo::Discovery) {
if (!progress._currentDiscoveredRemoteFolder.isEmpty()) {
- pi->_overallSyncString = tr("Checking for changes in remote '%1'").arg(progress._currentDiscoveredRemoteFolder);
+ pi->_overallSyncString = tr("Checking for changes in remote \"%1\"").arg(progress._currentDiscoveredRemoteFolder);
emit dataChanged(index(folderIndex), index(folderIndex), roles);
return;
} else if (!progress._currentDiscoveredLocalFolder.isEmpty()) {
- pi->_overallSyncString = tr("Checking for changes in local '%1'").arg(progress._currentDiscoveredLocalFolder);
+ pi->_overallSyncString = tr("Checking for changes in local \"%1\"").arg(progress._currentDiscoveredLocalFolder);
emit dataChanged(index(folderIndex), index(folderIndex), roles);
return;
}
auto *dlg = new QInputDialog(this);
dlg->setWindowTitle(tr("Create Remote Folder"));
- dlg->setLabelText(tr("Enter the name of the new folder to be created below '%1':")
+ dlg->setLabelText(tr("Enter the name of the new folder to be created below \"%1\":")
.arg(parent));
dlg->open(this, SLOT(slotCreateRemoteFolder(QString)));
dlg->setAttribute(Qt::WA_DeleteOnClose);
ConfigFile cfgFile;
//FIXME This is not true. The entries are hardcoded below in setupTableReadOnlyItems
- readOnlyTooltip = tr("This entry is provided by the system at '%1' "
+ readOnlyTooltip = tr("This entry is provided by the system at \"%1\" "
"and cannot be modified in this view.")
.arg(QDir::toNativeSeparators(cfgFile.excludeFile(ConfigFile::SystemScope)));
}
} else {
QMessageBox::warning(this, tr("Could not open file"),
- tr("Cannot write changes to '%1'.").arg(file));
+ tr("Cannot write changes to \"%1\".").arg(file));
}
ignores.close(); //close the file before reloading stuff.
if (progress.status() == ProgressInfo::Discovery) {
#if 0
if (!progress._currentDiscoveredRemoteFolder.isEmpty()) {
- _actionStatus->setText(tr("Checking for changes in remote '%1'")
+ _actionStatus->setText(tr("Checking for changes in remote \"%1\"")
.arg(progress._currentDiscoveredRemoteFolder));
} else if (!progress._currentDiscoveredLocalFolder.isEmpty()) {
- _actionStatus->setText(tr("Checking for changes in local '%1'")
+ _actionStatus->setText(tr("Checking for changes in local \"%1\"")
.arg(progress._currentDiscoveredLocalFolder));
}
#endif
return;
}
errorMsg = tr("The authenticated request to the server was redirected to "
- "'%1'. The URL is bad, the server is misconfigured.")
+ "\"%1\". The URL is bad, the server is misconfigured.")
.arg(Utility::escape(redirectUrl.toString()));
// A 404 is actually a success: we were authorized to know that the folder does
_pi_sharee.stopAnimation();
if (_completerModel->rowCount() == 0) {
- displayError(0, tr("No results for '%1'").arg(_completerModel->currentSearch()));
+ displayError(0, tr("No results for \"%1\"").arg(_completerModel->currentSearch()));
}
// if no rows are present in the model - complete() will hide the completer
if (_remoteFolder.isEmpty() || _remoteFolder == QLatin1String("/")) {
t = "";
} else {
- t = Utility::escape(tr("%1 folder '%2' is synced to local folder '%3'")
+ t = Utility::escape(tr("%1 folder \"%2\" is synced to local folder \"%3\"")
.arg(Theme::instance()->appName(), _remoteFolder,
QDir::toNativeSeparators(locFolder)));
- _ui.rSyncEverything->setText(tr("Sync the folder '%1'").arg(_remoteFolder));
+ _ui.rSyncEverything->setText(tr("Sync the folder \"%1\"").arg(_remoteFolder));
}
const bool dirNotEmpty(QDir(locFolder).entryList(QDir::AllEntries | QDir::NoDotAndDotDot).count() > 0);
}
}
if (invalid) {
- item->_errorString = tr("File names containing the character '%1' are not supported on this file system.")
+ item->_errorString = tr("File names containing the character \"%1\" are not supported on this file system.")
.arg(QLatin1Char(invalid));
}
if (isInvalidPattern) {
emit this->finished();
} else {
// Fatal for the root job since it has no SyncFileItem, or for the network errors
- emit _discoveryData->fatalError(tr("Server replied with an error while reading directory '%1' : %2")
+ emit _discoveryData->fatalError(tr("Server replied with an error while reading directory \"%1\" : %2")
.arg(_currentFolder._server, results.error().message));
}
}
onDeleted(di.filePath(), false);
} else {
if (errors) {
- errors->append(QCoreApplication::translate("FileSystem", "Error removing '%1': %2")
+ errors->append(QCoreApplication::translate("FileSystem", "Error removing \"%1\": %2")
.arg(QDir::toNativeSeparators(di.filePath()), removeError));
}
qCWarning(lcFileSystem) << "Error removing " << di.filePath() << ':' << removeError;
onDeleted(path, true);
} else {
if (errors) {
- errors->append(QCoreApplication::translate("FileSystem", "Could not remove folder '%1'")
+ errors->append(QCoreApplication::translate("FileSystem", "Could not remove folder \"%1\"")
.arg(QDir::toNativeSeparators(path)));
}
qCWarning(lcFileSystem) << "Error removing folder" << path;
if (!openSucceeded) {
locker.unlock(); // Just in case postGuiMessage has a qDebug()
postGuiMessage(tr("Error"),
- QString(tr("<nobr>File '%1'<br/>cannot be opened for writing.<br/><br/>"
+ QString(tr("<nobr>File \"%1\"<br/>cannot be opened for writing.<br/><br/>"
"The log output can <b>not</b> be saved!</nobr>"))
.arg(name));
return;