Skip to content

Commit c874205

Browse files
committed
fix(qt): tab switching via shortcuts doesn't work after 5986
1 parent 2610df3 commit c874205

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/qt/guiutil.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1612,14 +1612,14 @@ void updateButtonGroupShortcuts(QButtonGroup* buttonGroup)
16121612
return;
16131613
}
16141614
#ifdef Q_OS_MAC
1615-
auto modifier = Qt::CTRL;
1615+
auto modifier = "Ctrl";
16161616
#else
1617-
auto modifier = Qt::ALT;
1617+
auto modifier = "Alt";
16181618
#endif
1619-
int nKey = 0;
1619+
int nKey = 1;
16201620
for (auto button : buttonGroup->buttons()) {
16211621
if (button->isVisible()) {
1622-
button->setShortcut(QKeySequence(static_cast<int>(modifier) | static_cast<int>(Qt::Key_1) | nKey++));
1622+
button->setShortcut(QKeySequence(QString("%1+%2").arg(modifier).arg(nKey++)));
16231623
} else {
16241624
button->setShortcut(QKeySequence());
16251625
}

0 commit comments

Comments
 (0)