Skip to content

Commit b1852e0

Browse files
Merge dashpay#5995: fix(qt): tab switching via shortcuts doesn't work after 5986
c874205 fix(qt): tab switching via shortcuts doesn't work after 5986 (UdjinM6) Pull request description: ## Issue being fixed or feature implemented Looks like 3265b54 (dashpay#5986) broke it ## What was done? ## How Has This Been Tested? run dash-qt, try using shortcuts `cmd+1`, `cmd+2` etc. (on macos) ## Breaking Changes n/a ## Checklist: - [x] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have added or updated relevant unit/integration/functional/e2e tests - [ ] I have made corresponding changes to the documentation - [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_ ACKs for top commit: PastaPastaPasta: ACK c874205 kwvg: ACK c874205 Tree-SHA512: 62a593ec804d75ff8aada0ef9ea90106adbf8cd11b202a6296086f55c2a4d2181e56dc8e56193a0ed49d94e55ee3236ab441ab477c8ca6d7b0c649dff987dbbc
2 parents f9e123e + c874205 commit b1852e0

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)