summaryrefslogtreecommitdiffstats
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/controls/native/native_view_host_win.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/views/controls/native/native_view_host_win.cc b/views/controls/native/native_view_host_win.cc
index 52f9373..6e77f2a 100644
--- a/views/controls/native/native_view_host_win.cc
+++ b/views/controls/native/native_view_host_win.cc
@@ -130,10 +130,11 @@ gfx::NativeViewAccessible NativeViewHostWin::GetNativeViewAccessible() {
if (!IsWindow(hwnd))
return NULL;
- LRESULT ret = SendMessage(hwnd, WM_GETOBJECT, 0, OBJID_CLIENT);
IAccessible* accessible = NULL;
- HRESULT success = ObjectFromLresult(
- ret, IID_IDispatch, 0, reinterpret_cast<void**>(accessible));
+ HRESULT success = ::AccessibleObjectFromWindow(
+ hwnd, OBJID_CLIENT, IID_IAccessible,
+ reinterpret_cast<void**>(&accessible));
+
if (success == S_OK) {
return accessible;
} else {