allow sliders to be tabbed to
This commit is contained in:
@@ -33,6 +33,9 @@ SliderLabel::SliderLabel(QWidget *parent) :
|
||||
QFont f = font();
|
||||
f.setUnderline(true);
|
||||
setFont(f);
|
||||
|
||||
// Allow users to tab to this widget
|
||||
setFocusPolicy(Qt::TabFocus);
|
||||
}
|
||||
|
||||
void SliderLabel::mousePressEvent(QMouseEvent *ev)
|
||||
@@ -70,3 +73,10 @@ void SliderLabel::mouseReleaseEvent(QMouseEvent *ev)
|
||||
|
||||
static_cast<QGuiApplication*>(QApplication::instance())->restoreOverrideCursor();
|
||||
}
|
||||
|
||||
void SliderLabel::focusInEvent(QFocusEvent *event)
|
||||
{
|
||||
QWidget::focusInEvent(event);
|
||||
|
||||
emit focused();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user