Accessibility: Set checkable state for checkbox and buttons

Change-Id: I8048c223917a8494a6a4d9016870d3a0762758bf
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
This commit is contained in:
Frederik Gladhorn 2014-03-27 22:33:58 +01:00 committed by The Qt Project
parent c8113ad0a4
commit 214a3b093d

View File

@ -137,6 +137,8 @@ QAccessible::State QAccessibleButton::state() const
QAbstractButton *b = button();
QCheckBox *cb = qobject_cast<QCheckBox *>(b);
if (b->isCheckable())
state.checkable = true;
if (b->isChecked())
state.checked = true;
else if (cb && cb->checkState() == Qt::PartiallyChecked)