Allow buttons to be focusable

This improves accessibility.
PR #16648.
This commit is contained in:
Tyler Dunn 2022-03-16 21:51:47 -07:00 committed by GitHub
commit cf061b7d30
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -102,9 +102,6 @@ PropTabBar::PropTabBar(QWidget *parent)
// SIGNAL/SLOT // SIGNAL/SLOT
connect(m_btnGroup, &QButtonGroup::idClicked connect(m_btnGroup, &QButtonGroup::idClicked
, this, &PropTabBar::setCurrentIndex); , this, &PropTabBar::setCurrentIndex);
// Disable buttons focus
for (QAbstractButton *btn : asConst(m_btnGroup->buttons()))
btn->setFocusPolicy(Qt::NoFocus);
} }
int PropTabBar::currentIndex() const int PropTabBar::currentIndex() const