Diff
Modified: trunk/LayoutTests/ChangeLog (244537 => 244538)
--- trunk/LayoutTests/ChangeLog 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/LayoutTests/ChangeLog 2019-04-23 10:47:45 UTC (rev 244538)
@@ -1,3 +1,14 @@
+2019-04-23 Carlos Garcia Campos <[email protected]>
+
+ [ATK] Implement AtkComponentIface scroll_to methods
+ https://bugs.webkit.org/show_bug.cgi?id=196856
+
+ Reviewed by Michael Catanzaro.
+
+ Remove expectations for tests that are passing now.
+
+ * platform/gtk/TestExpectations:
+
2019-04-22 Zalan Bujtas <[email protected]>
[ContentChangeObserver] Some dropdown menus may close without user gesture on americanexpress.com
Modified: trunk/LayoutTests/platform/gtk/TestExpectations (244537 => 244538)
--- trunk/LayoutTests/platform/gtk/TestExpectations 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/LayoutTests/platform/gtk/TestExpectations 2019-04-23 10:47:45 UTC (rev 244538)
@@ -817,8 +817,6 @@
# No support for Filters Level 2 on GTK yet
webkit.org/b/169988 css3/filters/backdrop [ Skip ]
-webkit.org/b/141072 accessibility/frame-disconnect-textmarker-cache-crash.html [ Failure ]
-
webkit.org/b/141423 fast/css/font-shorthand-from-longhands.html [ Failure ]
webkit.org/b/141423 fast/css/font-shorthand-line-height.html [ Failure ]
webkit.org/b/141423 fast/css/getComputedStyle/computed-style-font.html [ Failure ]
@@ -907,6 +905,7 @@
# Text marker tests are not supported
webkit.org/b/153292 accessibility/text-marker [ Skip ]
+webkit.org/b/141072 accessibility/frame-disconnect-textmarker-cache-crash.html [ Skip ]
# WebKitGTK+ doesn't have killring support.
webkit.org/b/152379 editing/pasteboard/emacs-killring-alternating-append-prepend.html [ Failure ]
@@ -3110,14 +3109,6 @@
webkit.org/b/148932 imported/w3c/web-platform-tests/css/css-color/t424-hsl-basic-a.xht [ ImageOnlyFailure Pass ]
webkit.org/b/148932 imported/w3c/web-platform-tests/css/css-color/t425-hsla-clip-outside-device-gamut-b.xht [ ImageOnlyFailure ]
-webkit.org/b/148935 accessibility/scroll-to-global-point-iframe-nested.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-global-point-iframe.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-global-point-main-window.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-global-point-nested.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-make-visible-div-overflow.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-make-visible-iframe.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-make-visible-nested-2.html [ Failure ]
-webkit.org/b/148935 accessibility/scroll-to-make-visible-nested.html [ Failure ]
webkit.org/b/148935 accessibility/scroll-to-make-visible-with-subfocus.html [ Failure ]
webkit.org/b/149128 fast/text/control-characters [ ImageOnlyFailure ]
Modified: trunk/Source/WebCore/ChangeLog (244537 => 244538)
--- trunk/Source/WebCore/ChangeLog 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Source/WebCore/ChangeLog 2019-04-23 10:47:45 UTC (rev 244538)
@@ -1,3 +1,35 @@
+2019-04-23 Carlos Garcia Campos <[email protected]>
+
+ [ATK] Implement AtkComponentIface scroll_to methods
+ https://bugs.webkit.org/show_bug.cgi?id=196856
+
+ Reviewed by Michael Catanzaro.
+
+ Implement scroll_to and scroll_to_point when ATK >= 2.30.
+
+ Fixes: accessibility/scroll-to-global-point-iframe-nested.html
+ accessibility/scroll-to-global-point-iframe.html
+ accessibility/scroll-to-global-point-main-window.html
+ accessibility/scroll-to-global-point-nested.html
+ accessibility/scroll-to-make-visible-div-overflow.html
+ accessibility/scroll-to-make-visible-iframe.html
+ accessibility/scroll-to-make-visible-nested-2.html
+ accessibility/scroll-to-make-visible-nested.html
+
+ * accessibility/AccessibilityObject.cpp:
+ (WebCore::AccessibilityObject::scrollToMakeVisible const): Add new method receiving the
+ ScrollRectToVisibleOptions since ATK interface has a parameter to decide how to scroll.
+ * accessibility/AccessibilityObject.h:
+ * accessibility/atk/WebKitAccessibleInterfaceComponent.cpp:
+ (atkToContents):
+ (webkitAccessibleComponentRefAccessibleAtPoint):
+ (webkitAccessibleComponentGetExtents):
+ (webkitAccessibleComponentGrabFocus):
+ (webkitAccessibleComponentScrollTo):
+ (webkitAccessibleComponentScrollToPoint):
+ (webkitAccessibleComponentInterfaceInit):
+ (core): Deleted.
+
2019-04-22 Youenn Fablet <[email protected]>
Update libwebrtc logging when WebCore WebRTC logging is updated
Modified: trunk/Source/WebCore/accessibility/AccessibilityObject.cpp (244537 => 244538)
--- trunk/Source/WebCore/accessibility/AccessibilityObject.cpp 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Source/WebCore/accessibility/AccessibilityObject.cpp 2019-04-23 10:47:45 UTC (rev 244538)
@@ -3064,14 +3064,19 @@
void AccessibilityObject::scrollToMakeVisible() const
{
+ scrollToMakeVisible({ SelectionRevealMode::Reveal, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
+}
+
+void AccessibilityObject::scrollToMakeVisible(const ScrollRectToVisibleOptions& options) const
+{
if (dispatchAccessibilityEventWithType(AccessibilityEventType::ScrollIntoView))
return;
-
+
if (isScrollView() && parentObject())
parentObject()->scrollToMakeVisible();
if (auto* renderer = this->renderer())
- renderer->scrollRectToVisible(boundingBoxRect(), false, { SelectionRevealMode::Reveal, ScrollAlignment::alignCenterIfNeeded, ScrollAlignment::alignCenterIfNeeded, ShouldAllowCrossOriginScrolling::Yes });
+ renderer->scrollRectToVisible(boundingBoxRect(), false, options);
}
void AccessibilityObject::scrollToMakeVisibleWithSubFocus(const IntRect& subfocus) const
Modified: trunk/Source/WebCore/accessibility/AccessibilityObject.h (244537 => 244538)
--- trunk/Source/WebCore/accessibility/AccessibilityObject.h 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Source/WebCore/accessibility/AccessibilityObject.h 2019-04-23 10:47:45 UTC (rev 244538)
@@ -81,6 +81,7 @@
class ScrollableArea;
class ScrollView;
class Widget;
+struct ScrollRectToVisibleOptions;
enum class AccessibilityTextSource {
Alternative,
@@ -882,6 +883,7 @@
IntPoint scrollPosition() const;
IntSize scrollContentsSize() const;
IntRect scrollVisibleContentRect() const;
+ void scrollToMakeVisible(const ScrollRectToVisibleOptions&) const;
bool lastKnownIsIgnoredValue();
void setLastKnownIsIgnoredValue(bool);
Modified: trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceComponent.cpp (244537 => 244538)
--- trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceComponent.cpp 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceComponent.cpp 2019-04-23 10:47:45 UTC (rev 244538)
@@ -36,77 +36,137 @@
#include "AccessibilityObject.h"
#include "FrameView.h"
#include "IntRect.h"
+#include "RenderLayer.h"
#include "WebKitAccessible.h"
#include "WebKitAccessibleUtil.h"
using namespace WebCore;
-static AccessibilityObject* core(AtkComponent* component)
+static IntPoint atkToContents(const AccessibilityObject& coreObject, AtkCoordType coordType, gint x, gint y)
{
- if (!WEBKIT_IS_ACCESSIBLE(component))
- return 0;
+ auto* frameView = coreObject.documentFrameView();
+ if (!frameView)
+ return { x, y };
- return &webkitAccessibleGetAccessibilityObject(WEBKIT_ACCESSIBLE(component));
-}
-
-static IntPoint atkToContents(AccessibilityObject* coreObject, AtkCoordType coordType, gint x, gint y)
-{
- IntPoint pos(x, y);
-
- FrameView* frameView = coreObject->documentFrameView();
- if (frameView) {
- switch (coordType) {
- case ATK_XY_SCREEN:
- return frameView->screenToContents(pos);
- case ATK_XY_WINDOW:
- return frameView->windowToContents(pos);
+ switch (coordType) {
+ case ATK_XY_SCREEN:
+ return frameView->screenToContents({ x, y });
+ case ATK_XY_WINDOW:
+ return frameView->windowToContents({ x, y });
#if ATK_CHECK_VERSION(2, 30, 0)
- case ATK_XY_PARENT:
- RELEASE_ASSERT_NOT_REACHED();
+ case ATK_XY_PARENT:
+ RELEASE_ASSERT_NOT_REACHED();
#endif
- }
}
- return pos;
+ return { x, y };
}
static AtkObject* webkitAccessibleComponentRefAccessibleAtPoint(AtkComponent* component, gint x, gint y, AtkCoordType coordType)
{
- g_return_val_if_fail(ATK_IS_COMPONENT(component), 0);
- returnValIfWebKitAccessibleIsInvalid(WEBKIT_ACCESSIBLE(component), 0);
+ auto* accessible = WEBKIT_ACCESSIBLE(component);
+ returnValIfWebKitAccessibleIsInvalid(accessible, nullptr);
- IntPoint pos = atkToContents(core(component), coordType, x, y);
+ auto& coreObject = webkitAccessibleGetAccessibilityObject(accessible);
+ auto* target = downcast<AccessibilityObject>(coreObject.accessibilityHitTest(atkToContents(coreObject, coordType, x, y)));
+ if (!target)
+ return nullptr;
- AccessibilityObject* target = downcast<AccessibilityObject>(core(component)->accessibilityHitTest(pos));
- if (!target)
- return 0;
- g_object_ref(target->wrapper());
- return ATK_OBJECT(target->wrapper());
+ if (auto* wrapper = target->wrapper())
+ return ATK_OBJECT(g_object_ref(wrapper));
+
+ return nullptr;
}
static void webkitAccessibleComponentGetExtents(AtkComponent* component, gint* x, gint* y, gint* width, gint* height, AtkCoordType coordType)
{
- g_return_if_fail(ATK_IS_COMPONENT(component));
- returnIfWebKitAccessibleIsInvalid(WEBKIT_ACCESSIBLE(component));
+ auto* accessible = WEBKIT_ACCESSIBLE(component);
+ returnIfWebKitAccessibleIsInvalid(accessible);
- IntRect rect = snappedIntRect(core(component)->elementRect());
- contentsRelativeToAtkCoordinateType(core(component), coordType, rect, x, y, width, height);
+ auto& coreObject = webkitAccessibleGetAccessibilityObject(accessible);
+ contentsRelativeToAtkCoordinateType(&coreObject, coordType, snappedIntRect(coreObject.elementRect()), x, y, width, height);
}
static gboolean webkitAccessibleComponentGrabFocus(AtkComponent* component)
{
- g_return_val_if_fail(ATK_IS_COMPONENT(component), FALSE);
- returnValIfWebKitAccessibleIsInvalid(WEBKIT_ACCESSIBLE(component), FALSE);
+ auto* accessible = WEBKIT_ACCESSIBLE(component);
+ returnValIfWebKitAccessibleIsInvalid(accessible, FALSE);
- core(component)->setFocused(true);
- return core(component)->isFocused();
+ auto& coreObject = webkitAccessibleGetAccessibilityObject(accessible);
+ coreObject.setFocused(true);
+ return coreObject.isFocused();
}
+#if ATK_CHECK_VERSION(2, 30, 0)
+static gboolean webkitAccessibleComponentScrollTo(AtkComponent* component, AtkScrollType scrollType)
+{
+ auto* accessible = WEBKIT_ACCESSIBLE(component);
+ returnValIfWebKitAccessibleIsInvalid(accessible, FALSE);
+
+ ScrollAlignment alignX;
+ ScrollAlignment alignY;
+
+ switch (scrollType) {
+ case ATK_SCROLL_TOP_LEFT:
+ alignX = ScrollAlignment::alignLeftAlways;
+ alignY = ScrollAlignment::alignTopAlways;
+ break;
+ case ATK_SCROLL_BOTTOM_RIGHT:
+ alignX = ScrollAlignment::alignRightAlways;
+ alignY = ScrollAlignment::alignBottomAlways;
+ break;
+ case ATK_SCROLL_TOP_EDGE:
+ case ATK_SCROLL_BOTTOM_EDGE:
+ // Align to a particular edge is not supported, it's always the closest edge.
+ alignX = ScrollAlignment::alignCenterIfNeeded;
+ alignY = ScrollAlignment::alignToEdgeIfNeeded;
+ break;
+ case ATK_SCROLL_LEFT_EDGE:
+ case ATK_SCROLL_RIGHT_EDGE:
+ // Align to a particular edge is not supported, it's always the closest edge.
+ alignX = ScrollAlignment::alignToEdgeIfNeeded;
+ alignY = ScrollAlignment::alignCenterIfNeeded;
+ break;
+ case ATK_SCROLL_ANYWHERE:
+ alignX = ScrollAlignment::alignCenterIfNeeded;
+ alignY = ScrollAlignment::alignCenterIfNeeded;
+ break;
+ }
+
+ auto& coreObject = webkitAccessibleGetAccessibilityObject(accessible);
+ coreObject.scrollToMakeVisible({ SelectionRevealMode::Reveal, alignX, alignY, ShouldAllowCrossOriginScrolling::Yes });
+
+ return TRUE;
+}
+
+static gboolean webkitAccessibleComponentScrollToPoint(AtkComponent* component, AtkCoordType coordType, gint x, gint y)
+{
+ auto* accessible = WEBKIT_ACCESSIBLE(component);
+ returnValIfWebKitAccessibleIsInvalid(accessible, FALSE);
+
+ auto& coreObject = webkitAccessibleGetAccessibilityObject(accessible);
+
+ IntPoint point(x, y);
+ if (coordType == ATK_XY_SCREEN) {
+ if (auto* frameView = coreObject.documentFrameView())
+ point = frameView->contentsToWindow(frameView->screenToContents(point));
+ }
+
+ coreObject.scrollToGlobalPoint(point);
+
+ return TRUE;
+}
+#endif
+
void webkitAccessibleComponentInterfaceInit(AtkComponentIface* iface)
{
iface->ref_accessible_at_point = webkitAccessibleComponentRefAccessibleAtPoint;
iface->get_extents = webkitAccessibleComponentGetExtents;
iface->grab_focus = webkitAccessibleComponentGrabFocus;
+#if ATK_CHECK_VERSION(2, 30, 0)
+ iface->scroll_to = webkitAccessibleComponentScrollTo;
+ iface->scroll_to_point = webkitAccessibleComponentScrollToPoint;
+#endif
}
-#endif
+#endif // HAVE(ACCESSIBILITY)
Modified: trunk/Tools/ChangeLog (244537 => 244538)
--- trunk/Tools/ChangeLog 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Tools/ChangeLog 2019-04-23 10:47:45 UTC (rev 244538)
@@ -1,3 +1,15 @@
+2019-04-23 Carlos Garcia Campos <[email protected]>
+
+ [ATK] Implement AtkComponentIface scroll_to methods
+ https://bugs.webkit.org/show_bug.cgi?id=196856
+
+ Reviewed by Michael Catanzaro.
+
+ * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
+ (WTR::AccessibilityUIElement::scrollToMakeVisible): Call atk_component_scroll_to().
+ (WTR::AccessibilityUIElement::scrollToGlobalPoint): Call atk_component_scroll_to_point().
+ * gtk/jhbuild.modules: Bump atk, at-spi2-core and at-spi2-atk to their latest stable version.
+
2019-04-22 Aakash Jain <[email protected]>
[ews-build] Improve summary for UploadBuiltProduct step
Modified: trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp (244537 => 244538)
--- trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp 2019-04-23 10:47:45 UTC (rev 244538)
@@ -2332,14 +2332,24 @@
void AccessibilityUIElement::scrollToMakeVisible()
{
- // FIXME: implement
+#if ATK_CHECK_VERSION(2, 30, 0)
+ if (!ATK_IS_COMPONENT(m_element.get()))
+ return;
+
+ atk_component_scroll_to(ATK_COMPONENT(m_element.get()), ATK_SCROLL_ANYWHERE);
+#endif
}
-
+
void AccessibilityUIElement::scrollToGlobalPoint(int x, int y)
{
- // FIXME: implement
+#if ATK_CHECK_VERSION(2, 30, 0)
+ if (!ATK_IS_COMPONENT(m_element.get()))
+ return;
+
+ atk_component_scroll_to_point(ATK_COMPONENT(m_element.get()), ATK_XY_WINDOW, x, y);
+#endif
}
-
+
void AccessibilityUIElement::scrollToMakeVisibleWithSubFocus(int x, int y, int width, int height)
{
// FIXME: implement
Modified: trunk/Tools/gtk/jhbuild.modules (244537 => 244538)
--- trunk/Tools/gtk/jhbuild.modules 2019-04-23 01:36:39 UTC (rev 244537)
+++ trunk/Tools/gtk/jhbuild.modules 2019-04-23 10:47:45 UTC (rev 244538)
@@ -281,31 +281,26 @@
hash="sha256:ccf79ff3bd340254737ce4d28b87f0ccee4b3358cd3cd5cd11dc7b42f41b272a"/>
</autotools>
- <autotools id="atk"
- autogen-sh="configure"
- autogenargs="--disable-introspection">
- <branch module="pub/GNOME/sources/atk/2.25/atk-2.25.2.tar.xz" version="2.25.2"
+ <meson id="atk" mesonargs="-Dintrospection=false">
+ <branch module="pub/GNOME/sources/atk/2.32/atk-2.32.0.tar.xz" version="2.32.0"
repo="ftp.gnome.org"
- hash="sha256:75ac1f63e845f895dec8d72d4645ef5f362e32c921cc78987f2f19c2ce212a24"/>
- </autotools>
+ hash="sha256:cb41feda7fe4ef0daa024471438ea0219592baf7c291347e5a858bb64e4091cc"/>
+ </meson>
- <autotools id="at-spi2-core"
- autogen-sh="configure"
- autogenargs="--disable-introspection">
- <branch module="pub/GNOME/sources/at-spi2-core/2.25/at-spi2-core-2.25.4.tar.xz" version="2.25.4"
+ <meson id="at-spi2-core" mesonargs="-Dintrospection=no">
+ <branch module="pub/GNOME/sources/at-spi2-core/2.32/at-spi2-core-2.32.1.tar.xz" version="2.32.1"
repo="ftp.gnome.org"
- hash="sha256:baeccbf92e84e64bb4a853f076c27b78ab44edf1fa5414a9c6e59a9b180bc9d8">
+ hash="sha256:3c2aa937ebfaca2c86569bce9b16a34fbe20d69ef0c58846313b1c42f53b0d53">
</branch>
<dependencies>
<dep package="glib"/>
</dependencies>
- </autotools>
+ </meson>
- <autotools id="at-spi2-atk"
- autogen-sh="configure">
- <branch module="pub/GNOME/sources/at-spi2-atk/2.25/at-spi2-atk-2.25.3.tar.xz" version="2.25.3"
+ <meson id="at-spi2-atk">
+ <branch module="pub/GNOME/sources/at-spi2-atk/2.32/at-spi2-atk-2.32.0.tar.xz" version="2.32.0"
repo="ftp.gnome.org"
- hash="sha256:b7aab1a4ee7182083fcfafb595b7b3fe4df34aa2230c775050fe6015b01f84e1">
+ hash="sha256:0b51e6d339fa2bcca3a3e3159ccea574c67b107f1ac8b00047fa60e34ce7a45c">
</branch>
<dependencies>
<dep package="glib"/>
@@ -312,7 +307,7 @@
<dep package="atk"/>
<dep package="at-spi2-core"/>
</dependencies>
- </autotools>
+ </meson>
<autotools id="libxml2" supports-non-srcdir-builds="no"
autogen-sh="./autogen.sh; ./configure --with-python=no">