Remove warning about being unable to instantiate accessibility interface

This warning was a good idea when the plugins were needed to give a hint
where to start debugging. Now the a11y plugins were merged into
qtwidgets/qtquick, so there is no more need for this warning which may
pop up on custom widgets e.g. inheriting QWindow.

Task-number: QTBUG-50215
Change-Id: Ic5efbb3dfbd07a7139884126a2604b54c99005e4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
This commit is contained in:
Frederik Gladhorn 2016-01-05 12:43:32 +01:00
parent 0c019d7bd2
commit ba8d343002

View File

@ -1758,15 +1758,8 @@ QAccessibleInterface *QAccessibleEvent::accessibleInterface() const
return QAccessible::accessibleInterface(m_uniqueId); return QAccessible::accessibleInterface(m_uniqueId);
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(m_object); QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(m_object);
if (!iface || !iface->isValid()) { if (!iface || !iface->isValid())
static bool hasWarned = false;
if (!iface && !hasWarned) {
qWarning() << "Problem creating accessible interface for: " << m_object << endl
<< "Make sure to deploy Qt with accessibility plugins.";
hasWarned = true;
}
return 0; return 0;
}
if (m_child >= 0) { if (m_child >= 0) {
QAccessibleInterface *child = iface->child(m_child); QAccessibleInterface *child = iface->child(m_child);