mirror of
https://invent.kde.org/system/dolphin
synced 2024-11-05 18:47:12 +00:00
Don't rely on that the same proxy model is used for all views. Trigger a refresh of the directory (done from the cache) and remember the selection. This fixes also the issue that the selection got lost when previews have been enabled or when the column view was used.
BUG: 217562 CCBUG: 211149 svn path=/trunk/KDE/kdebase/apps/; revision=1063960
This commit is contained in:
parent
ea258a5f09
commit
11abae0a1d
1 changed files with 5 additions and 3 deletions
|
@ -222,6 +222,10 @@ void DolphinView::setMode(Mode mode)
|
|||
const int oldZoomLevel = m_controller->zoomLevel();
|
||||
m_mode = mode;
|
||||
|
||||
// remember the currently selected items, so that they will
|
||||
// be restored after reloading the directory
|
||||
m_selectedItems = selectedItems();
|
||||
|
||||
deleteView();
|
||||
|
||||
const KUrl viewPropsUrl = rootUrl();
|
||||
|
@ -248,9 +252,7 @@ void DolphinView::setMode(Mode mode)
|
|||
emit modeChanged();
|
||||
|
||||
updateZoomLevel(oldZoomLevel);
|
||||
if (m_showPreview) {
|
||||
loadDirectory(viewPropsUrl);
|
||||
}
|
||||
loadDirectory(viewPropsUrl);
|
||||
}
|
||||
|
||||
DolphinView::Mode DolphinView::mode() const
|
||||
|
|
Loading…
Reference in a new issue