┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinview.cpp
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2007-10-09 21:10:17 +0000
committerPeter Penz <[email protected]>2007-10-09 21:10:17 +0000
commit1d4cfd16fd5ceb8f37400d4890807e3c56619971 (patch)
treef2d6cf306175a65ed61ccd91474dced063169405 /src/dolphinview.cpp
parent0c1d1c42f4abeaa03522b3059c485788276464f7 (diff)
column view fixes:
* assure that the history does not get messed up when changing the focus to an existing column * fix issue that the status bar does not get updated when the focus is changed between the columns svn path=/trunk/KDE/kdebase/apps/; revision=723519
Diffstat (limited to 'src/dolphinview.cpp')
-rw-r--r--src/dolphinview.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/dolphinview.cpp b/src/dolphinview.cpp
index 51dbb708c..8361ceb06 100644
--- a/src/dolphinview.cpp
+++ b/src/dolphinview.cpp
@@ -88,8 +88,16 @@ DolphinView::DolphinView(QWidget* parent,
m_controller = new DolphinController(this);
m_controller->setUrl(url);
+
+ // Receiver of the DolphinView signal 'urlChanged()' don't need
+ // to care whether the internal controller changed the URL already or whether
+ // the controller just requested an URL change and will be updated later.
+ // In both cases the URL has been changed:
connect(m_controller, SIGNAL(urlChanged(const KUrl&)),
this, SIGNAL(urlChanged(const KUrl&)));
+ connect(m_controller, SIGNAL(requestUrlChange(const KUrl&)),
+ this, SIGNAL(urlChanged(const KUrl&)));
+
connect(m_controller, SIGNAL(requestContextMenu(const QPoint&)),
this, SLOT(openContextMenu(const QPoint&)));
connect(m_controller, SIGNAL(urlsDropped(const KUrl::List&, const KUrl&, const QModelIndex&, QWidget*)),
@@ -466,18 +474,11 @@ void DolphinView::updateView(const KUrl& url, const KUrl& rootUrl)
return;
}
- const bool restoreColumnView = !rootUrl.isEmpty()
- && !rootUrl.equals(url, KUrl::CompareWithoutTrailingSlash)
- && rootUrl.isParentOf(url);
-
m_controller->setUrl(url); // emits urlChanged, which we forward
- if (restoreColumnView) {
+ if (!rootUrl.isEmpty() && rootUrl.isParentOf(url)) {
applyViewProperties(rootUrl);
loadDirectory(rootUrl);
- // Restoring the column view relies on the URL-history. It might be possible
- // that the view properties have been changed or deleted in the meantime, so
- // it cannot be asserted that really a column view has been created:
if (itemView() == m_columnView) {
m_columnView->setRootUrl(rootUrl);
m_columnView->showColumn(url);