#include <KActionMenu>
#include <KAuthorized>
#include <KConfig>
+#include <KConfigGui>
#include <KDualAction>
#include <KFileItemListProperties>
#include <KHelpMenu>
}
}
+ if (GeneralSettings::rememberOpenedTabs()) {
+ KConfigGui::setSessionConfig(QStringLiteral("dolphin"), QStringLiteral("dolphin"));
+ KConfig *config = KConfigGui::sessionConfig();
+ saveGlobalProperties(config);
+ savePropertiesInternal(config, 1);
+ config->sync();
+ }
+
GeneralSettings::setVersion(CurrentDolphinVersion);
GeneralSettings::self()->save();
void DolphinMainWindow::copy()
{
- m_activeViewContainer->view()->copySelectedItems();
+ m_activeViewContainer->view()->copySelectedItemsToClipboard();
}
void DolphinMainWindow::paste()
{
m_searchTools.clear();
KMoreToolsMenuFactory("dolphin/search-tools").fillMenuFromGroupingNames(
- &m_searchTools, { "files-find" }, QUrl::fromLocalFile(activeContainerLocalPath())
+ &m_searchTools, { "files-find" }, m_activeViewContainer->url()
);
QList<QAction*> actions = m_searchTools.actions();
if (actions.isEmpty()) {
void DolphinMainWindow::updateWindowTitle()
{
- const QString newTitle = m_activeViewContainer->caption();
+ const QString newTitle = m_activeViewContainer->captionWindowTitle();
if (windowTitle() != newTitle) {
setWindowTitle(newTitle);
}
QWhatsThisClickedEvent* whatsThisEvent = dynamic_cast<QWhatsThisClickedEvent*>(event);
QDesktopServices::openUrl(QUrl(whatsThisEvent->href()));
return true;
- } else if (event->type() == QEvent::WindowActivate) {
- updateOpenPreferredSearchToolAction();
}
return KXmlGuiWindow::event(event);
}