[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.17-1283-gcf603cf
mitz at apple.com
mitz at apple.com
Wed Jan 6 00:21:22 UTC 2010
The following commit has been merged in the webkit-1.1 branch:
commit 01562a52c91de7fecad41c85294d024d6a0acb78
Author: mitz at apple.com <mitz at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Jan 5 04:45:28 2010 +0000
<rdar://problem/6655695> REGRESSION: VoiceOver is not highlighting some web elements correctly
<rdar://problem/7397558> REGRESSION: AXImages inside of AXLink cause AXLink to have wrong bounds
Reviewed by Simon Fraser.
WebCore:
Test: accessibility/dimensions-include-descendants.html
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::boundingBoxRect): Use absoluteFocusRingQuads()
for non-text renderers. The focus ring encompasses descendants, which is
what we want for the accessibility indicator.
* rendering/RenderObject.cpp:
(WebCore::RenderObject::absoluteFocusRingQuads): Added.
* rendering/RenderObject.h:
LayoutTests:
* accessibility/dimensions-include-descendants-expected.txt: Added.
* accessibility/dimensions-include-descendants.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@52783 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index c8d3064..3f45ffd 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,13 @@
+2010-01-04 Dan Bernstein <mitz at apple.com>
+
+ Reviewed by Simon Fraser.
+
+ <rdar://problem/6655695> REGRESSION: VoiceOver is not highlighting some web elements correctly
+ <rdar://problem/7397558> REGRESSION: AXImages inside of AXLink cause AXLink to have wrong bounds
+
+ * accessibility/dimensions-include-descendants-expected.txt: Added.
+ * accessibility/dimensions-include-descendants.html: Added.
+
2010-01-04 Jon Honeycutt <jhoneycutt at apple.com>
MSAA: Accessibility role of <select> elements is wrong
diff --git a/LayoutTests/accessibility/dimensions-include-descendants-expected.txt b/LayoutTests/accessibility/dimensions-include-descendants-expected.txt
new file mode 100644
index 0000000..5af72d2
--- /dev/null
+++ b/LayoutTests/accessibility/dimensions-include-descendants-expected.txt
@@ -0,0 +1 @@
+link 1 dimensions: 100 x 100; link 2 dimensions: 100 x 100
diff --git a/LayoutTests/accessibility/dimensions-include-descendants.html b/LayoutTests/accessibility/dimensions-include-descendants.html
new file mode 100644
index 0000000..98508fa
--- /dev/null
+++ b/LayoutTests/accessibility/dimensions-include-descendants.html
@@ -0,0 +1,20 @@
+<!DOCTYPE HTML>
+<div style = "height: 150px;">
+ <a href="#" id="link1"><div style="width: 20px; height: 20px; display: inline-block"></div><div style="width: 80px; height: 100px; float: left;"></div></a>
+</div>
+<div style = "height: 150px;">
+ <a href="#" id="link2"><div style="width: 100px; height: 96px; position: relative; display: inline-block;"></div></a>
+</div>
+<div id="result"></div>
+<script>
+ if (window.accessibilityController) {
+ layoutTestController.dumpAsText();
+
+ document.getElementById("link1").focus();
+ var link1 = accessibilityController.focusedElement;
+ document.getElementById("link2").focus();
+ var link2 = accessibilityController.focusedElement;
+
+ document.getElementById("result").innerText = "link 1 dimensions: " + link1.width + " x " + link1.height + "; link 2 dimensions: " + link2.width + " x " + link2.height;
+ }
+</script>
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 6ee68b4..217228d 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,20 @@
+2010-01-04 Dan Bernstein <mitz at apple.com>
+
+ Reviewed by Simon Fraser.
+
+ <rdar://problem/6655695> REGRESSION: VoiceOver is not highlighting some web elements correctly
+ <rdar://problem/7397558> REGRESSION: AXImages inside of AXLink cause AXLink to have wrong bounds
+
+ Test: accessibility/dimensions-include-descendants.html
+
+ * accessibility/AccessibilityRenderObject.cpp:
+ (WebCore::AccessibilityRenderObject::boundingBoxRect): Use absoluteFocusRingQuads()
+ for non-text renderers. The focus ring encompasses descendants, which is
+ what we want for the accessibility indicator.
+ * rendering/RenderObject.cpp:
+ (WebCore::RenderObject::absoluteFocusRingQuads): Added.
+ * rendering/RenderObject.h:
+
2010-01-04 Ojan Vafai <ojan at ojanmacpro.sfo.corp.google.com>
Reviewed by Dan Bernstein.
diff --git a/WebCore/accessibility/AccessibilityRenderObject.cpp b/WebCore/accessibility/AccessibilityRenderObject.cpp
index 67762f5..c966634 100644
--- a/WebCore/accessibility/AccessibilityRenderObject.cpp
+++ b/WebCore/accessibility/AccessibilityRenderObject.cpp
@@ -1139,7 +1139,10 @@ IntRect AccessibilityRenderObject::boundingBoxRect() const
obj = obj->node()->renderer();
Vector<FloatQuad> quads;
- obj->absoluteQuads(quads);
+ if (obj->isText())
+ obj->absoluteQuads(quads);
+ else
+ obj->absoluteFocusRingQuads(quads);
const size_t n = quads.size();
if (!n)
return IntRect();
diff --git a/WebCore/rendering/RenderObject.cpp b/WebCore/rendering/RenderObject.cpp
index 52ae602..9887869 100644
--- a/WebCore/rendering/RenderObject.cpp
+++ b/WebCore/rendering/RenderObject.cpp
@@ -1076,6 +1076,23 @@ IntRect RenderObject::absoluteBoundingBoxRect(bool useTransforms)
return result;
}
+void RenderObject::absoluteFocusRingQuads(Vector<FloatQuad>& quads)
+{
+ Vector<IntRect> rects;
+ // FIXME: addFocusRingRects() needs to be passed this transform-unaware
+ // localToAbsolute() offset here because RenderInline::addFocusRingRects()
+ // implicitly assumes that. This doesn't work correctly with transformed
+ // descendants.
+ FloatPoint absolutePoint = localToAbsolute();
+ addFocusRingRects(rects, absolutePoint.x(), absolutePoint.y());
+ size_t count = rects.size();
+ for (size_t i = 0; i < count; ++i) {
+ IntRect rect = rects[i];
+ rect.move(-absolutePoint.x(), -absolutePoint.y());
+ quads.append(localToAbsoluteQuad(FloatQuad(rect)));
+ }
+}
+
void RenderObject::addAbsoluteRectForLayer(IntRect& result)
{
if (hasLayer())
diff --git a/WebCore/rendering/RenderObject.h b/WebCore/rendering/RenderObject.h
index c099053..097e088 100644
--- a/WebCore/rendering/RenderObject.h
+++ b/WebCore/rendering/RenderObject.h
@@ -570,6 +570,8 @@ public:
// Build an array of quads in absolute coords for line boxes
virtual void absoluteQuads(Vector<FloatQuad>&) { }
+ void absoluteFocusRingQuads(Vector<FloatQuad>&);
+
// the rect that will be painted if this object is passed as the paintingRoot
IntRect paintingRootRect(IntRect& topLevelRect);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list