┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinviewcontainer.cpp
diff options
context:
space:
mode:
authorAntonio Prcela <[email protected]>2020-04-14 09:12:04 -0600
committerNate Graham <[email protected]>2020-04-14 09:15:08 -0600
commit8de24d5802f8b1806ac26ad270e81cff1cae2111 (patch)
treefd0a2ef8567dc25b60e711fa5700a11b737333c6 /src/dolphinviewcontainer.cpp
parent514d9c8fc9705f76fda8f22c70730fb9c383c95a (diff)
Display readable titlebar text while using search and full paths in titlebar
Summary: BUG: 406624 FIXED-IN: 20.08 Reviewers: #vdg, #dolphin, iasensio, elvisangelaccio, ngraham, meven Reviewed By: #vdg, #dolphin, ngraham, meven Subscribers: meven, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D28815
Diffstat (limited to 'src/dolphinviewcontainer.cpp')
-rw-r--r--src/dolphinviewcontainer.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/dolphinviewcontainer.cpp b/src/dolphinviewcontainer.cpp
index bd3c8ed20..3a17805ab 100644
--- a/src/dolphinviewcontainer.cpp
+++ b/src/dolphinviewcontainer.cpp
@@ -451,6 +451,14 @@ void DolphinViewContainer::reload()
QString DolphinViewContainer::caption() const
{
+ if (isSearchModeEnabled()) {
+ if (currentSearchText().isEmpty()){
+ return i18n("Search");
+ } else {
+ return i18n("Search for %1", currentSearchText());
+ }
+ }
+
if (GeneralSettings::showFullPathInTitlebar()) {
if (!url().isLocalFile()) {
return url().adjusted(QUrl::StripTrailingSlash).toString();
@@ -465,13 +473,6 @@ QString DolphinViewContainer::caption() const
return placesModel->text(matchedPlaces.first());
}
- if (isSearchModeEnabled()) {
- if (currentSearchText().isEmpty()){
- return i18n("Search");
- } else {
- return i18n("Search for %1", currentSearchText());
- }
- }
if (!url().isLocalFile()) {
QUrl adjustedUrl = url().adjusted(QUrl::StripTrailingSlash);