Fix minor stuff in Windows UI Automation support

Adding missing "override" keywords in overridden interfaces, using
"#if QT_CONFIG(accessibility)" instead of "#ifndef QT_NO_ACCESSIBILITY",
and other minor bits. No change in behavior expected.

Change-Id: Ief0e23cb7b577dd3e4af21750b6beccc80d6a2f8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
Andre de la Rocha 2018-06-26 18:01:55 +02:00
parent aaf60da01c
commit 92666ff521
37 changed files with 220 additions and 230 deletions

View File

@ -52,7 +52,7 @@
#endif
#include "qwindowstheme.h"
#include <private/qguiapplication_p.h>
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
# include "uiautomation/qwindowsuiaaccessibility.h"
#endif
#if QT_CONFIG(sessionmanager)
@ -974,7 +974,7 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message,
case QtWindows::UnknownEvent:
return false;
case QtWindows::AccessibleObjectFromWindowRequest:
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
return QWindowsUiaAccessibility::handleWmGetObject(hwnd, wParam, lParam, result);
#else
return false;

View File

@ -59,7 +59,7 @@
#endif
#include "qwindowsinputcontext.h"
#include "qwindowskeymapper.h"
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
# include "uiautomation/qwindowsuiaaccessibility.h"
#endif
@ -150,7 +150,7 @@ struct QWindowsIntegrationPrivate
QScopedPointer<QWindowsStaticOpenGLContext> m_staticOpenGLContext;
#endif // QT_NO_OPENGL
QScopedPointer<QPlatformInputContext> m_inputContext;
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
QWindowsUiaAccessibility m_accessibility;
#endif
QWindowsServices m_services;
@ -560,7 +560,7 @@ QPlatformInputContext * QWindowsIntegration::inputContext() const
return d->m_inputContext.data();
}
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
QPlatformAccessibility *QWindowsIntegration::accessibility() const
{
return &d->m_accessibility;

View File

@ -90,7 +90,7 @@ public:
# endif
#endif // !QT_NO_CLIPBOARD
QPlatformInputContext *inputContext() const override;
#ifndef QT_NO_ACCESSIBILITY
#if QT_CONFIG(accessibility)
QPlatformAccessibility *accessibility() const override;
#endif
QPlatformFontDatabase *fontDatabase() const override;

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiaaccessibility.h"
#include "qwindowsuiamainprovider.h"
@ -107,19 +107,15 @@ void QWindowsUiaAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event
return;
switch (event->type()) {
case QAccessible::Focus:
QWindowsUiaMainProvider::notifyFocusChange(event);
break;
case QAccessible::StateChanged:
QWindowsUiaMainProvider::notifyStateChange(static_cast<QAccessibleStateChangeEvent *>(event));
break;
case QAccessible::ValueChanged:
QWindowsUiaMainProvider::notifyValueChange(static_cast<QAccessibleValueChangeEvent *>(event));
break;
case QAccessible::TextAttributeChanged:
case QAccessible::TextColumnChanged:
case QAccessible::TextInserted:
@ -129,7 +125,6 @@ void QWindowsUiaAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event
case QAccessible::TextCaretMoved:
QWindowsUiaMainProvider::notifyTextChange(event);
break;
default:
break;
}
@ -137,4 +132,4 @@ void QWindowsUiaAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,15 +40,15 @@
#ifndef QWINDOWSUIAACCESSIBILITY_H
#define QWINDOWSUIAACCESSIBILITY_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowscontext.h"
#include <qpa/qplatformaccessibility.h>
QT_BEGIN_NAMESPACE
// Windows plataform accessibility implemented over UI Automation.
// Windows platform accessibility implemented over UI Automation.
class QWindowsUiaAccessibility : public QPlatformAccessibility
{
public:
@ -60,6 +60,6 @@ public:
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAACCESSIBILITY_H

View File

@ -37,15 +37,14 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -77,4 +76,4 @@ QAccessible::Id QWindowsUiaBaseProvider::id() const
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIABASEPROVIDER_H
#define QWINDOWSUIABASEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include <QtGui/qaccessible.h>
#include <QtCore/qpointer.h>
@ -52,7 +52,6 @@
QT_BEGIN_NAMESPACE
class QAccessibleInterface;
class QDebug;
// Base class for UI Automation providers.
class QWindowsUiaBaseProvider : public QObject
@ -72,6 +71,6 @@ private:
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIABASEPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiagriditemprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -147,7 +147,7 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaGridItemProvider::get_ColumnSpan(int *pRetV
return S_OK;
}
// Returns the provider for the cointaining table/tree.
// Returns the provider for the containing table/tree.
HRESULT STDMETHODCALLTYPE QWindowsUiaGridItemProvider::get_ContainingGrid(IRawElementProviderSimple **pRetVal)
{
qCDebug(lcQpaUiAutomation) << __FUNCTION__;
@ -172,4 +172,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaGridItemProvider::get_ContainingGrid(IRawEl
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAGRIDITEMPROVIDER_H
#define QWINDOWSUIAGRIDITEMPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,15 +57,15 @@ public:
virtual ~QWindowsUiaGridItemProvider();
// IGridItemProvider
HRESULT STDMETHODCALLTYPE get_Row(int *pRetVal);
HRESULT STDMETHODCALLTYPE get_Column(int *pRetVal);
HRESULT STDMETHODCALLTYPE get_RowSpan(int *pRetVal);
HRESULT STDMETHODCALLTYPE get_ColumnSpan(int *pRetVal);
HRESULT STDMETHODCALLTYPE get_ContainingGrid(IRawElementProviderSimple **pRetVal);
HRESULT STDMETHODCALLTYPE get_Row(int *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_Column(int *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_RowSpan(int *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_ColumnSpan(int *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_ContainingGrid(IRawElementProviderSimple **pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAGRIDITEMPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiagridprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -132,4 +132,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaGridProvider::get_ColumnCount(int *pRetVal)
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAGRIDPROVIDER_H
#define QWINDOWSUIAGRIDPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,13 +57,13 @@ public:
virtual ~QWindowsUiaGridProvider();
// IGridProvider
HRESULT STDMETHODCALLTYPE GetItem(int row, int column, IRawElementProviderSimple **pRetVal);
HRESULT STDMETHODCALLTYPE get_RowCount(int *pRetVal);
HRESULT STDMETHODCALLTYPE get_ColumnCount(int *pRetVal);
HRESULT STDMETHODCALLTYPE GetItem(int row, int column, IRawElementProviderSimple **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_RowCount(int *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_ColumnCount(int *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAGRIDPROVIDER_H

View File

@ -37,15 +37,15 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiainvokeprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -80,4 +80,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaInvokeProvider::Invoke()
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAINVOKEPROVIDER_H
#define QWINDOWSUIAINVOKEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,11 +57,11 @@ public:
virtual ~QWindowsUiaInvokeProvider();
// IInvokeProvider
HRESULT STDMETHODCALLTYPE Invoke();
HRESULT STDMETHODCALLTYPE Invoke() override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAINVOKEPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiamainprovider.h"
#include "qwindowsuiavalueprovider.h"
@ -57,7 +57,7 @@
#include "qwindowsuiautils.h"
#include "qwindowsuiaprovidercache.h"
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtGui/qaccessible.h>
#include <QtGui/qguiapplication.h>
#include <QtGui/qwindow.h>
@ -391,9 +391,8 @@ HRESULT QWindowsUiaMainProvider::GetPropertyValue(PROPERTYID idProp, VARIANT *pR
break;
case UIA_NamePropertyId: {
QString name = accessible->text(QAccessible::Name);
if (name.isEmpty() && clientTopLevel) {
if (name.isEmpty() && clientTopLevel)
name = QCoreApplication::applicationName();
}
setVariantString(name, pRetVal);
break;
}
@ -635,4 +634,4 @@ HRESULT QWindowsUiaMainProvider::GetFocus(IRawElementProviderFragment **pRetVal)
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAMAINPROVIDER_H
#define QWINDOWSUIAMAINPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -71,27 +71,27 @@ public:
static void notifyTextChange(QAccessibleEvent *event);
// IUnknown
HRESULT STDMETHODCALLTYPE QueryInterface(REFIID id, LPVOID *iface);
ULONG STDMETHODCALLTYPE AddRef();
ULONG STDMETHODCALLTYPE Release();
HRESULT STDMETHODCALLTYPE QueryInterface(REFIID id, LPVOID *iface) override;
ULONG STDMETHODCALLTYPE AddRef() override;
ULONG STDMETHODCALLTYPE Release() override;
// IRawElementProviderSimple methods
HRESULT STDMETHODCALLTYPE get_ProviderOptions(ProviderOptions *pRetVal);
HRESULT STDMETHODCALLTYPE GetPatternProvider(PATTERNID idPattern, IUnknown **pRetVal);
HRESULT STDMETHODCALLTYPE GetPropertyValue(PROPERTYID idProp, VARIANT *pRetVal);
HRESULT STDMETHODCALLTYPE get_HostRawElementProvider(IRawElementProviderSimple **pRetVal);
HRESULT STDMETHODCALLTYPE get_ProviderOptions(ProviderOptions *pRetVal) override;
HRESULT STDMETHODCALLTYPE GetPatternProvider(PATTERNID idPattern, IUnknown **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetPropertyValue(PROPERTYID idProp, VARIANT *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_HostRawElementProvider(IRawElementProviderSimple **pRetVal) override;
// IRawElementProviderFragment methods
HRESULT STDMETHODCALLTYPE Navigate(NavigateDirection direction, IRawElementProviderFragment **pRetVal);
HRESULT STDMETHODCALLTYPE GetRuntimeId(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE get_BoundingRectangle(UiaRect *pRetVal);
HRESULT STDMETHODCALLTYPE GetEmbeddedFragmentRoots(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE Navigate(NavigateDirection direction, IRawElementProviderFragment **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetRuntimeId(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_BoundingRectangle(UiaRect *pRetVal) override;
HRESULT STDMETHODCALLTYPE GetEmbeddedFragmentRoots(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE SetFocus();
HRESULT STDMETHODCALLTYPE get_FragmentRoot(IRawElementProviderFragmentRoot **pRetVal);
HRESULT STDMETHODCALLTYPE get_FragmentRoot(IRawElementProviderFragmentRoot **pRetVal) override;
// IRawElementProviderFragmentRoot methods
HRESULT STDMETHODCALLTYPE ElementProviderFromPoint(double x, double y, IRawElementProviderFragment **pRetVal);
HRESULT STDMETHODCALLTYPE GetFocus(IRawElementProviderFragment **pRetVal);
HRESULT STDMETHODCALLTYPE ElementProviderFromPoint(double x, double y, IRawElementProviderFragment **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetFocus(IRawElementProviderFragment **pRetVal) override;
private:
QString automationIdForAccessible(const QAccessibleInterface *accessible);
@ -100,6 +100,6 @@ private:
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAMAINPROVIDER_H

View File

@ -37,15 +37,13 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiaprovidercache.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtCore/qdebug.h>
QT_BEGIN_NAMESPACE
using namespace QWindowsUiAutomation;
@ -66,7 +64,7 @@ QWindowsUiaProviderCache *QWindowsUiaProviderCache::instance()
// Returns the provider instance associated with the ID, or nullptr.
QWindowsUiaBaseProvider *QWindowsUiaProviderCache::providerForId(QAccessible::Id id) const
{
return providerTable.value(id);
return m_providerTable.value(id);
}
// Inserts a provider in the cache and associates it with an accessibility ID.
@ -74,8 +72,8 @@ void QWindowsUiaProviderCache::insert(QAccessible::Id id, QWindowsUiaBaseProvide
{
remove(id);
if (provider) {
providerTable[id] = provider;
inverseTable[provider] = id;
m_providerTable[id] = provider;
m_inverseTable[provider] = id;
// Connects the destroyed signal to our slot, to remove deleted objects from the cache.
QObject::connect(provider, &QObject::destroyed, this, &QWindowsUiaProviderCache::objectDestroyed);
}
@ -87,20 +85,20 @@ void QWindowsUiaProviderCache::objectDestroyed(QObject *obj)
// We have to use the inverse table to map the object address back to its ID,
// since at this point (called from QObject destructor), it has already been
// partially destroyed and we cannot treat it as a provider.
auto it = inverseTable.find(obj);
if (it != inverseTable.end()) {
providerTable.remove(*it);
inverseTable.remove(obj);
auto it = m_inverseTable.find(obj);
if (it != m_inverseTable.end()) {
m_providerTable.remove(*it);
m_inverseTable.remove(obj);
}
}
// Removes a provider with a given id from the cache.
void QWindowsUiaProviderCache::remove(QAccessible::Id id)
{
inverseTable.remove(providerTable.value(id));
providerTable.remove(id);
m_inverseTable.remove(m_providerTable.value(id));
m_providerTable.remove(id);
}
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAPROVIDERCACHE_H
#define QWINDOWSUIAPROVIDERCACHE_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -65,12 +65,12 @@ private Q_SLOTS:
void objectDestroyed(QObject *obj);
private:
QHash<QAccessible::Id, QWindowsUiaBaseProvider *> providerTable;
QHash<QObject *, QAccessible::Id> inverseTable;
QHash<QAccessible::Id, QWindowsUiaBaseProvider *> m_providerTable;
QHash<QObject *, QAccessible::Id> m_inverseTable;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAPROVIDERCACHE_H

View File

@ -37,15 +37,15 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiarangevalueprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -186,4 +186,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaRangeValueProvider::get_SmallChange(double
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIARANGEVALUEPROVIDER_H
#define QWINDOWSUIARANGEVALUEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,17 +57,17 @@ public:
virtual ~QWindowsUiaRangeValueProvider();
// IRangeValueProvider
HRESULT STDMETHODCALLTYPE SetValue(double val);
HRESULT STDMETHODCALLTYPE get_Value(double *pRetVal);
HRESULT STDMETHODCALLTYPE get_IsReadOnly(BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE get_Maximum(double *pRetVal);
HRESULT STDMETHODCALLTYPE get_Minimum(double *pRetVal);
HRESULT STDMETHODCALLTYPE get_LargeChange(double *pRetVal);
HRESULT STDMETHODCALLTYPE get_SmallChange(double *pRetVal);
HRESULT STDMETHODCALLTYPE SetValue(double val) override;
HRESULT STDMETHODCALLTYPE get_Value(double *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_IsReadOnly(BOOL *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_Maximum(double *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_Minimum(double *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_LargeChange(double *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_SmallChange(double *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIARANGEVALUEPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiaselectionitemprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -197,4 +197,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaSelectionItemProvider::get_SelectionContain
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIASELECTIONITEMPROVIDER_H
#define QWINDOWSUIASELECTIONITEMPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,15 +57,15 @@ public:
virtual ~QWindowsUiaSelectionItemProvider();
// ISelectionItemProvider
HRESULT STDMETHODCALLTYPE Select();
HRESULT STDMETHODCALLTYPE AddToSelection();
HRESULT STDMETHODCALLTYPE RemoveFromSelection();
HRESULT STDMETHODCALLTYPE get_IsSelected(BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE get_SelectionContainer(IRawElementProviderSimple **pRetVal);
HRESULT STDMETHODCALLTYPE Select() override;
HRESULT STDMETHODCALLTYPE AddToSelection() override;
HRESULT STDMETHODCALLTYPE RemoveFromSelection() override;
HRESULT STDMETHODCALLTYPE get_IsSelected(BOOL *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_SelectionContainer(IRawElementProviderSimple **pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIASELECTIONITEMPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiaselectionprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
#include <QtCore/qlist.h>
@ -143,4 +143,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaSelectionProvider::get_IsSelectionRequired(
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIASELECTIONPROVIDER_H
#define QWINDOWSUIASELECTIONPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,13 +57,13 @@ public:
virtual ~QWindowsUiaSelectionProvider();
// ISelectionProvider
HRESULT STDMETHODCALLTYPE GetSelection(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE get_CanSelectMultiple(BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE get_IsSelectionRequired(BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE GetSelection(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_CanSelectMultiple(BOOL *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_IsSelectionRequired(BOOL *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIASELECTIONPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiatableitemprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -125,4 +125,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaTableItemProvider::GetColumnHeaderItems(SAF
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIATABLEITEMPROVIDER_H
#define QWINDOWSUIATABLEITEMPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,12 +57,12 @@ public:
virtual ~QWindowsUiaTableItemProvider();
// ITableItemProvider
HRESULT STDMETHODCALLTYPE GetRowHeaderItems(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetColumnHeaderItems(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetRowHeaderItems(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetColumnHeaderItems(SAFEARRAY **pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIATABLEITEMPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiatableprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -150,4 +150,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaTableProvider::get_RowOrColumnMajor(enum Ro
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIATABLEPROVIDER_H
#define QWINDOWSUIATABLEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,13 +57,13 @@ public:
virtual ~QWindowsUiaTableProvider();
// ITableProvider
HRESULT STDMETHODCALLTYPE GetRowHeaders(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetColumnHeaders(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE get_RowOrColumnMajor(enum RowOrColumnMajor *pRetVal);
HRESULT STDMETHODCALLTYPE GetRowHeaders(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetColumnHeaders(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_RowOrColumnMajor(enum RowOrColumnMajor *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIATABLEPROVIDER_H

View File

@ -37,15 +37,15 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiatextprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -257,4 +257,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaTextProvider::GetCaretRange(BOOL *isActive,
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIATEXTPROVIDER_H
#define QWINDOWSUIATEXTPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
#include "qwindowsuiatextrangeprovider.h"
@ -58,23 +58,23 @@ public:
~QWindowsUiaTextProvider();
// IUnknown overrides
HRESULT STDMETHODCALLTYPE QueryInterface(REFIID id, LPVOID *iface);
HRESULT STDMETHODCALLTYPE QueryInterface(REFIID id, LPVOID *iface) override;
// ITextProvider
HRESULT STDMETHODCALLTYPE GetSelection(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetVisibleRanges(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE RangeFromChild(IRawElementProviderSimple *childElement, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE RangeFromPoint(UiaPoint point, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE get_DocumentRange(ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE get_SupportedTextSelection(SupportedTextSelection *pRetVal);
HRESULT STDMETHODCALLTYPE GetSelection(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetVisibleRanges(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE RangeFromChild(IRawElementProviderSimple *childElement, ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE RangeFromPoint(UiaPoint point, ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_DocumentRange(ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE get_SupportedTextSelection(SupportedTextSelection *pRetVal) override;
// ITextProvider2
HRESULT STDMETHODCALLTYPE RangeFromAnnotation(IRawElementProviderSimple *annotationElement, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE GetCaretRange(BOOL *isActive, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE RangeFromAnnotation(IRawElementProviderSimple *annotationElement, ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetCaretRange(BOOL *isActive, ITextRangeProvider **pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIATEXTPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiatextrangeprovider.h"
#include "qwindowsuiamainprovider.h"
@ -46,7 +46,7 @@
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -237,12 +237,12 @@ HRESULT QWindowsUiaTextRangeProvider::GetBoundingRectangles(SAFEARRAY **pRetVal)
int endRange = qMin(end, m_endOffset);
if (startRange < endRange) {
// Calculates a bounding rectangle for the line and adds it to the list.
QRect startRect = textInterface->characterRect(startRange);
QRect endRect = textInterface->characterRect(endRange - 1);
QRect lineRect(qMin(startRect.x(), endRect.x()),
qMin(startRect.y(), endRect.y()),
qMax(startRect.x() + startRect.width(), endRect.x() + endRect.width()) - qMin(startRect.x(), endRect.x()),
qMax(startRect.y() + startRect.height(), endRect.y() + endRect.height()) - qMin(startRect.y(), endRect.y()));
const QRect startRect = textInterface->characterRect(startRange);
const QRect endRect = textInterface->characterRect(endRange - 1);
const QRect lineRect(qMin(startRect.x(), endRect.x()),
qMin(startRect.y(), endRect.y()),
qMax(startRect.x() + startRect.width(), endRect.x() + endRect.width()) - qMin(startRect.x(), endRect.x()),
qMax(startRect.y() + startRect.height(), endRect.y() + endRect.height()) - qMin(startRect.y(), endRect.y()));
rectList.append(lineRect);
}
if (end >= len) break;
@ -518,9 +518,9 @@ HRESULT QWindowsUiaTextRangeProvider::Select()
}
// Not supported.
HRESULT QWindowsUiaTextRangeProvider::FindTextW(BSTR /* text */, BOOL /* backward */,
BOOL /* ignoreCase */,
ITextRangeProvider **pRetVal)
HRESULT QWindowsUiaTextRangeProvider::FindText(BSTR /* text */, BOOL /* backward */,
BOOL /* ignoreCase */,
ITextRangeProvider **pRetVal)
{
if (!pRetVal)
return E_INVALIDARG;
@ -550,4 +550,4 @@ HRESULT QWindowsUiaTextRangeProvider::unselect()
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIATEXTRANGEPROVIDER_H
#define QWINDOWSUIATEXTRANGEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -56,24 +56,25 @@ public:
explicit QWindowsUiaTextRangeProvider(QAccessible::Id id, int startOffset, int endOffset);
virtual ~QWindowsUiaTextRangeProvider();
HRESULT STDMETHODCALLTYPE AddToSelection();
HRESULT STDMETHODCALLTYPE Clone(ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE Compare(ITextRangeProvider *range, BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE CompareEndpoints(TextPatternRangeEndpoint endpoint, ITextRangeProvider *targetRange, TextPatternRangeEndpoint targetEndpoint, int *pRetVal);
HRESULT STDMETHODCALLTYPE ExpandToEnclosingUnit(TextUnit unit);
HRESULT STDMETHODCALLTYPE FindAttribute(TEXTATTRIBUTEID attributeId, VARIANT val, BOOL backward, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE FindText(BSTR text, BOOL backward, BOOL ignoreCase, ITextRangeProvider **pRetVal);
HRESULT STDMETHODCALLTYPE GetAttributeValue(TEXTATTRIBUTEID attributeId, VARIANT *pRetVal);
HRESULT STDMETHODCALLTYPE GetBoundingRectangles(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetChildren(SAFEARRAY **pRetVal);
HRESULT STDMETHODCALLTYPE GetEnclosingElement(IRawElementProviderSimple **pRetVal);
HRESULT STDMETHODCALLTYPE GetText(int maxLength, BSTR *pRetVal);
HRESULT STDMETHODCALLTYPE Move(TextUnit unit, int count, int *pRetVal);
HRESULT STDMETHODCALLTYPE MoveEndpointByRange(TextPatternRangeEndpoint endpoint, ITextRangeProvider *targetRange, TextPatternRangeEndpoint targetEndpoint);
HRESULT STDMETHODCALLTYPE MoveEndpointByUnit(TextPatternRangeEndpoint endpoint, TextUnit unit, int count, int *pRetVal);
HRESULT STDMETHODCALLTYPE RemoveFromSelection();
HRESULT STDMETHODCALLTYPE ScrollIntoView(BOOL alignToTop);
HRESULT STDMETHODCALLTYPE Select();
// ITextRangeProvider
HRESULT STDMETHODCALLTYPE AddToSelection() override;
HRESULT STDMETHODCALLTYPE Clone(ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE Compare(ITextRangeProvider *range, BOOL *pRetVal) override;
HRESULT STDMETHODCALLTYPE CompareEndpoints(TextPatternRangeEndpoint endpoint, ITextRangeProvider *targetRange, TextPatternRangeEndpoint targetEndpoint, int *pRetVal) override;
HRESULT STDMETHODCALLTYPE ExpandToEnclosingUnit(TextUnit unit) override;
HRESULT STDMETHODCALLTYPE FindAttribute(TEXTATTRIBUTEID attributeId, VARIANT val, BOOL backward, ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE FindText(BSTR text, BOOL backward, BOOL ignoreCase, ITextRangeProvider **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetAttributeValue(TEXTATTRIBUTEID attributeId, VARIANT *pRetVal) override;
HRESULT STDMETHODCALLTYPE GetBoundingRectangles(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetChildren(SAFEARRAY **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetEnclosingElement(IRawElementProviderSimple **pRetVal) override;
HRESULT STDMETHODCALLTYPE GetText(int maxLength, BSTR *pRetVal) override;
HRESULT STDMETHODCALLTYPE Move(TextUnit unit, int count, int *pRetVal) override;
HRESULT STDMETHODCALLTYPE MoveEndpointByRange(TextPatternRangeEndpoint endpoint, ITextRangeProvider *targetRange, TextPatternRangeEndpoint targetEndpoint) override;
HRESULT STDMETHODCALLTYPE MoveEndpointByUnit(TextPatternRangeEndpoint endpoint, TextUnit unit, int count, int *pRetVal) override;
HRESULT STDMETHODCALLTYPE RemoveFromSelection() override;
HRESULT STDMETHODCALLTYPE ScrollIntoView(BOOL alignToTop) override;
HRESULT STDMETHODCALLTYPE Select() override;
private:
HRESULT unselect();
@ -83,6 +84,6 @@ private:
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIATEXTRANGEPROVIDER_H

View File

@ -37,15 +37,15 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiatoggleprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -101,4 +101,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaToggleProvider::get_ToggleState(ToggleState
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIATOGGLEPROVIDER_H
#define QWINDOWSUIATOGGLEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -57,12 +57,12 @@ public:
virtual ~QWindowsUiaToggleProvider();
// IToggleProvider
HRESULT STDMETHODCALLTYPE Toggle();
HRESULT STDMETHODCALLTYPE get_ToggleState(ToggleState *pRetVal);
HRESULT STDMETHODCALLTYPE Toggle() override;
HRESULT STDMETHODCALLTYPE get_ToggleState(ToggleState *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIATOGGLEPROVIDER_H

View File

@ -37,8 +37,8 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
@ -218,4 +218,4 @@ bool isTextUnitSeparator(TextUnit unit, const QChar &ch)
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,14 +40,13 @@
#ifndef QWINDOWSUIAUTILS_H
#define QWINDOWSUIAUTILS_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include <QtCore/qstring.h>
#include <QtCore/qt_windows.h>
#include <QtGui/qaccessible.h>
#include <QtGui/qwindow.h>
#include <QtCore/qdebug.h>
#include <QtCore/qrect.h>
#include <QtWindowsUIAutomationSupport/private/qwindowsuiawrapper_p.h>
@ -83,6 +82,6 @@ void setVariantString(const QString &value, VARIANT *variant);
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAUTILS_H

View File

@ -37,15 +37,15 @@
**
****************************************************************************/
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiavalueprovider.h"
#include "qwindowsuiautils.h"
#include "qwindowscontext.h"
#include <QtGui/qaccessible.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
@ -128,4 +128,4 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaValueProvider::get_Value(BSTR *pRetVal)
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)

View File

@ -40,8 +40,8 @@
#ifndef QWINDOWSUIAVALUEPROVIDER_H
#define QWINDOWSUIAVALUEPROVIDER_H
#include <QtCore/qconfig.h>
#ifndef QT_NO_ACCESSIBILITY
#include <QtGui/qtguiglobal.h>
#if QT_CONFIG(accessibility)
#include "qwindowsuiabaseprovider.h"
@ -58,13 +58,13 @@ public:
virtual ~QWindowsUiaValueProvider();
// IValueProvider
HRESULT STDMETHODCALLTYPE SetValue(LPCWSTR val);
HRESULT STDMETHODCALLTYPE get_IsReadOnly(BOOL *pRetVal);
HRESULT STDMETHODCALLTYPE get_Value(BSTR *pRetVal);
HRESULT STDMETHODCALLTYPE SetValue(LPCWSTR val) override;
HRESULT STDMETHODCALLTYPE get_IsReadOnly(BOOL *pRetVal) override;
HRESULT STDMETHODCALLTYPE get_Value(BSTR *pRetVal) override;
};
QT_END_NAMESPACE
#endif // QT_NO_ACCESSIBILITY
#endif // QT_CONFIG(accessibility)
#endif // QWINDOWSUIAVALUEPROVIDER_H