Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(725)

Unified Diff: third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp

Issue 1713723002: Implement accessibility support for CSS-transformed iframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix gn build Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp
diff --git a/third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp b/third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp
index 342874f1e40051063de30fc6d7e0ecffa909c1ae..073bc4b8893d0c77d003d6147e792bbe2a9f42c2 100644
--- a/third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp
+++ b/third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp
@@ -80,6 +80,7 @@
#include "modules/accessibility/AXSpinButton.h"
#include "modules/accessibility/AXTable.h"
#include "platform/fonts/FontTraits.h"
+#include "platform/geometry/TransformState.h"
#include "platform/text/PlatformLocale.h"
#include "platform/text/TextDirection.h"
#include "wtf/StdLibExtras.h"
@@ -218,6 +219,23 @@ LayoutRect AXLayoutObject::elementRect() const
return m_cachedElementRect;
}
+SkMatrix44 AXLayoutObject::transformFromLocalParentFrame() const
+{
+ if (!m_layoutObject)
+ return SkMatrix44();
+ LayoutView* layoutView = documentFrameView()->layoutView();
+
+ FrameView* parentFrameView = documentFrameView()->parentFrameView();
+ if (!parentFrameView)
+ return SkMatrix44();
+ LayoutView* parentLayoutView = parentFrameView->layoutView();
+
+ TransformationMatrix accumulatedTransform = layoutView->localToAncestorTransform(parentLayoutView, TraverseDocumentBoundaries);
+ IntPoint scrollPosition = documentFrameView()->scrollPosition();
+ accumulatedTransform.translate(scrollPosition.x(), scrollPosition.y());
+ return TransformationMatrix::toSkMatrix44(accumulatedTransform);
+}
+
LayoutBoxModelObject* AXLayoutObject::getLayoutBoxModelObject() const
{
if (!m_layoutObject || !m_layoutObject->isBoxModelObject())

Powered by Google App Engine
This is Rietveld 408576698