Skip to content

Commit

Permalink
Backed out 2 changesets (bug 1624954) for eslint failure on browser_a…
Browse files Browse the repository at this point in the history
…ria_haspopup.js. CLOSED TREE

Backed out changeset 2a3f592412a2 (bug 1624954)
Backed out changeset 74085e028726 (bug 1624954)
  • Loading branch information
ncsoregi committed Apr 30, 2020
1 parent 5636f6c commit 5ca61e2
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 329 deletions.
7 changes: 0 additions & 7 deletions accessible/generic/DocAccessible.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1042,13 +1042,6 @@ void DocAccessible::ARIAAttributeChanged(Accessible* aAccessible,
return;
}

if (aAttribute == nsGkAtoms::aria_haspopup) {
RefPtr<AccEvent> event =
new AccStateChangeEvent(aAccessible, states::HASPOPUP);
FireDelayedEvent(event);
return;
}

if (aAttribute == nsGkAtoms::aria_owns) {
mNotificationController->ScheduleRelocation(aAccessible);
}
Expand Down
8 changes: 2 additions & 6 deletions accessible/mac/mozAccessible.mm
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ - (id)childAt:(uint32_t)i {

static const uint64_t kCachedStates = states::CHECKED | states::PRESSED | states::MIXED |
states::EXPANDED | states::CURRENT | states::SELECTED |
states::TRAVERSED | states::LINKED | states::HASPOPUP;
states::TRAVERSED | states::LINKED;
static const uint64_t kCacheInitialized = ((uint64_t)0x1) << 63;

- (uint64_t)state {
Expand Down Expand Up @@ -344,11 +344,7 @@ - (id)accessibilityAttributeValue:(NSString*)attribute {
if ([attribute isEqualToString:NSAccessibilityEnabledAttribute])
return [NSNumber numberWithBool:[self isEnabled]];
if ([attribute isEqualToString:NSAccessibilityHasPopupAttribute]) {
if ([self stateWithMask:states::HASPOPUP] != 0) {
return utils::GetAccAttr(self, "haspopup");
} else {
return nil;
}
return [NSNumber numberWithBool:[self stateWithMask:states::HASPOPUP] != 0];
}
if ([attribute isEqualToString:NSAccessibilityValueAttribute]) return [self value];
if ([attribute isEqualToString:NSAccessibilityARIACurrentAttribute]) {
Expand Down
1 change: 0 additions & 1 deletion accessible/tests/browser/mac/browser.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,4 @@ support-files =
[browser_selectables.js]
[browser_toggle_radio_check.js]
[browser_link.js]
[browser_aria_haspopup.js]
[browser_required.js]
277 changes: 0 additions & 277 deletions accessible/tests/browser/mac/browser_aria_haspopup.js

This file was deleted.

38 changes: 0 additions & 38 deletions accessible/tests/mochitest/events/test_statechange.html
Original file line number Diff line number Diff line change
Expand Up @@ -137,40 +137,6 @@
await p;
}

async function testHasPopup() {
let p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "true");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "tree");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "menu");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "listbox");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "grid");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, false, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "false");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, true, "popupButton"));
getNode("popupButton").setAttribute("aria-haspopup", "dialog");
await p;

p = waitForEvent(...stateChange(STATE_HASPOPUP, false, false, "popupButton"));
getNode("popupButton").removeAttribute("aria-haspopup");
await p;
}

async function doTests() {
// Test opening details objects
await openNode("detailsOpen", "summaryOpen", true);
Expand Down Expand Up @@ -218,8 +184,6 @@

await testLinked();

await testHasPopup();

SimpleTest.finish();
}

Expand Down Expand Up @@ -311,7 +275,5 @@
<a id="link3">I am a non-link link</a>

<div id="eventdump"></div>

<button id="popupButton">action</button>
</body>
</html>

0 comments on commit 5ca61e2

Please sign in to comment.