summaryrefslogtreecommitdiffstats
path: root/src/gui/accessible
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/accessible')
-rw-r--r--src/gui/accessible/qaccessible.cpp32
-rw-r--r--src/gui/accessible/qaccessible.h2
-rw-r--r--src/gui/accessible/qaccessible2.cpp16
3 files changed, 30 insertions, 20 deletions
diff --git a/src/gui/accessible/qaccessible.cpp b/src/gui/accessible/qaccessible.cpp
index 37e7a1dbb4..aa47616161 100644
--- a/src/gui/accessible/qaccessible.cpp
+++ b/src/gui/accessible/qaccessible.cpp
@@ -77,10 +77,10 @@ QT_BEGIN_NAMESPACE
braille displays. Clients and servers communicate in the following way:
\list
- \o \e{AT Servers} notify the clients about events through calls to the
+ \li \e{AT Servers} notify the clients about events through calls to the
updateAccessibility() function.
- \o \e{AT Clients} request information about the objects in the server.
+ \li \e{AT Clients} request information about the objects in the server.
The QAccessibleInterface class is the core interface, and encapsulates
this information in a pure virtual API. Implementations of the interface
are provided by Qt through the queryAccessibleInterface() API.
@@ -650,8 +650,6 @@ void QAccessible::updateAccessibility(QObject *object, int child, Event reason)
{
Q_ASSERT(object);
- qWarning("QAccessible::updateAccessibility is deprecated.");
-
QAccessibleEvent event = QAccessibleEvent(reason, object, child);
updateAccessibility(event);
}
@@ -750,12 +748,12 @@ QAccessibleInterface *QAccessibleEvent::accessibleInterface() const
The AT client uses three basic concepts to acquire information
about any accessible object in an application:
\list
- \i \e Properties The client can read information about
+ \li \e Properties The client can read information about
accessible objects. In some cases the client can also modify these
properties; such as text in a line edit.
- \i \e Actions The client can invoke actions like pressing a button
+ \li \e Actions The client can invoke actions like pressing a button
or .
- \i \e{Relationships and Navigation} The client can traverse from one
+ \li \e{Relationships and Navigation} The client can traverse from one
accessible object to another, using the relationships between objects.
\endlist
@@ -1198,11 +1196,23 @@ Q_GUI_EXPORT QDebug operator<<(QDebug d, const QAccessibleInterface *iface)
if (iface->object()) {
d << "obj=" << iface->object();
}
- if (iface->state().invisible) {
- d << "invisible";
- } else {
+ QStringList stateStrings;
+ QAccessible::State st = iface->state();
+ if (st.focusable)
+ stateStrings << QLatin1String("focusable");
+ if (st.focused)
+ stateStrings << QLatin1String("focused");
+ if (st.selected)
+ stateStrings << QLatin1String("selected");
+ if (st.invisible)
+ stateStrings << QLatin1String("invisible");
+
+ if (!stateStrings.isEmpty())
+ d << stateStrings.join(QLatin1String("|"));
+
+ if (!st.invisible)
d << "rect=" << iface->rect();
- }
+
} else {
d << " invalid";
}
diff --git a/src/gui/accessible/qaccessible.h b/src/gui/accessible/qaccessible.h
index a72b91a90f..6ad1bb9da9 100644
--- a/src/gui/accessible/qaccessible.h
+++ b/src/gui/accessible/qaccessible.h
@@ -336,7 +336,7 @@ public:
static QAccessibleInterface *queryAccessibleInterface(QObject *);
- static void updateAccessibility(QObject *object, int child, Event reason);
+ QT_DEPRECATED static void updateAccessibility(QObject *object, int child, Event reason);
static void updateAccessibility(const QAccessibleEvent &event);
static bool isActive();
diff --git a/src/gui/accessible/qaccessible2.cpp b/src/gui/accessible/qaccessible2.cpp
index db3028b371..d3dafb8820 100644
--- a/src/gui/accessible/qaccessible2.cpp
+++ b/src/gui/accessible/qaccessible2.cpp
@@ -371,14 +371,14 @@ QT_BEGIN_NAMESPACE
In general you should use one of the predefined action names, unless describing an action that does not fit these:
\table
- \header \o Action name \o Description
- \row \o \l checkAction() \o checks the item (checkbox, radio button, ...)
- \row \o \l decreaseAction() \o decrease the value of the accessible (e.g. spinbox)
- \row \o \l increaseAction() \o increase the value of the accessible (e.g. spinbox)
- \row \o \l pressAction() \o press or click or activate the accessible (should correspont to clicking the object with the mouse)
- \row \o \l setFocusAction() \o set the focus to this accessible
- \row \o \l showMenuAction() \o show a context menu, corresponds to right-clicks
- \row \o \l uncheckAction() \o uncheck the item (checkbox, radio button, ...)
+ \header \li Action name \li Description
+ \row \li \l checkAction() \li checks the item (checkbox, radio button, ...)
+ \row \li \l decreaseAction() \li decrease the value of the accessible (e.g. spinbox)
+ \row \li \l increaseAction() \li increase the value of the accessible (e.g. spinbox)
+ \row \li \l pressAction() \li press or click or activate the accessible (should correspont to clicking the object with the mouse)
+ \row \li \l setFocusAction() \li set the focus to this accessible
+ \row \li \l showMenuAction() \li show a context menu, corresponds to right-clicks
+ \row \li \l uncheckAction() \li uncheck the item (checkbox, radio button, ...)
\endtable
In order to invoke the action, \l doAction() is called with an action name.