@@ -35,13 +35,13 @@ GlobalShortcutList GlobalShortcutRegistry::shortcuts() const
36bool GlobalShortcutRegistry::hasShortcut(const QVariant &seq) const
36bool GlobalShortcutRegistry::hasShortcut(const QVariant &seq) const
38− return m_shortcuts.keys().contains(seq);
38+ return m_shortcuts.contains(seq);
41void GlobalShortcutRegistry::addShortcut(const QVariant &seq, GlobalShortcut *sc)
41void GlobalShortcutRegistry::addShortcut(const QVariant &seq, GlobalShortcut *sc)
44− if (!m_shortcuts.keys().contains(seq)) { // create a new entry
44+ if (!m_shortcuts.contains(seq)) { // create a new entry
45 m_shortcuts.insert(seq, {sc});
45 m_shortcuts.insert(seq, {sc});
46 } else { // append to an existing one
46 } else { // append to an existing one
47 auto shortcuts = m_shortcuts[seq];
47 auto shortcuts = m_shortcuts[seq];
@@ -76,7 +76,7 @@ bool GlobalShortcutRegistry::eventFilter(QObject *obj, QEvent *event)
76 if (event->type() == QEvent::KeyPress) {
76 if (event->type() == QEvent::KeyPress) {
77 QKeyEvent *keyEvent = static_cast<QKeyEvent*>(event);
77 QKeyEvent *keyEvent = static_cast<QKeyEvent*>(event);
78 QKeySequence seq = QKeySequence(keyEvent->key() + keyEvent->modifiers());
78 QKeySequence seq = QKeySequence(keyEvent->key() + keyEvent->modifiers());
79− if (m_shortcuts.keys().contains(seq)) {
79+ if (m_shortcuts.contains(seq)) {
80 const auto shortcuts = m_shortcuts.value(seq);
80 const auto shortcuts = m_shortcuts.value(seq);
81 Q_FOREACH(const auto &shortcut, shortcuts) {
81 Q_FOREACH(const auto &shortcut, shortcuts) {
82 if (shortcut) {
82 if (shortcut) {