┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmmanuel Pescosta <[email protected]>2012-08-18 15:11:53 +0200
committerEmmanuel Pescosta <[email protected]>2012-08-23 22:04:44 +0200
commite7793132e8fc1549bb7781b43dbee840211224e6 (patch)
tree0ce8509c92baacf39794194f0cd7ec172634b1c0
parent90e1e4e9f0a9a44ef7d97a257094fac976193dc7 (diff)
Select the correct item in places-panel, when a directory is opened.
BUG: 304541 REVIEW: 106074 FIXED-IN: 4.9.1 (cherry picked from commit 1ec8de2c619006e3fe997fbf6074035d65dea6c5)
-rw-r--r--src/panels/places/placespanel.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/panels/places/placespanel.cpp b/src/panels/places/placespanel.cpp
index 429c5399a..d4450888e 100644
--- a/src/panels/places/placespanel.cpp
+++ b/src/panels/places/placespanel.cpp
@@ -62,6 +62,16 @@ PlacesPanel::~PlacesPanel()
bool PlacesPanel::urlChanged()
{
+ if (!url().isValid() || url().protocol().contains("search")) {
+ // Skip results shown by a search, as possible identical
+ // directory names are useless without parent-path information.
+ return false;
+ }
+
+ if (m_controller) {
+ selectClosestItem();
+ }
+
return true;
}