Commit 4b43bf39 authored by Dominic Mazzoni's avatar Dominic Mazzoni Committed by Commit Bot

Simpler fix for infinite loop in Views accessibility on Linux.

This restores things to how they were before
Reland "Consolidated some text helper methods in AXNode"
(http://crrev.com/2224224) with regards to what
ViewAXPlatformNodeDelegate::IsChildOfLeaf returned.

Later if we come up with a better fix for the endless loop we can
restore the proper implementation of IsChildOfLeaf for Views.

Bug: 1100047
Change-Id: I8e34fed0e4dcfd4822386f90b3724dc4977ed5ec
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2277502
Commit-Queue: Nektarios Paisios <nektar@chromium.org>
Reviewed-by: default avatarNektarios Paisios <nektar@chromium.org>
Auto-Submit: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#784361}
parent 98d72298
...@@ -355,6 +355,11 @@ gfx::NativeViewAccessible ViewAXPlatformNodeDelegate::GetParent() { ...@@ -355,6 +355,11 @@ gfx::NativeViewAccessible ViewAXPlatformNodeDelegate::GetParent() {
return nullptr; return nullptr;
} }
bool ViewAXPlatformNodeDelegate::IsChildOfLeaf() const {
// Needed to prevent endless loops, see: http://crbug.com/1100047
return false;
}
bool ViewAXPlatformNodeDelegate::IsLeaf() const { bool ViewAXPlatformNodeDelegate::IsLeaf() const {
return ViewAccessibility::IsLeaf() || AXPlatformNodeDelegateBase::IsLeaf(); return ViewAccessibility::IsLeaf() || AXPlatformNodeDelegateBase::IsLeaf();
} }
......
...@@ -61,6 +61,7 @@ class ViewAXPlatformNodeDelegate : public ViewAccessibility, ...@@ -61,6 +61,7 @@ class ViewAXPlatformNodeDelegate : public ViewAccessibility,
gfx::NativeViewAccessible GetNSWindow() override; gfx::NativeViewAccessible GetNSWindow() override;
gfx::NativeViewAccessible GetNativeViewAccessible() override; gfx::NativeViewAccessible GetNativeViewAccessible() override;
gfx::NativeViewAccessible GetParent() override; gfx::NativeViewAccessible GetParent() override;
bool IsChildOfLeaf() const override;
bool IsLeaf() const override; bool IsLeaf() const override;
gfx::Rect GetBoundsRect( gfx::Rect GetBoundsRect(
const ui::AXCoordinateSystem coordinate_system, const ui::AXCoordinateSystem coordinate_system,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment