<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[166175] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/166175">166175</a></dd>
<dt>Author</dt> <dd>cfleizach@apple.com</dd>
<dt>Date</dt> <dd>2014-03-24 10:08:00 -0700 (Mon, 24 Mar 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>&lt;hr&gt; should expose AXRole/AXSubrole, etc
https://bugs.webkit.org/show_bug.cgi?id=109015

Reviewed by Mario Sanchez Prada.

Source/WebCore: 

Expose the &lt;hr&gt; element to Mac and iOS through the accessibility interface.

Test: platform/mac/accessibility/hr-element.html

* English.lproj/Localizable.strings:
* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::isEnabled):
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::computedRoleString):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
* accessibility/atk/AccessibilityObjectAtk.cpp:
(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
* accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):
(-[WebAccessibilityObjectWrapper accessibilityLabel]):
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(createAccessibilityRoleMap):
(-[WebAccessibilityObjectWrapper subrole]):
(-[WebAccessibilityObjectWrapper roleDescription]):
* platform/LocalizedStrings.cpp:
(WebCore::AXHorizontalRuleDescriptionText):
* platform/LocalizedStrings.h:

LayoutTests: 

* accessibility/lists.html:
    - An errant &lt;hr&gt; element was in this test which changed results
* accessibility/roles-computedRoleString-expected.txt:
* accessibility/roles-exposed.html:
* platform/gtk/accessibility/roles-exposed-expected.txt: Added.
* platform/mac/accessibility/hr-element-expected.txt: Added.
* platform/mac/accessibility/hr-element.html: Added.
* platform/mac/accessibility/lists-expected.txt:
* platform/mac/accessibility/roles-exposed-expected.txt:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsaccessibilitylistshtml">trunk/LayoutTests/accessibility/lists.html</a></li>
<li><a href="#trunkLayoutTestsaccessibilityrolescomputedRoleStringexpectedtxt">trunk/LayoutTests/accessibility/roles-computedRoleString-expected.txt</a></li>
<li><a href="#trunkLayoutTestsaccessibilityrolesexposedhtml">trunk/LayoutTests/accessibility/roles-exposed.html</a></li>
<li><a href="#trunkLayoutTestsplatformmacaccessibilitylistsexpectedtxt">trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt</a></li>
<li><a href="#trunkLayoutTestsplatformmacaccessibilityrolesexposedexpectedtxt">trunk/LayoutTests/platform/mac/accessibility/roles-exposed-expected.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreEnglishlprojLocalizablestrings">trunk/Source/WebCore/English.lproj/Localizable.strings</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityNodeObjectcpp">trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityObjectcpp">trunk/Source/WebCore/accessibility/AccessibilityObject.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityRenderObjectcpp">trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityatkAccessibilityObjectAtkcpp">trunk/Source/WebCore/accessibility/atk/AccessibilityObjectAtk.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityiosWebAccessibilityObjectWrapperIOSmm">trunk/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm</a></li>
<li><a href="#trunkSourceWebCoreaccessibilitymacWebAccessibilityObjectWrapperMacmm">trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm</a></li>
<li><a href="#trunkSourceWebCoreplatformLocalizedStringscpp">trunk/Source/WebCore/platform/LocalizedStrings.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformLocalizedStringsh">trunk/Source/WebCore/platform/LocalizedStrings.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsplatformmacaccessibilityhrelementexpectedtxt">trunk/LayoutTests/platform/mac/accessibility/hr-element-expected.txt</a></li>
<li><a href="#trunkLayoutTestsplatformmacaccessibilityhrelementhtml">trunk/LayoutTests/platform/mac/accessibility/hr-element.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/ChangeLog        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -1,3 +1,20 @@
</span><ins>+2014-03-24  Chris Fleizach  &lt;cfleizach@apple.com&gt;
+
+        &lt;hr&gt; should expose AXRole/AXSubrole, etc
+        https://bugs.webkit.org/show_bug.cgi?id=109015
+
+        Reviewed by Mario Sanchez Prada.
+
+        * accessibility/lists.html:
+            - An errant &lt;hr&gt; element was in this test which changed results
+        * accessibility/roles-computedRoleString-expected.txt:
+        * accessibility/roles-exposed.html:
+        * platform/gtk/accessibility/roles-exposed-expected.txt: Added.
+        * platform/mac/accessibility/hr-element-expected.txt: Added.
+        * platform/mac/accessibility/hr-element.html: Added.
+        * platform/mac/accessibility/lists-expected.txt:
+        * platform/mac/accessibility/roles-exposed-expected.txt:
+
</ins><span class="cx"> 2014-03-24  Antti Koivisto  &lt;antti@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Invalidate sibling text node style when needed instead of attaching synchronously
</span></span></pre></div>
<a id="trunkLayoutTestsaccessibilitylistshtml"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/accessibility/lists.html (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/accessibility/lists.html        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/accessibility/lists.html        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -25,7 +25,7 @@
</span><span class="cx">       &lt;dd&gt;meaning 2&lt;/dd&gt;
</span><span class="cx">     &lt;/dl&gt;
</span><span class="cx"> 
</span><del>-    &lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;hr&gt;&lt;BR&gt;
</del><ins>+    &lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;
</ins><span class="cx">     &lt;div id=&quot;result&quot;&gt;&lt;/div&gt;    
</span><span class="cx"> 
</span><span class="cx">     &lt;script&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsaccessibilityrolescomputedRoleStringexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/accessibility/roles-computedRoleString-expected.txt (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/accessibility/roles-computedRoleString-expected.txt        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/accessibility/roles-computedRoleString-expected.txt        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -19,6 +19,7 @@
</span><span class="cx"> PASS: h4 -&gt; heading. 
</span><span class="cx"> PASS: h5 -&gt; heading. 
</span><span class="cx"> PASS: h5 -&gt; heading. 
</span><ins>+PASS: hr -&gt; separator. 
</ins><span class="cx"> PASS: img[alt='X'] -&gt; img. 
</span><span class="cx"> PASS: input[type='button'] -&gt; button. 
</span><span class="cx"> PASS: input[type='checkbox'] -&gt; checkbox. 
</span></span></pre></div>
<a id="trunkLayoutTestsaccessibilityrolesexposedhtml"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/accessibility/roles-exposed.html (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/accessibility/roles-exposed.html        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/accessibility/roles-exposed.html        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -50,7 +50,7 @@
</span><span class="cx"> &lt;h4 data-platform=&quot;atk,mac&quot; data-role=&quot;AXHeading&quot; data-subrole=&quot;&quot; data-roledescription=&quot;heading&quot; class=&quot;ex&quot;&gt;X&lt;/h4&gt;
</span><span class="cx"> &lt;h5 data-platform=&quot;atk,mac&quot; data-role=&quot;AXHeading&quot; data-subrole=&quot;&quot; data-roledescription=&quot;heading&quot; class=&quot;ex&quot;&gt;X&lt;/h5&gt;
</span><span class="cx"> &lt;h6 data-platform=&quot;atk,mac&quot; data-role=&quot;AXHeading&quot; data-subrole=&quot;&quot; data-roledescription=&quot;heading&quot; class=&quot;ex&quot;&gt;X&lt;/h6&gt;
</span><del>-&lt;!-- http://webkit.org/b/109015 --&gt;&lt;hr data-platform=&quot;atk,mac&quot; data-role=&quot;&quot; data-role-atk=&quot;AXSeparator&quot; data-subrole=&quot;&quot; data-roledescription=&quot;&quot; class=&quot;ex&quot;&gt;
</del><ins>+&lt;hr data-platform=&quot;atk,mac&quot; data-role-mac=&quot;AXSplitter&quot; data-role-atk=&quot;AXSeparator&quot; data-subrole=&quot;AXContentSeparator&quot; data-roledescription=&quot;separator&quot; class=&quot;ex&quot;&gt;
</ins><span class="cx"> &lt;!-- skipped &lt;html&gt; --&gt;
</span><span class="cx"> &lt;!-- [ATK] Skipped: not focusable --&gt;&lt;i data-platform=&quot;mac&quot; data-role=&quot;&quot; data-subrole=&quot;&quot; data-roledescription=&quot;&quot; class=&quot;ex&quot;&gt;X&lt;/i&gt;
</span><span class="cx"> &lt;!-- skipped &lt;iframe&gt; --&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsplatformmacaccessibilityhrelementexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/platform/mac/accessibility/hr-element-expected.txt (0 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/accessibility/hr-element-expected.txt                                (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/hr-element-expected.txt        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -0,0 +1,30 @@
</span><ins>+This tests that the 'hr' element is accessible on the Mac.
+
+On success, you will see a series of &quot;PASS&quot; messages, followed by &quot;TEST COMPLETE&quot;.
+
+
+hr1 role: AXRole: AXSplitter
+hr1 subrole: AXSubrole: AXContentSeparator
+hr1 roleDescription: AXRoleDescription: separator
+hr1 description: AXDescription: 
+hr1 is value settable: false
+hr1 is enabled: false
+
+hr2 role: AXRole: AXSplitter
+hr2 subrole: AXSubrole: AXContentSeparator
+hr2 roleDescription: AXRoleDescription: separator
+hr2 description: AXDescription: 
+hr2 is value settable: false
+hr2 is enabled: false
+
+hr3 role: AXRole: AXSplitter
+hr3 subrole: AXSubrole: AXContentSeparator
+hr3 roleDescription: AXRoleDescription: separator
+hr3 description: AXDescription: RULER
+hr3 is value settable: false
+hr3 is enabled: false
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
</ins></span></pre></div>
<a id="trunkLayoutTestsplatformmacaccessibilityhrelementhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/platform/mac/accessibility/hr-element.html (0 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/accessibility/hr-element.html                                (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/hr-element.html        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -0,0 +1,41 @@
</span><ins>+&lt;!DOCTYPE HTML PUBLIC &quot;-//IETF//DTD HTML//EN&quot;&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;script src=&quot;../../../resources/js-test-pre.js&quot;&gt;&lt;/script&gt;
+&lt;/head&gt;
+&lt;body id=&quot;body&quot;&gt;
+
+&lt;div id=&quot;content&quot;&gt;
+&lt;hr id=&quot;hr1&quot; onclick=&quot;test();&quot;&gt;
+
+&lt;hr id=&quot;hr2&quot;&gt;
+
+&lt;hr id=&quot;hr3&quot; aria-label=&quot;RULER&quot; tabindex=&quot;0&quot;&gt;
+&lt;/div&gt;
+
+&lt;p id=&quot;description&quot;&gt;&lt;/p&gt;
+&lt;div id=&quot;console&quot;&gt;&lt;/div&gt;
+
+&lt;script&gt;
+
+    description(&quot;This tests that the 'hr' element is accessible on the Mac.&quot;);
+
+    if (window.accessibilityController) {
+
+        for (var k = 1; k &lt;= 3; k++) {
+           var hr = accessibilityController.accessibleElementById(&quot;hr&quot; + k);
+           debug(&quot;hr&quot; + k + &quot; role: &quot; + hr.role);
+           debug(&quot;hr&quot; + k + &quot; subrole: &quot; + hr.subrole);
+           debug(&quot;hr&quot; + k + &quot; roleDescription: &quot; + hr.roleDescription);
+           debug(&quot;hr&quot; + k + &quot; description: &quot; + hr.description);
+           debug(&quot;hr&quot; + k + &quot; is value settable: &quot; + hr.isAttributeSettable('AXValue'));
+           debug(&quot;hr&quot; + k + &quot; is enabled: &quot; + hr.isEnabled + &quot;\n&quot;);
+        }
+        document.getElementById(&quot;content&quot;).style.visibility = &quot;none&quot;;
+    }
+
+&lt;/script&gt;
+
+&lt;script src=&quot;../../../resources/js-test-post.js&quot;&gt;&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsplatformmacaccessibilitylistsexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/platform/mac/accessibility/lists-expected.txt        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -110,7 +110,7 @@
</span><span class="cx"> AXChildren: &lt;array of size 0&gt;
</span><span class="cx"> AXHelp: 
</span><span class="cx"> AXParent: &lt;AXGroup&gt;
</span><del>-AXSize: NSSize: {784, 54}
</del><ins>+AXSize: NSSize: {784, 72}
</ins><span class="cx"> AXTitle: 
</span><span class="cx"> AXDescription: 
</span><span class="cx"> AXValue: 
</span><span class="lines">@@ -132,36 +132,8 @@
</span><span class="cx"> AXElementBusy: 0
</span><span class="cx"> 
</span><span class="cx"> ------------
</span><del>-AXRole: AXGroup
-AXSubrole: (null)
-AXRoleDescription: group
-AXChildren: &lt;array of size 0&gt;
-AXHelp: 
-AXParent: &lt;AXGroup&gt;
-AXSize: NSSize: {784, 18}
-AXTitle: 
-AXDescription: 
-AXValue: 
-AXFocused: 0
-AXEnabled: 1
-AXWindow: &lt;AXGroup&gt;
-AXSelectedTextMarkerRange: (null)
-AXStartTextMarker: &lt;AXGroup&gt;
-AXEndTextMarker: &lt;AXGroup&gt;
-AXVisited: 0
-AXLinkedUIElements: (null)
-AXSelected: 0
-AXBlockQuoteLevel: 0
-AXTopLevelUIElement: &lt;AXGroup&gt;
-AXLanguage: 
-AXDOMIdentifier: 
-AXDOMClassList: &lt;array of size 0&gt;
-AXTitleUIElement: (null)
-AXElementBusy: 0
</del><span class="cx"> 
</span><del>-------------
</del><span class="cx"> 
</span><del>-
</del><span class="cx"> AXRole: AXGroup
</span><span class="cx"> AXSubrole: (null)
</span><span class="cx"> AXRoleDescription: group
</span></span></pre></div>
<a id="trunkLayoutTestsplatformmacaccessibilityrolesexposedexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/mac/accessibility/roles-exposed-expected.txt (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/accessibility/roles-exposed-expected.txt        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/LayoutTests/platform/mac/accessibility/roles-exposed-expected.txt        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -170,9 +170,9 @@
</span><span class="cx">       AXRoleDescription: heading
</span><span class="cx">       
</span><span class="cx"> PASS: hr
</span><del>-      AXRole: 
-      AXSubrole: 
-      AXRoleDescription: 
</del><ins>+      AXRole: AXSplitter
+      AXSubrole: AXContentSeparator
+      AXRoleDescription: separator
</ins><span class="cx">       
</span><span class="cx"> PASS: i
</span><span class="cx">       AXRole: 
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/ChangeLog        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -1,3 +1,34 @@
</span><ins>+2014-03-24  Chris Fleizach  &lt;cfleizach@apple.com&gt;
+
+        &lt;hr&gt; should expose AXRole/AXSubrole, etc
+        https://bugs.webkit.org/show_bug.cgi?id=109015
+
+        Reviewed by Mario Sanchez Prada.
+
+        Expose the &lt;hr&gt; element to Mac and iOS through the accessibility interface.
+
+        Test: platform/mac/accessibility/hr-element.html
+
+        * English.lproj/Localizable.strings:
+        * accessibility/AccessibilityNodeObject.cpp:
+        (WebCore::AccessibilityNodeObject::isEnabled):
+        * accessibility/AccessibilityObject.cpp:
+        (WebCore::AccessibilityObject::computedRoleString):
+        * accessibility/AccessibilityRenderObject.cpp:
+        (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
+        * accessibility/atk/AccessibilityObjectAtk.cpp:
+        (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
+        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
+        (-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):
+        (-[WebAccessibilityObjectWrapper accessibilityLabel]):
+        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
+        (createAccessibilityRoleMap):
+        (-[WebAccessibilityObjectWrapper subrole]):
+        (-[WebAccessibilityObjectWrapper roleDescription]):
+        * platform/LocalizedStrings.cpp:
+        (WebCore::AXHorizontalRuleDescriptionText):
+        * platform/LocalizedStrings.h:
+
</ins><span class="cx"> 2014-03-24  Antti Koivisto  &lt;antti@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Invalidate sibling text node style when needed instead of attaching synchronously
</span><span class="lines">@@ -3062,7 +3093,6 @@
</span><span class="cx"> 
</span><span class="cx">         * platform/ios/WebSafeGCActivityCallbackIOS.h:
</span><span class="cx"> 
</span><del>-=======
</del><span class="cx"> 2014-03-19  Antti Koivisto  &lt;antti@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Crash with long selector list
</span></span></pre></div>
<a id="trunkSourceWebCoreEnglishlprojLocalizablestrings"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/English.lproj/Localizable.strings (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/English.lproj/Localizable.strings        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/English.lproj/Localizable.strings        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -931,6 +931,9 @@
</span><span class="cx"> /* Verb stating the action that will occur when a radio button is clicked, as used by accessibility */
</span><span class="cx"> &quot;select&quot; = &quot;select&quot;;
</span><span class="cx"> 
</span><ins>+/* accessibility role description for a horizontal rule [&lt;hr&gt;] */
+&quot;separator&quot; = &quot;separator&quot;;
+
</ins><span class="cx"> /* HTTP result code string */
</span><span class="cx"> &quot;server error&quot; = &quot;server error&quot;;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityNodeObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -640,7 +640,10 @@
</span><span class="cx">         if (equalIgnoringCase(disabledStatus, &quot;false&quot;))
</span><span class="cx">             break;
</span><span class="cx">     }
</span><del>-
</del><ins>+    
+    if (roleValue() == HorizontalRuleRole)
+        return false;
+    
</ins><span class="cx">     Node* node = this-&gt;node();
</span><span class="cx">     if (!node || !node-&gt;isElementNode())
</span><span class="cx">         return true;
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityObject.cpp (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityObject.cpp        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/AccessibilityObject.cpp        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -1749,7 +1749,11 @@
</span><span class="cx"> String AccessibilityObject::computedRoleString() const
</span><span class="cx"> {
</span><span class="cx">     // FIXME: Need a few special cases that aren't in the RoleMap: option, etc. http://webkit.org/b/128296
</span><del>-    return reverseAriaRoleMap().get(roleValue());
</del><ins>+    AccessibilityRole role = roleValue();
+    if (role == HorizontalRuleRole)
+        role = SplitterRole;
+    
+    return reverseAriaRoleMap().get(role);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> bool AccessibilityObject::hasHighlighting() const
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityRenderObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -1252,7 +1252,10 @@
</span><span class="cx">     
</span><span class="cx">     if (ariaRoleAttribute() != UnknownRole)
</span><span class="cx">         return false;
</span><del>-
</del><ins>+    
+    if (roleValue() == HorizontalRuleRole)
+        return false;
+    
</ins><span class="cx">     // don't ignore labels, because they serve as TitleUIElements
</span><span class="cx">     Node* node = m_renderer-&gt;node();
</span><span class="cx">     if (node &amp;&amp; isHTMLLabelElement(node))
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityatkAccessibilityObjectAtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/atk/AccessibilityObjectAtk.cpp (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/atk/AccessibilityObjectAtk.cpp        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/atk/AccessibilityObjectAtk.cpp        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -42,9 +42,6 @@
</span><span class="cx">         return DefaultBehavior;
</span><span class="cx"> 
</span><span class="cx">     AccessibilityRole role = roleValue();
</span><del>-    if (role == HorizontalRuleRole)
-        return IncludeObject;
-
</del><span class="cx">     // We expose the slider as a whole but not its value indicator.
</span><span class="cx">     if (role == SliderThumbRole)
</span><span class="cx">         return IgnoreObject;
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityiosWebAccessibilityObjectWrapperIOSmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -44,6 +44,7 @@
</span><span class="cx"> #import &quot;HTMLNames.h&quot;
</span><span class="cx"> #import &quot;IntRect.h&quot;
</span><span class="cx"> #import &quot;IntSize.h&quot;
</span><ins>+#import &quot;LocalizedStrings.h&quot;
</ins><span class="cx"> #import &quot;Page.h&quot;
</span><span class="cx"> #import &quot;Range.h&quot;
</span><span class="cx"> #import &quot;RenderView.h&quot;
</span><span class="lines">@@ -620,6 +621,7 @@
</span><span class="cx">         case ListBoxOptionRole:
</span><span class="cx">         case TabRole:
</span><span class="cx">         case DocumentMathRole:
</span><ins>+        case HorizontalRuleRole:
</ins><span class="cx">             return true;
</span><span class="cx">         case StaticTextRole:
</span><span class="cx">         {
</span><span class="lines">@@ -750,9 +752,11 @@
</span><span class="cx">     NSString *axTitle = [self accessibilityTitle];
</span><span class="cx">     NSString *axDescription = [self accessibilityDescription];
</span><span class="cx">     NSString *landmarkDescription = [self ariaLandmarkRoleDescription];
</span><del>-
</del><ins>+    
</ins><span class="cx">     NSMutableString *result = [NSMutableString string];
</span><del>-
</del><ins>+    if (m_object-&gt;roleValue() == HorizontalRuleRole)
+        appendStringToResult(result, AXHorizontalRuleDescriptionText());
+        
</ins><span class="cx">     appendStringToResult(result, axTitle);
</span><span class="cx">     appendStringToResult(result, axDescription);
</span><span class="cx">     if ([self stringValueShouldBeUsedInLabel]) {
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilitymacWebAccessibilityObjectWrapperMacmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -116,6 +116,10 @@
</span><span class="cx"> #define NSAccessibilityDescriptionListSubrole @&quot;AXDescriptionList&quot;
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><ins>+#ifndef NSAccessibilityContentSeparatorSubrole
+#define NSAccessibilityContentSeparatorSubrole @&quot;AXContentSeparator&quot;
+#endif
+
</ins><span class="cx"> // Miscellaneous
</span><span class="cx"> #ifndef NSAccessibilityBlockQuoteLevelAttribute
</span><span class="cx"> #define NSAccessibilityBlockQuoteLevelAttribute @&quot;AXBlockQuoteLevel&quot;
</span><span class="lines">@@ -1916,7 +1920,8 @@
</span><span class="cx">         { LegendRole, NSAccessibilityGroupRole },
</span><span class="cx">         { MathElementRole, NSAccessibilityGroupRole },
</span><span class="cx">         { AudioRole, NSAccessibilityGroupRole },
</span><del>-        { VideoRole, NSAccessibilityGroupRole }
</del><ins>+        { VideoRole, NSAccessibilityGroupRole },
+        { HorizontalRuleRole, NSAccessibilitySplitterRole }
</ins><span class="cx">     };
</span><span class="cx">     AccessibilityRoleMap&amp; roleMap = *new AccessibilityRoleMap;
</span><span class="cx">     
</span><span class="lines">@@ -1962,6 +1967,9 @@
</span><span class="cx">         }
</span><span class="cx">     }
</span><span class="cx">     
</span><ins>+    if (m_object-&gt;roleValue() == HorizontalRuleRole)
+        return NSAccessibilityContentSeparatorSubrole;
+    
</ins><span class="cx">     if (m_object-&gt;isSpinButtonPart()) {
</span><span class="cx">         if (toAccessibilitySpinButtonPart(m_object)-&gt;isIncrementor())
</span><span class="cx">             return NSAccessibilityIncrementArrowSubrole;
</span><span class="lines">@@ -2155,6 +2163,9 @@
</span><span class="cx">             return AXDescriptionListText();
</span><span class="cx">     }
</span><span class="cx">     
</span><ins>+    if (m_object-&gt;roleValue() == HorizontalRuleRole)
+        return AXHorizontalRuleDescriptionText();
+    
</ins><span class="cx">     // AppKit also returns AXTab for the role description for a tab item.
</span><span class="cx">     if (m_object-&gt;isTabItem())
</span><span class="cx">         return NSAccessibilityRoleDescription(@&quot;AXTab&quot;, nil);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformLocalizedStringscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/LocalizedStrings.cpp (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/LocalizedStrings.cpp        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/platform/LocalizedStrings.cpp        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -700,6 +700,12 @@
</span><span class="cx">         return WEB_UI_STRING(&quot;math&quot;, &quot;An ARIA accessibility group that contains mathematical symbols.&quot;);
</span><span class="cx">     return String();
</span><span class="cx"> }
</span><ins>+
+String AXHorizontalRuleDescriptionText()
+{
+    return WEB_UI_STRING(&quot;separator&quot;, &quot;accessibility role description for a horizontal rule [&lt;hr&gt;]&quot;);
+}
+    
</ins><span class="cx"> #endif // PLATFORM(COCOA)
</span><span class="cx"> 
</span><span class="cx"> String missingPluginText()
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformLocalizedStringsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/LocalizedStrings.h (166174 => 166175)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/LocalizedStrings.h        2014-03-24 16:52:06 UTC (rev 166174)
+++ trunk/Source/WebCore/platform/LocalizedStrings.h        2014-03-24 17:08:00 UTC (rev 166175)
</span><span class="lines">@@ -181,6 +181,7 @@
</span><span class="cx"> #endif
</span><span class="cx"> #if PLATFORM(COCOA)
</span><span class="cx">     String AXARIAContentGroupText(const String&amp; ariaType);
</span><ins>+    String AXHorizontalRuleDescriptionText();
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx">     String missingPluginText();
</span></span></pre>
</div>
</div>

</body>
</html>