summaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickaccessibleattached_p.h
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2019-05-28 17:59:34 +0200
committerLaszlo Agocs <laszlo.agocs@qt.io>2019-05-28 17:59:40 +0200
commit0f5c34f2c6b64bae3429706a6c4211334c689092 (patch)
treeb85888d73518f6abc7bbde74ab71a27887682f9d /src/quick/items/qquickaccessibleattached_p.h
parent44ca7e31ee9365a72cd17ecd335ec4d0161420a9 (diff)
parent9d61684d70c8691d81536b7b519388586e2cbbb8 (diff)
Merge remote-tracking branch 'origin/dev' into wip/scenegraphng
Diffstat (limited to 'src/quick/items/qquickaccessibleattached_p.h')
-rw-r--r--src/quick/items/qquickaccessibleattached_p.h32
1 files changed, 3 insertions, 29 deletions
diff --git a/src/quick/items/qquickaccessibleattached_p.h b/src/quick/items/qquickaccessibleattached_p.h
index 215a1e5db6..f4194ef13d 100644
--- a/src/quick/items/qquickaccessibleattached_p.h
+++ b/src/quick/items/qquickaccessibleattached_p.h
@@ -69,6 +69,7 @@ QT_BEGIN_NAMESPACE
bool P() const { return m_state.P ; } \
void set_ ## P(bool arg) \
{ \
+ m_stateExplicitlySet.P = true; \
if (m_state.P == arg) \
return; \
m_state.P = arg; \
@@ -111,35 +112,7 @@ public:
~QQuickAccessibleAttached();
QAccessible::Role role() const { return m_role; }
- void setRole(QAccessible::Role role)
- {
- if (role != m_role) {
- m_role = role;
- Q_EMIT roleChanged();
- // There is no way to signify role changes at the moment.
- // QAccessible::updateAccessibility(parent(), 0, QAccessible::);
-
- switch (role) {
- case QAccessible::CheckBox:
- case QAccessible::RadioButton:
- m_state.focusable = true;
- m_state.checkable = true;
- break;
- case QAccessible::Button:
- case QAccessible::MenuItem:
- case QAccessible::PageTab:
- case QAccessible::EditableText:
- case QAccessible::SpinBox:
- case QAccessible::ComboBox:
- case QAccessible::Terminal:
- case QAccessible::ScrollBar:
- m_state.focusable = true;
- break;
- default:
- break;
- }
- }
- }
+ void setRole(QAccessible::Role role);
QString name() const {
if (m_state.passwordEdit)
return QString();
@@ -241,6 +214,7 @@ private:
QAccessible::Role m_role;
QAccessible::State m_state;
+ QAccessible::State m_stateExplicitlySet;
QString m_name;
QString m_description;