diff options
| author | Peter Penz <[email protected]> | 2008-05-28 20:40:16 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2008-05-28 20:40:16 +0000 |
| commit | e54e6a9cdbc0e37e7c81abcea4e69838cddabaa3 (patch) | |
| tree | cc6f04e75706796a9a53424663e02f77d62b24a8 /src/dolphinviewcontainer.cpp | |
| parent | b445156dd40a16877058f8228900679cb27aa4cc (diff) | |
Move the code for restoring the current item from DolphinViewContainer to DolphinView, as the DolphinView must be able to do this without advice from the container.
Beside that this simplifies the code it also fixes a regression of having empty tabs.
svn path=/trunk/KDE/kdebase/apps/; revision=813828
Diffstat (limited to 'src/dolphinviewcontainer.cpp')
| -rw-r--r-- | src/dolphinviewcontainer.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/dolphinviewcontainer.cpp b/src/dolphinviewcontainer.cpp index 6bc620ee2..7179c5080 100644 --- a/src/dolphinviewcontainer.cpp +++ b/src/dolphinviewcontainer.cpp @@ -68,9 +68,7 @@ DolphinViewContainer::DolphinViewContainer(DolphinMainWindow* mainWindow, m_filterBar(0), m_statusBar(0), m_dirLister(0), - m_proxyModel(0), - m_previousUrl(), - m_currentUrl() + m_proxyModel(0) { hide(); @@ -171,16 +169,12 @@ DolphinViewContainer::~DolphinViewContainer() void DolphinViewContainer::setUrl(const KUrl& newUrl) { - if (newUrl != m_currentUrl) { - m_previousUrl = m_currentUrl; - m_currentUrl = newUrl; - m_urlNavigator->setUrl(newUrl); - } + m_urlNavigator->setUrl(newUrl); } const KUrl& DolphinViewContainer::url() const { - return m_currentUrl; + return m_urlNavigator->url(); } void DolphinViewContainer::setActive(bool active) @@ -234,7 +228,6 @@ void DolphinViewContainer::slotDirListerCompleted() } updateStatusBar(); - m_view->setCurrentItem(m_previousUrl); QTimer::singleShot(100, this, SLOT(restoreContentsPos())); } |
