]> cloud.milkyroute.net Git - dolphin.git/commitdiff
* the directory lister must be updated when reloading columns
authorPeter Penz <peter.penz19@gmail.com>
Tue, 25 Sep 2007 12:03:57 +0000 (12:03 +0000)
committerPeter Penz <peter.penz19@gmail.com>
Tue, 25 Sep 2007 12:03:57 +0000 (12:03 +0000)
* ignore trailing slashes when comparing URLs

svn path=/trunk/KDE/kdebase/apps/; revision=716858

src/dolphincolumnview.cpp

index 119888f2d0b9430b8d119d4d939185b5bd13fa47..381a795e1ce0b061ac8e2a689d456fd5e518196d 100644 (file)
@@ -757,7 +757,9 @@ void DolphinColumnView::expandToActiveUrl()
     Q_ASSERT(lastIndex >= 0);
     const KUrl& activeUrl = m_columns[lastIndex]->url();
     const KUrl rootUrl = m_dolphinModel->dirLister()->url();
-    if (rootUrl.isParentOf(activeUrl) && (rootUrl != activeUrl)) {
+    const bool expand = rootUrl.isParentOf(activeUrl)
+                        && !rootUrl.equals(activeUrl, KUrl::CompareWithoutTrailingSlash);
+    if (expand) {
         m_dolphinModel->expandToUrl(activeUrl);
         reloadColumns();
     }
@@ -775,6 +777,10 @@ void DolphinColumnView::reloadColumns()
     const int end = m_columns.count() - 2; // next to last column
     for (int i = 0; i <= end; ++i) {
         ColumnWidget* nextColumn = m_columns[i + 1];
+
+        KDirLister* dirLister = m_dolphinModel->dirLister();
+        dirLister->updateDirectory(nextColumn->url());
+
         const QModelIndex rootIndex = nextColumn->rootIndex();
         if (rootIndex.isValid()) {
             nextColumn->show();