summaryrefslogtreecommitdiffstats
path: root/webkit/glue/webaccessibility.cc
diff options
context:
space:
mode:
authorctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-21 22:58:29 +0000
committerctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-21 22:58:29 +0000
commit7650a34df2c9e72a531327fa14387266fc8d6e66 (patch)
treec04af6ccecd34072043d74fd7fbd594b2b4b0ae6 /webkit/glue/webaccessibility.cc
parent22719e06dcb09ba3f33f5ac4424c252a8a41691f (diff)
downloadchromium_src-7650a34df2c9e72a531327fa14387266fc8d6e66.zip
chromium_src-7650a34df2c9e72a531327fa14387266fc8d6e66.tar.gz
chromium_src-7650a34df2c9e72a531327fa14387266fc8d6e66.tar.bz2
Set name of document accessibility nodes to document title.
BUG=36169 TEST=browser_tests:RendererAccessibilityBrowserTest.TestCrossPlatformAccessibilityTree TEST=interactive_ui_tests:AccessibilityWinBrowserTest.TestNotificationActiveDescendantChanged Review URL: http://codereview.chromium.org/3448016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60120 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/webaccessibility.cc')
-rw-r--r--webkit/glue/webaccessibility.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/webkit/glue/webaccessibility.cc b/webkit/glue/webaccessibility.cc
index 38b1cfd..2e75f19 100644
--- a/webkit/glue/webaccessibility.cc
+++ b/webkit/glue/webaccessibility.cc
@@ -314,6 +314,8 @@ void WebAccessibility::Init(const WebKit::WebAccessibilityObject& src,
if (role == WebAccessibility::ROLE_DOCUMENT ||
role == WebAccessibility::ROLE_WEB_AREA) {
WebKit::WebDocument document = src.document();
+ if (name.empty())
+ name = document.title();
attributes[ATTR_DOC_TITLE] = document.title();
attributes[ATTR_DOC_URL] = document.frame()->url().spec().utf16();
if (document.isXHTMLDocument())