Commit be0ed51d authored by Olga Sharonova's avatar Olga Sharonova Committed by Commit Bot

Revert "Fix LocalizedLandmarkType for contentinfo aria role and <footer> scoped to body"

This reverts commit 3df4743f.

Reason for revert: suspected root cause of bug 1001496

BUG: 1001496

TBR:rockot@google.com, alevelthal@chromium.org

Original change's description:
> Fix LocalizedLandmarkType for contentinfo aria role and <footer> scoped to body
>
> Change the LocalizedLandmarkType and LocalizedControlType for the
> contentinfo aria role from "content info" to "content information" per
> https://www.w3.org/TR/core-aam-1.1/#role-map-contentinfo.
>
> Also update the LocalizedLandmarkType for <footer> when scoped to the
> body element to "content information", since it inherits this from
> the contentinfo role per https://w3c.github.io/html-aam/#el-footer.
>
> Note that this doesn't affect <footer>'s LocalizedControlType,
> which should be "footer" (but is currently still "content info").
> That is handled in the separate change at
> https://chromium-review.googlesource.com/c/chromium/src/+/1763243.
>
> Bug: 997897
> Change-Id: If958b2090447010f0c0f3839739354dd4a0ea683
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1772228
> Reviewed-by: Aaron Leventhal <aleventhal@chromium.org>
> Reviewed-by: Ken Rockot <rockot@google.com>
> Reviewed-by: Kevin Babbitt <kbabbitt@microsoft.com>
> Commit-Queue: Dan Clark <daniec@microsoft.com>
> Cr-Commit-Position: refs/heads/master@{#693375}

TBR=rockot@google.com,aleventhal@chromium.org,kbabbitt@microsoft.com,daniec@microsoft.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: 997897
Change-Id: I3da07d47fd4cdd502f2ecbfb191293bcfa95ea2a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1789295
Commit-Queue: Olga Sharonova <olka@chromium.org>
Reviewed-by: default avatarOlga Sharonova <olka@chromium.org>
Cr-Commit-Position: refs/heads/master@{#694242}
parent a5a480a2
...@@ -273,7 +273,7 @@ below: ...@@ -273,7 +273,7 @@ below:
checkbox checkbox
</message> </message>
<message name="IDS_AX_ROLE_CONTENT_INFO" desc="Accessibility role description for credits and information about the content of the page, like copyrights and privacy statements"> <message name="IDS_AX_ROLE_CONTENT_INFO" desc="Accessibility role description for credits and information about the content of the page, like copyrights and privacy statements">
content information content info
</message> </message>
<message name="IDS_AX_ROLE_DATE" desc="Accessibility role description for a date input"> <message name="IDS_AX_ROLE_DATE" desc="Accessibility role description for a date input">
date picker date picker
......
...@@ -1860,9 +1860,6 @@ base::string16 BrowserAccessibility::GetLocalizedStringForRoleDescription() ...@@ -1860,9 +1860,6 @@ base::string16 BrowserAccessibility::GetLocalizedStringForRoleDescription()
case ax::mojom::Role::kColorWell: case ax::mojom::Role::kColorWell:
return content_client->GetLocalizedString(IDS_AX_ROLE_COLOR_WELL); return content_client->GetLocalizedString(IDS_AX_ROLE_COLOR_WELL);
case ax::mojom::Role::kContentInfo:
return content_client->GetLocalizedString(IDS_AX_ROLE_CONTENT_INFO);
case ax::mojom::Role::kDate: case ax::mojom::Role::kDate:
return content_client->GetLocalizedString(IDS_AX_ROLE_DATE); return content_client->GetLocalizedString(IDS_AX_ROLE_DATE);
......
...@@ -676,7 +676,7 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest, ...@@ -676,7 +676,7 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest,
TestLocalizedLandmarkType(1, ax::mojom::Role::kComplementary, "aside", TestLocalizedLandmarkType(1, ax::mojom::Role::kComplementary, "aside",
base::ASCIIToUTF16("complementary")); base::ASCIIToUTF16("complementary"));
TestLocalizedLandmarkType(2, ax::mojom::Role::kFooter, "footer", TestLocalizedLandmarkType(2, ax::mojom::Role::kFooter, "footer",
base::ASCIIToUTF16("content information")); base::ASCIIToUTF16("content info"));
TestLocalizedLandmarkType(3, ax::mojom::Role::kForm, "form"); TestLocalizedLandmarkType(3, ax::mojom::Role::kForm, "form");
TestLocalizedLandmarkType(4, ax::mojom::Role::kMain, "main"); TestLocalizedLandmarkType(4, ax::mojom::Role::kMain, "main");
TestLocalizedLandmarkType(5, ax::mojom::Role::kNavigation, "nav"); TestLocalizedLandmarkType(5, ax::mojom::Role::kNavigation, "nav");
...@@ -689,7 +689,7 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest, ...@@ -689,7 +689,7 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest,
TestLocalizedLandmarkType(9, ax::mojom::Role::kComplementary, "complementary", TestLocalizedLandmarkType(9, ax::mojom::Role::kComplementary, "complementary",
base::ASCIIToUTF16("complementary")); base::ASCIIToUTF16("complementary"));
TestLocalizedLandmarkType(10, ax::mojom::Role::kContentInfo, "contentinfo", TestLocalizedLandmarkType(10, ax::mojom::Role::kContentInfo, "contentinfo",
base::ASCIIToUTF16("content information")); base::ASCIIToUTF16("content info"));
TestLocalizedLandmarkType(11, ax::mojom::Role::kForm, "role_form"); TestLocalizedLandmarkType(11, ax::mojom::Role::kForm, "role_form");
TestLocalizedLandmarkType(12, ax::mojom::Role::kMain, "role_main"); TestLocalizedLandmarkType(12, ax::mojom::Role::kMain, "role_main");
TestLocalizedLandmarkType(13, ax::mojom::Role::kNavigation, "role_nav"); TestLocalizedLandmarkType(13, ax::mojom::Role::kNavigation, "role_nav");
...@@ -720,15 +720,14 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest, ...@@ -720,15 +720,14 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest,
"<input type='week'>" "<input type='week'>"
"<meter></meter>" "<meter></meter>"
"<output></output>" "<output></output>"
"<time></time>" "<time></time>");
"<div role='contentinfo' aria-label='contentinfo'></div>");
NavigateToURL(shell(), url); NavigateToURL(shell(), url);
waiter.WaitForNotification(); waiter.WaitForNotification();
BrowserAccessibility* root = GetManager()->GetRoot(); BrowserAccessibility* root = GetManager()->GetRoot();
ASSERT_NE(nullptr, root); ASSERT_NE(nullptr, root);
ASSERT_EQ(16u, root->PlatformChildCount()); ASSERT_EQ(15u, root->PlatformChildCount());
auto TestLocalizedRoleDescription = auto TestLocalizedRoleDescription =
[root](int child_index, [root](int child_index,
...@@ -757,7 +756,6 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest, ...@@ -757,7 +756,6 @@ IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest,
TestLocalizedRoleDescription(12, base::ASCIIToUTF16("meter")); TestLocalizedRoleDescription(12, base::ASCIIToUTF16("meter"));
TestLocalizedRoleDescription(13, base::ASCIIToUTF16("output")); TestLocalizedRoleDescription(13, base::ASCIIToUTF16("output"));
TestLocalizedRoleDescription(14, base::ASCIIToUTF16("time")); TestLocalizedRoleDescription(14, base::ASCIIToUTF16("time"));
TestLocalizedRoleDescription(15, base::ASCIIToUTF16("content information"));
} }
IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest, IN_PROC_BROWSER_TEST_F(CrossPlatformAccessibilityBrowserTest,
......
android.webkit.WebView focusable focused scrollable android.webkit.WebView focusable focused scrollable
++android.view.View role_description='content information' name='This is ARIA role contentinfo.' ++android.view.View role_description='content info' name='This is ARIA role contentinfo.'
\ No newline at end of file \ No newline at end of file
document
++contentinfo LocalizedControlType='content information' LocalizedLandmarkType='content information'
++++description Name='This is ARIA role contentinfo.'
ROLE_SYSTEM_DOCUMENT READONLY FOCUSABLE ROLE_SYSTEM_DOCUMENT READONLY FOCUSABLE
++IA2_ROLE_LANDMARK xml-roles:contentinfo localized_extended_role='content information' ++IA2_ROLE_LANDMARK xml-roles:contentinfo
++++ROLE_SYSTEM_STATICTEXT name='This is ARIA role contentinfo.' ++++ROLE_SYSTEM_STATICTEXT name='This is ARIA role contentinfo.'
\ No newline at end of file
...@@ -2,9 +2,6 @@ ...@@ -2,9 +2,6 @@
@MAC-ALLOW:AXRole=* @MAC-ALLOW:AXRole=*
@MAC-ALLOW:AXSubrole=* @MAC-ALLOW:AXSubrole=*
@MAC-ALLOW:AXRoleDescription=* @MAC-ALLOW:AXRoleDescription=*
@UIA-WIN-ALLOW:LocalizedControlType='content information'
@UIA-WIN-ALLOW:LocalizedLandmarkType='content information'
@WIN-ALLOW:localized_extended_role='content information'
@WIN-ALLOW:xml-roles:* @WIN-ALLOW:xml-roles:*
@AURALINUX-ALLOW:xml-roles:* @AURALINUX-ALLOW:xml-roles:*
--> -->
......
document document
++contentinfo LocalizedLandmarkType='content information' ++contentinfo
++++description Name='Footer element' ++++description Name='Footer element'
<!-- <!--
@MAC-ALLOW:AXRole* @MAC-ALLOW:AXRole*
@MAC-ALLOW:AXSubrole* @MAC-ALLOW:AXSubrole*
@UIA-WIN-ALLOW:LocalizedLandmarkType='content information'
@WIN-ALLOW:xml-roles:* @WIN-ALLOW:xml-roles:*
@AURALINUX-ALLOW:xml-roles:* @AURALINUX-ALLOW:xml-roles:*
--> -->
......
...@@ -9,7 +9,7 @@ android.webkit.WebView focusable focused scrollable ...@@ -9,7 +9,7 @@ android.webkit.WebView focusable focused scrollable
++android.view.View role_description='application' name='This is an ARIA application landmark.' ++android.view.View role_description='application' name='This is an ARIA application landmark.'
++android.view.View role_description='banner' name='This is an ARIA banner landmark.' ++android.view.View role_description='banner' name='This is an ARIA banner landmark.'
++android.view.View role_description='complementary' name='This is an ARIA complementary landmark.' ++android.view.View role_description='complementary' name='This is an ARIA complementary landmark.'
++android.view.View role_description='content information' name='This is an ARIA contentinfo landmark.' ++android.view.View role_description='content info' name='This is an ARIA contentinfo landmark.'
++android.view.View name='This is an ARIA form landmark.' ++android.view.View name='This is an ARIA form landmark.'
++android.view.View role_description='main' name='This is an ARIA main landmark.' ++android.view.View role_description='main' name='This is an ARIA main landmark.'
++android.view.View role_description='navigation' name='This is an ARIA navigation landmark.' ++android.view.View role_description='navigation' name='This is an ARIA navigation landmark.'
......
...@@ -587,9 +587,6 @@ base::string16 TestAXNodeWrapper::GetLocalizedStringForRoleDescription() const { ...@@ -587,9 +587,6 @@ base::string16 TestAXNodeWrapper::GetLocalizedStringForRoleDescription() const {
case ax::mojom::Role::kColorWell: case ax::mojom::Role::kColorWell:
return base::ASCIIToUTF16("color picker"); return base::ASCIIToUTF16("color picker");
case ax::mojom::Role::kContentInfo:
return base::ASCIIToUTF16("content information");
case ax::mojom::Role::kDate: case ax::mojom::Role::kDate:
return base::ASCIIToUTF16("date picker"); return base::ASCIIToUTF16("date picker");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment