Accessibility: Warn if an event cannot create an interface for some reason.
authorFrederik Gladhorn <frederik.gladhorn@digia.com>
Sun, 4 Nov 2012 09:32:27 +0000 (10:32 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 8 Nov 2012 15:59:50 +0000 (16:59 +0100)
Change-Id: I87d0290286243f8ead114e238798c9a7b882d978
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
src/gui/accessible/qaccessible.cpp

index d9fcd6e..e62f426 100644 (file)
@@ -1070,8 +1070,10 @@ QColor QAccessibleInterface::backgroundColor() const
 QAccessibleInterface *QAccessibleEvent::accessibleInterface() const
 {
     QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(m_object);
-    if (!iface)
+    if (!iface) {
+        qWarning() << "Cannot create accessible interface for object: " << m_object;
         return 0;
+    }
 
     if (m_child >= 0) {
         QAccessibleInterface *child = iface->child(m_child);