By defining the KF_DISABLE_DEPRECATED_BEFORE_AND_AT and QT_DISABLE_DEPRECATED_BEFOREvalues,
the deprecated overloads are hidden. This way we only have the un-deprecated one visible.
KIO::FileUndoManager* undoManager = KIO::FileUndoManager::self();
undoManager->setUiInterface(new UndoUiInterface());
- connect(undoManager, QOverload<bool>::of(&KIO::FileUndoManager::undoAvailable),
+ connect(undoManager, &KIO::FileUndoManager::undoAvailable,
this, &DolphinMainWindow::slotUndoAvailable);
connect(undoManager, &KIO::FileUndoManager::undoTextChanged,
this, &DolphinMainWindow::slotUndoTextChanged);
setupWhatsThis();
- connect(KSycoca::self(), QOverload<>::of(&KSycoca::databaseChanged), this, &DolphinMainWindow::updateOpenPreferredSearchToolAction);
+ connect(KSycoca::self(), &KSycoca::databaseChanged, this, &DolphinMainWindow::updateOpenPreferredSearchToolAction);
QTimer::singleShot(0, this, &DolphinMainWindow::updateOpenPreferredSearchToolAction);
connect(&DolphinNewFileMenuObserver::instance(), &DolphinNewFileMenuObserver::errorMessage,
this, &DolphinPart::slotErrorMessage);
- connect(m_view, &DolphinView::directoryLoadingCompleted, this, QOverload<>::of(&KParts::ReadOnlyPart::completed));
+ connect(m_view, &DolphinView::directoryLoadingCompleted, this, &KParts::ReadOnlyPart::completed);
connect(m_view, &DolphinView::directoryLoadingCompleted, this, &DolphinPart::updatePasteAction);
connect(m_view, &DolphinView::directoryLoadingProgress, this, &DolphinPart::updateProgress);
connect(m_view, &DolphinView::errorMessage, this, &DolphinPart::slotErrorMessage);
connect(m_view, &DolphinView::requestContextMenu,
this, &DolphinPart::slotOpenContextMenu);
connect(m_view, &DolphinView::selectionChanged,
- m_extension, QOverload<const KFileItemList&>::of(&KParts::BrowserExtension::selectionInfo));
+ m_extension, &KParts::BrowserExtension::selectionInfo);
connect(m_view, &DolphinView::selectionChanged,
this, &DolphinPart::slotSelectionChanged);
connect(m_view, &DolphinView::requestItemInfo,
}
connect(m_dirLister, &KCoreDirLister::started, this, &KFileItemModel::directoryLoadingStarted);
- connect(m_dirLister, QOverload<>::of(&KCoreDirLister::canceled), this, &KFileItemModel::slotCanceled);
+ connect(m_dirLister, &KCoreDirLister::canceled, this, &KFileItemModel::slotCanceled);
connect(m_dirLister, &KCoreDirLister::itemsAdded, this, &KFileItemModel::slotItemsAdded);
connect(m_dirLister, &KCoreDirLister::itemsDeleted, this, &KFileItemModel::slotItemsDeleted);
connect(m_dirLister, &KCoreDirLister::refreshItems, this, &KFileItemModel::slotRefreshItems);
- connect(m_dirLister, QOverload<>::of(&KCoreDirLister::clear), this, &KFileItemModel::slotClear);
+ connect(m_dirLister, &KCoreDirLister::clear, this, &KFileItemModel::slotClear);
connect(m_dirLister, &KCoreDirLister::infoMessage, this, &KFileItemModel::infoMessage);
connect(m_dirLister, &KCoreDirLister::jobError, this, &KFileItemModel::slotListerError);
connect(m_dirLister, &KCoreDirLister::percent, this, &KFileItemModel::directoryLoadingProgress);
- connect(m_dirLister, QOverload<const QUrl&, const QUrl&>::of(&KCoreDirLister::redirection), this, &KFileItemModel::directoryRedirection);
+ connect(m_dirLister, &KCoreDirLister::redirection, this, &KFileItemModel::directoryRedirection);
connect(m_dirLister, &KCoreDirLister::listingDirCompleted, this, &KFileItemModel::slotCompleted);
// Apply default roles that should be determined
combo->setFrame(false);
combo->setMinimumHeight(parentWidget()->height());
combo->setCurrentIndex(0);
- connect(combo, QOverload<int>::of(&QComboBox::activated), this, &DolphinFacetsWidget::facetChanged);
+ connect(combo, &QComboBox::activated, this, &DolphinFacetsWidget::facetChanged);
}
void DolphinFacetsWidget::updateTagsSelector()
loadSettings();
connect(m_listView, &QListView::clicked, this, &PreviewsSettingsPage::changed);
- connect(m_localFileSizeBox, QOverload<int>::of(&QSpinBox::valueChanged), this, &PreviewsSettingsPage::changed);
- connect(m_remoteFileSizeBox, QOverload<int>::of(&QSpinBox::valueChanged), this, &PreviewsSettingsPage::changed);
+ connect(m_localFileSizeBox, &QSpinBox::valueChanged, this, &PreviewsSettingsPage::changed);
+ connect(m_remoteFileSizeBox, &QSpinBox::valueChanged, this, &PreviewsSettingsPage::changed);
}
PreviewsSettingsPage::~PreviewsSettingsPage()
loadSettings();
- connect(m_proxy, QOverload<bool>::of(&KCModuleProxy::changed), this, &TrashSettingsPage::changed);
+ connect(m_proxy, &KCModuleProxy::changed, this, &TrashSettingsPage::changed);
}
TrashSettingsPage::~TrashSettingsPage()
m_modeCombo = new QComboBox(this);
m_modeCombo->addItem(i18nc("@item:inlistbox Font", "System Font"));
m_modeCombo->addItem(i18nc("@item:inlistbox Font", "Custom Font"));
- connect(m_modeCombo, QOverload<int>::of(&QComboBox::activated),
+ connect(m_modeCombo, &QComboBox::activated,
this, &DolphinFontRequester::changeMode);
m_chooseFontButton = new QPushButton(i18nc("@action:button Choose font", "Choose..."), this);
sortingModeGroup->addButton(m_sizeOfContents);
m_recursiveDirectorySizeLimit = new QSpinBox();
- connect(m_recursiveDirectorySizeLimit, QOverload<int>::of(&QSpinBox::valueChanged), this, [this](int value) {
+ connect(m_recursiveDirectorySizeLimit, &QSpinBox::valueChanged, this, [this](int value) {
m_recursiveDirectorySizeLimit->setSuffix(i18np(" level deep", " levels deep", value));
});
m_recursiveDirectorySizeLimit->setRange(1, 20);
switch (m_mode) {
case IconsMode:
- connect(m_widthBox, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &ViewSettingsTab::changed);
- connect(m_maxLinesBox, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &ViewSettingsTab::changed);
+ connect(m_widthBox, &QComboBox::currentIndexChanged, this, &ViewSettingsTab::changed);
+ connect(m_maxLinesBox, &QComboBox::currentIndexChanged, this, &ViewSettingsTab::changed);
break;
case CompactMode:
- connect(m_widthBox, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &ViewSettingsTab::changed);
+ connect(m_widthBox, &QComboBox::currentIndexChanged, this, &ViewSettingsTab::changed);
break;
case DetailsMode:
connect(m_expandableFolders, &QCheckBox::toggled, this, &ViewSettingsTab::changed);
#ifndef Q_OS_WIN
- connect(m_recursiveDirectorySizeLimit, QOverload<int>::of(&QSpinBox::valueChanged), this, &ViewSettingsTab::changed);
+ connect(m_recursiveDirectorySizeLimit, &QSpinBox::valueChanged, this, &ViewSettingsTab::changed);
connect(m_numberOfItems, &QRadioButton::toggled, this, &ViewSettingsTab::changed);
connect(m_sizeOfContents, &QRadioButton::toggled, this, [=]() {
m_recursiveDirectorySizeLimit->setEnabled(m_sizeOfContents->isChecked());
layout->addRow(QString(), m_showHiddenFiles);
layout->addRow(QString(), m_sortHiddenLast);
- connect(m_viewMode, QOverload<int>::of(&QComboBox::currentIndexChanged),
+ connect(m_viewMode, &QComboBox::currentIndexChanged,
this, &ViewPropertiesDialog::slotViewModeChanged);
- connect(m_sorting, QOverload<int>::of(&QComboBox::currentIndexChanged),
+ connect(m_sorting, &QComboBox::currentIndexChanged,
this, &ViewPropertiesDialog::slotSortingChanged);
- connect(m_sortOrder, QOverload<int>::of(&QComboBox::currentIndexChanged),
+ connect(m_sortOrder, &QComboBox::currentIndexChanged,
this, &ViewPropertiesDialog::slotSortOrderChanged);
connect(m_sortFoldersFirst, &QCheckBox::clicked,
this, &ViewPropertiesDialog::slotSortFoldersFirstChanged);
bool isTrashEmpty = m_trashDirLister->items().isEmpty();
Q_EMIT emptinessChanged(isTrashEmpty);
};
- connect(m_trashDirLister, QOverload<>::of(&KCoreDirLister::completed), this, trashDirContentChanged);
+ connect(m_trashDirLister, &KCoreDirLister::completed, this, trashDirContentChanged);
connect(m_trashDirLister, &KDirLister::itemsDeleted, this, trashDirContentChanged);
m_trashDirLister->openUrl(QUrl(QStringLiteral("trash:/")));
}
viewModeActions->addAction(compactAction);
viewModeActions->addAction(detailsAction);
viewModeActions->setToolBarMode(KSelectAction::MenuMode);
- connect(viewModeActions, QOverload<QAction*>::of(&KSelectAction::triggered), this, &DolphinViewActionHandler::slotViewModeActionTriggered);
+ connect(viewModeActions, &KSelectAction::triggered, this, &DolphinViewActionHandler::slotViewModeActionTriggered);
QAction* zoomInAction = KStandardAction::zoomIn(this,
&DolphinViewActionHandler::zoomIn,