[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
hyatt
hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:40:36 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 5621ca53e4c5ed050e180aff75658b2c3693542b
Author: hyatt <hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Wed May 19 05:24:25 2004 +0000
Add two new attributes for accessibility that can be polled by the screen reader. AXLayoutCount indicates
the number of layouts that have occurred, and AXLoaded indicates whether or not a page has finished loading.
* khtml/khtmlview.cpp:
(KHTMLViewPrivate::reset):
(KHTMLView::layoutCount):
(KHTMLView::layout):
* khtml/khtmlview.h:
* kwq/KWQAccObject.mm:
(-[KWQAccObject roleDescription]):
(-[KWQAccObject accessibilityAttributeNames]):
(-[KWQAccObject accessibilityAttributeValue:]):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6633 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 4b63647..71ac284 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,5 +1,20 @@
2004-05-18 David Hyatt <hyatt at apple.com>
+ Add two new attributes for accessibility that can be polled by the screen reader. AXLayoutCount indicates
+ the number of layouts that have occurred, and AXLoaded indicates whether or not a page has finished loading.
+
+ * khtml/khtmlview.cpp:
+ (KHTMLViewPrivate::reset):
+ (KHTMLView::layoutCount):
+ (KHTMLView::layout):
+ * khtml/khtmlview.h:
+ * kwq/KWQAccObject.mm:
+ (-[KWQAccObject roleDescription]):
+ (-[KWQAccObject accessibilityAttributeNames]):
+ (-[KWQAccObject accessibilityAttributeValue:]):
+
+2004-05-18 David Hyatt <hyatt at apple.com>
+
Fix crash when retrieving the AXHelp text.
* kwq/KWQAccObject.mm:
diff --git a/WebCore/khtml/khtmlview.cpp b/WebCore/khtml/khtmlview.cpp
index f74d745..5c9fe12 100644
--- a/WebCore/khtml/khtmlview.cpp
+++ b/WebCore/khtml/khtmlview.cpp
@@ -165,6 +165,7 @@ public:
doFullRepaint = true;
layoutSchedulingEnabled = true;
layoutSuppressed = false;
+ layoutCount = 0;
#if APPLE_CHANGES
firstLayout = true;
#endif
@@ -206,6 +207,8 @@ public:
bool layoutSchedulingEnabled;
bool layoutSuppressed;
+ int layoutCount;
+
#if APPLE_CHANGES
bool firstLayout;
bool needToInitScrollBars;
@@ -511,6 +514,11 @@ bool KHTMLView::inLayout() const
return d->layoutSuppressed;
}
+int KHTMLView::layoutCount() const
+{
+ return d->layoutCount;
+}
+
bool KHTMLView::needsFullRepaint() const
{
return d->doFullRepaint;
@@ -659,6 +667,8 @@ void KHTMLView::layout()
d->repaintRects->clear();
}
+ d->layoutCount++;
+
if (root->needsLayout()) {
//qDebug("needs layout, delaying repaint");
scheduleRelayout();
diff --git a/WebCore/khtml/khtmlview.h b/WebCore/khtml/khtmlview.h
index 0b746f7..edcf1e7 100644
--- a/WebCore/khtml/khtmlview.h
+++ b/WebCore/khtml/khtmlview.h
@@ -155,6 +155,7 @@ public:
void layout();
bool inLayout() const;
+ int layoutCount() const;
bool needsFullRepaint() const;
diff --git a/WebCore/kwq/KWQAccObject.mm b/WebCore/kwq/KWQAccObject.mm
index 0bdb410..2bc4748 100644
--- a/WebCore/kwq/KWQAccObject.mm
+++ b/WebCore/kwq/KWQAccObject.mm
@@ -289,6 +289,9 @@ using khtml::RenderImage;
if ([role isEqualToString:@"AXListMarker"])
return UI_STRING("list marker", "accessibility role description for list marker");
+ if ([role isEqualToString:@"AXImageMap"])
+ return UI_STRING("image map", "accessibility role description for image map");
+
return UI_STRING("unknown", "accessibility role description for unknown role");
}
@@ -497,6 +500,8 @@ static QRect boundingBoxRect(RenderObject* obj)
NSAccessibilityEnabledAttribute,
NSAccessibilityWindowAttribute,
@"AXLinkUIElements",
+ @"AXLoaded",
+ @"AXLayoutCount",
nil];
}
@@ -564,19 +569,25 @@ static QRect boundingBoxRect(RenderObject* obj)
return m_children;
}
- if ([attributeName isEqualToString: @"AXLinkUIElements"] && m_renderer->isCanvas()) {
- NSMutableArray* links = [NSMutableArray arrayWithCapacity: 32];
- HTMLCollection coll(m_renderer->document(), HTMLCollectionImpl::DOC_LINKS);
- if (coll.isNull())
+ if (m_renderer->isCanvas()) {
+ if ([attributeName isEqualToString: @"AXLinkUIElements"]) {
+ NSMutableArray* links = [NSMutableArray arrayWithCapacity: 32];
+ HTMLCollection coll(m_renderer->document(), HTMLCollectionImpl::DOC_LINKS);
+ if (coll.isNull())
+ return links;
+ Node curr = coll.firstItem();
+ while (!curr.isNull()) {
+ RenderObject* obj = curr.handle()->renderer();
+ if (obj)
+ [links addObject: obj->document()->getOrCreateAccObjectCache()->accObject(obj)];
+ curr = coll.nextItem();
+ }
return links;
- Node curr = coll.firstItem();
- while (!curr.isNull()) {
- RenderObject* obj = curr.handle()->renderer();
- if (obj)
- [links addObject: obj->document()->getOrCreateAccObjectCache()->accObject(obj)];
- curr = coll.nextItem();
}
- return links;
+ else if ([attributeName isEqualToString: @"AXLoaded"])
+ return [NSNumber numberWithBool: (!m_renderer->document()->tokenizer())];
+ else if ([attributeName isEqualToString: @"AXLayoutCount"])
+ return [NSNumber numberWithInt: (static_cast<RenderCanvas*>(m_renderer)->view()->layoutCount())];
}
if ([attributeName isEqualToString: @"AXURL"] &&
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list