Commit 25d1c368 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

operator+/- is disabled for QFlags in qt6

parent 8d34c970
......@@ -239,7 +239,7 @@ DirFilterPlugin::DirFilterPlugin(QObject *parent, const QVariantList &)
QAction *action = actionCollection()->addAction(QStringLiteral("filterdir"), this, SLOT(slotShowFilterBar()));
action->setText(i18nc("@action:inmenu Tools", "Show Filter Bar"));
action->setIcon(QIcon::fromTheme(QStringLiteral("view-filter")));
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_I));
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL | Qt::SHIFT | Qt::Key_I));
}
}
......
......@@ -56,7 +56,7 @@ KImGalleryPlugin::KImGalleryPlugin(QObject *parent, const QVariantList &)
QAction *a = actionCollection()->addAction(QStringLiteral("create_img_gallery"));
a->setText(i18n("&Create Image Gallery..."));
a->setIcon(QIcon::fromTheme(QStringLiteral("imagegallery")));
actionCollection()->setDefaultShortcut(a, QKeySequence(Qt::CTRL + Qt::Key_I));
actionCollection()->setDefaultShortcut(a, QKeySequence(Qt::CTRL | Qt::Key_I));
connect(a, &QAction::triggered, this, &KImGalleryPlugin::slotExecute);
}
......
......@@ -88,7 +88,7 @@ SearchBarPlugin::SearchBarPlugin(QObject *parent,
QAction *a = actionCollection()->addAction(QStringLiteral("focus_search_bar"));
a->setText(i18n("Focus Searchbar"));
actionCollection()->setDefaultShortcut(a, QKeySequence(Qt::CTRL + Qt::ALT + Qt::Key_S));
actionCollection()->setDefaultShortcut(a, QKeySequence(Qt::CTRL | Qt::ALT | Qt::Key_S));
connect(a, &QAction::triggered, this, &SearchBarPlugin::focusSearchbar);
m_searchProvidersDir = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation) + "/kde5/services/searchproviders/";
QDir().mkpath(m_searchProvidersDir);
......
......@@ -43,7 +43,7 @@ KShellCmdPlugin::KShellCmdPlugin(QObject *parent, const QVariantList &)
action->setIcon(QIcon::fromTheme(QStringLiteral("system-run")));
action->setText(i18n("&Execute Shell Command..."));
connect(action, &QAction::triggered, this, &KShellCmdPlugin::slotExecuteShellCommand);
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::Key_E));
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL | Qt::Key_E));
}
void KShellCmdPlugin::slotExecuteShellCommand()
......
......@@ -3182,7 +3182,7 @@ bool KonqMainWindow::eventFilter(QObject *obj, QEvent *ev)
// TODO: decide if the delete-character behaviour of QLineEdit
// really is useful enough to warrant this workaround
QAction *duplicate = actionCollection()->action(QStringLiteral("duplicatecurrenttab"));
if (duplicate->shortcuts().contains(QKeySequence(Qt::CTRL + Qt::Key_D))) {
if (duplicate->shortcuts().contains(QKeySequence(Qt::CTRL | Qt::Key_D))) {
duplicate->setEnabled(false);
}
......@@ -3205,7 +3205,7 @@ bool KonqMainWindow::eventFilter(QObject *obj, QEvent *ev)
// see above in FocusIn for explanation
// action is reenabled if a view exists
QAction *duplicate = actionCollection()->action(QStringLiteral("duplicatecurrenttab"));
if (duplicate->shortcuts().contains(QKeySequence(Qt::CTRL + Qt::Key_D))) {
if (duplicate->shortcuts().contains(QKeySequence(Qt::CTRL | Qt::Key_D))) {
duplicate->setEnabled(currentView() && currentView()->frame());
}
......@@ -3688,7 +3688,7 @@ void KonqMainWindow::initActions()
connect(m_ptaFullScreen, &KToggleFullScreenAction::toggled, this, &KonqMainWindow::slotUpdateFullScreen);
QList<QKeySequence> reloadShortcut = KStandardShortcut::shortcut(KStandardShortcut::Reload);
QKeySequence reloadAlternate(Qt::CTRL + Qt::Key_R);
QKeySequence reloadAlternate(Qt::CTRL | Qt::Key_R);
if (!reloadShortcut.contains(reloadAlternate)) {
reloadShortcut.append(reloadAlternate);
}
......
......@@ -302,7 +302,7 @@ void WebEnginePart::initActions()
action = new QAction(i18n("View Do&cument Source"), this);
actionCollection()->addAction(QStringLiteral("viewDocumentSource"), action);
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::Key_U));
actionCollection()->setDefaultShortcut(action, QKeySequence(Qt::CTRL | Qt::Key_U));
connect(action, &QAction::triggered, m_browserExtension, &WebEngineBrowserExtension::slotViewDocumentSource);
action = new QAction(i18nc("Secure Sockets Layer", "SSL"), this);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment