diff options
| author | Laurent Montel <[email protected]> | 2019-09-08 09:33:41 +0200 |
|---|---|---|
| committer | Laurent Montel <[email protected]> | 2019-09-08 09:33:41 +0200 |
| commit | 81065795b78e06ec679ec0589fba7082e777ef2a (patch) | |
| tree | 67acbba969c750a69734326179815474be25f42b /src/panels/folders | |
| parent | dfe713edf0c3b0b44ff18c19ebd4d616a9004f48 (diff) | |
GIT_SILENT: minor qstring optimization
Diffstat (limited to 'src/panels/folders')
| -rw-r--r-- | src/panels/folders/folderspanel.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/panels/folders/folderspanel.cpp b/src/panels/folders/folderspanel.cpp index 020c41e55..01f338461 100644 --- a/src/panels/folders/folderspanel.cpp +++ b/src/panels/folders/folderspanel.cpp @@ -111,7 +111,7 @@ void FoldersPanel::rename(const KFileItem& item) bool FoldersPanel::urlChanged() { - if (!url().isValid() || url().scheme().contains(QStringLiteral("search"))) { + if (!url().isValid() || url().scheme().contains(QLatin1String("search"))) { // Skip results shown by a search, as possible identical // directory names are useless without parent-path information. return false; @@ -258,7 +258,7 @@ void FoldersPanel::slotRoleEditingFinished(int index, const QByteArray& role, co if (role == "text") { const KFileItem item = m_model->fileItem(index); const QString newName = value.toString(); - if (!newName.isEmpty() && newName != item.text() && newName != QLatin1String(".") && newName != QLatin1String("..")) { + if (!newName.isEmpty() && newName != item.text() && newName != QLatin1Char('.') && newName != QLatin1String("..")) { const QUrl oldUrl = item.url(); QUrl newUrl = oldUrl.adjusted(QUrl::RemoveFilename); newUrl.setPath(newUrl.path() + KIO::encodeFileName(newName)); |
