Windows QPA: Enable Toggle UIA pattern for all checkable controls
This change allows the checked/unchecked state to be detected by screen readers for all controls with a checkable state. Task-number: QTBUG-81919 Change-Id: I604151397b4ae21297009c274ffe634723ebe783 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
parent
c91b7f15ce
commit
319ac188eb
@ -305,11 +305,9 @@ HRESULT QWindowsUiaMainProvider::GetPatternProvider(PATTERNID idPattern, IUnknow
|
||||
}
|
||||
break;
|
||||
case UIA_TogglePatternId:
|
||||
// Checkbox controls.
|
||||
if (accessible->role() == QAccessible::CheckBox
|
||||
|| (accessible->role() == QAccessible::MenuItem && accessible->state().checkable)) {
|
||||
// Checkboxes and other checkable controls.
|
||||
if (accessible->state().checkable)
|
||||
*pRetVal = new QWindowsUiaToggleProvider(id());
|
||||
}
|
||||
break;
|
||||
case UIA_SelectionPatternId:
|
||||
// Lists of items.
|
||||
|
Loading…
Reference in New Issue
Block a user