#include "treeviewsidebarpage.h"
+#include "bookmarkselector.h"
#include "dolphinmainwindow.h"
#include "dolphinview.h"
void TreeViewSidebarPage::updatePosition(const KUrl& url)
{
+ KUrl baseUrl = BookmarkSelector::baseBookmark(url).url();
+ if (m_dirLister->url() != baseUrl) {
+ m_dirLister->stop();
+ m_dirLister->openUrl(baseUrl);
+ }
+
+ // TODO: open sub folders to be synchronous to 'url'
}
void TreeViewSidebarPage::connectToActiveView()
{
DolphinView* view = mainWindow()->activeView();
- m_dirLister->openUrl(view->url(), true);
+ m_dirLister->stop();
+ m_dirLister->openUrl(view->url());
connect(view, SIGNAL(urlChanged(const KUrl&)),
this, SLOT(updatePosition(const KUrl&)));
}