#include <QGraphicsSceneDragDropEvent>
#include <QTimer>
#include <QScrollBar>
+#include <QPixmapCache>
#include <QPointer>
#include <QMenu>
#include <QVBoxLayout>
QDataStream saveStream(&viewState, QIODevice::WriteOnly);
saveState(saveStream);
- const KFileItemList itemList = selectedItems();
- m_selectedUrls.clear();
- m_selectedUrls = itemList.urlList();
-
setUrl(url());
loadDirectory(url(), true);
clearSelection();
- emit urlAboutToBeChanged(url);
m_url = url;
hideToolTip();
switch (event->type()) {
case QEvent::PaletteChange:
updatePalette();
+ QPixmapCache::clear();
break;
case QEvent::KeyPress:
const QPoint pos = m_container->mapToGlobal(itemRect.topLeft().toPoint());
itemRect.moveTo(pos);
- m_toolTipManager->showToolTip(item, itemRect);
+ m_toolTipManager->showToolTip(item, itemRect, nativeParentWidget()->windowHandle());
}
emit requestItemInfo(item);
// Restore the current item that had the keyboard focus
stream >> m_currentItemUrl;
+ // Restore the previously selected items
+ stream >> m_selectedUrls;
+
// Restore the view position
stream >> m_restoredContentsPosition;
stream << QUrl();
}
+ // Save the selected urls
+ stream << selectedItems().urlList();
+
// Save view position
const qreal x = m_container->horizontalScrollBar()->value();
const qreal y = m_container->verticalScrollBar()->value();
}
}
+ selectionManager->beginAnchoredSelection(selectionManager->currentItem());
selectionManager->setSelectedItems(selectedItems);
}
}