summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJan Arve Sæther <jan-arve.saether@qt.io>2021-02-03 11:49:47 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-02-05 14:36:26 +0000
commitfd15b28cf80897a212d4a57190e8c0e75c644eb3 (patch)
treeaf35c4e63925ad8c7efa0ee33748ac0c79d5d7bf /src
parent8652493529a46a375c11bbaf16d2122ee8466c29 (diff)
a11y: Report mixed state if QCheckBox is PartiallyChecked
Previously it only returned checked or unchecked for a tri-state checkbox. Fixes: QTBUG-84616 Change-Id: Ife72098e35f8295fd389bda232de5478ffa7e87f Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit f4887aca1e5ac7b90abf862d7c9828417a74a1b6) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src')
-rw-r--r--src/plugins/platforms/cocoa/qcocoaaccessibility.mm2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibility.mm b/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
index 585518628d..0f5c638f7c 100644
--- a/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
+++ b/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
@@ -389,6 +389,8 @@ id getValueAttribute(QAccessibleInterface *interface)
}
if (interface->state().checkable) {
+ if (interface->state().checkStateMixed)
+ return @(2);
return interface->state().checked ? @(1) : @(0);
}