m_fileItemListView->setEnabledSelectionToggles(GeneralSettings::showSelectionToggle());
controller()->setView(m_fileItemListView);
+ updateAutoActivationDelay();
updateFont();
updateGridSize();
}
ViewModeSettings settings(viewMode());
settings.readConfig();
+ beginTransaction();
+
+ m_fileItemListView->setEnabledSelectionToggles(GeneralSettings::showSelectionToggle());
+ updateAutoActivationDelay();
updateFont();
updateGridSize();
<< "imagethumbnail"
<< "jpegthumbnail");
m_fileItemListView->setEnabledPlugins(plugins);
+
+ endTransaction();
}
void DolphinItemListContainer::updateGridSize()
m_fileItemListView->setStyleOption(styleOption);
}
+void DolphinItemListContainer::updateAutoActivationDelay()
+{
+ const int delay = GeneralSettings::autoExpandFolders() ? 750 : -1;
+ controller()->setAutoActivationDelay(delay);
+}
+
ViewModeSettings::ViewMode DolphinItemListContainer::viewMode() const
{
ViewModeSettings::ViewMode mode;
void updateGridSize();
void updateFont();
+ /**
+ * Updates the auto activation delay of the itemlist controller
+ * dependent on the 'autoExpand' setting from the general settings.
+ */
+ void updateAutoActivationDelay();
+
ViewModeSettings::ViewMode viewMode() const;
private:
KItemListController* controller = m_container->controller();
controller->setSelectionBehavior(KItemListController::MultiSelection);
- if (GeneralSettings::autoExpandFolders()) {
- controller->setAutoActivationDelay(750);
- }
connect(controller, SIGNAL(itemActivated(int)), this, SLOT(slotItemActivated(int)));
connect(controller, SIGNAL(itemsActivated(QSet<int>)), this, SLOT(slotItemsActivated(QSet<int>)));
connect(controller, SIGNAL(itemMiddleClicked(int)), this, SLOT(slotItemMiddleClicked(int)));