┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinurlnavigator.cpp
diff options
context:
space:
mode:
authorNate Graham <[email protected]>2020-12-10 15:16:12 -0700
committerElvis Angelaccio <[email protected]>2020-12-27 17:38:55 +0000
commitb14f98de19b97bcf8ca967f635c6df39963df2b0 (patch)
treedf17b6b5b22f05bdc78cedb77a36da0d5421825e /src/dolphinurlnavigator.cpp
parent88d3f92dff4f153308092d8301b57c2bb8e4b03e (diff)
Make it more obvious that you can connect to servers on remote:/ page
Right now it is not super obvious how you connect to a remote server in Dolphin when you already know the URL. Users will go to the "Network" item in the Places panel, but from there it is not totally clear. The "Add Network Folder" icon in the view opens a complicated wizard and it's also a bit of an odd UX to have it living in the view as opposed to being a toolbar button. Old hands and developers know that the URL navigator is, well, a URL navigator, and as such, it accepts arbitrary URLs from any view. However this may not be obvious to other more casual users, for two reasons: 1. The URL navigator is in breadcrumbs view nearly all of the time and by default, so may users may not know that it can accept text at all 2. Even when it's displaying URLs, they are almost always local paths, so users may not make the connection that it can accept remote URLs rather that just local paths To improve the discoverability of this feature, this commit makes the following change: When the view is displaying the remote:/ ioslave (i.e. the "Networks" place), the URL navigator is put into URL entry mode and given some placeholder text that hints at what it can do. It reverts to breadcrumbs mode when you leave. BUG: 414670 FIXED-IN: 21.04
Diffstat (limited to 'src/dolphinurlnavigator.cpp')
-rw-r--r--src/dolphinurlnavigator.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/dolphinurlnavigator.cpp b/src/dolphinurlnavigator.cpp
index 1dfe5420f..d8d325bb4 100644
--- a/src/dolphinurlnavigator.cpp
+++ b/src/dolphinurlnavigator.cpp
@@ -101,6 +101,16 @@ void DolphinUrlNavigator::setVisualState(const VisualState& visualState)
}
}
+void DolphinUrlNavigator::clearText() const
+{
+ editor()->lineEdit()->clear();
+}
+
+void DolphinUrlNavigator::setPlaceholderText(const QString &text)
+{
+ editor()->lineEdit()->setPlaceholderText(text);
+}
+
void DolphinUrlNavigator::slotReturnPressed()
{
if (!GeneralSettings::editableUrl()) {