зеркало из https://github.com/mozilla/gecko-dev.git
Backed out changeset b27d83c0aa57 (bug 1806356) for causint dt failures in devtools/client/netmonitor/test/browser_net_basic-search.js
This commit is contained in:
Родитель
9904c96a1d
Коммит
41b0aaaaac
|
@ -107,18 +107,7 @@ using namespace mozilla::dom;
|
|||
* Return true if the element must be accessible.
|
||||
*/
|
||||
static bool MustBeAccessible(nsIContent* aContent, DocAccessible* aDocument) {
|
||||
nsIFrame* frame = aContent->GetPrimaryFrame();
|
||||
MOZ_ASSERT(frame);
|
||||
if (frame->IsFocusable()) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// If the frame has been transformed, we should create an accessible so that
|
||||
// we can account for the transform when calculating the Accessible's bounds
|
||||
// using the parent process cache.
|
||||
if (frame->IsTransformed()) {
|
||||
return true;
|
||||
}
|
||||
if (aContent->GetPrimaryFrame()->IsFocusable()) return true;
|
||||
|
||||
if (aContent->IsElement()) {
|
||||
uint32_t attrCount = aContent->AsElement()->GetAttrCount();
|
||||
|
|
|
@ -4,9 +4,6 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
/* import globals from ../../mochitest/role.js */
|
||||
loadScripts({ name: "role.js", dir: MOCHITESTS_DIR });
|
||||
|
||||
// test basic translation
|
||||
addAccessibleTask(
|
||||
`<p id="translate">hello world</p>`,
|
||||
|
@ -117,32 +114,3 @@ addAccessibleTask(
|
|||
},
|
||||
{ topLevel: true, iframe: true, remoteIframe: true }
|
||||
);
|
||||
|
||||
// Verify that a transform forces creation of an accessible.
|
||||
addAccessibleTask(
|
||||
`
|
||||
<div id="div-transform" style="transform:translate(100px,100px);">
|
||||
<p>test</p>
|
||||
</div>
|
||||
|
||||
<div id="div-presentational" role="presentation" style="transform:translate(100px,100px);">
|
||||
<p>test</p>
|
||||
</div>
|
||||
`,
|
||||
async function(browser, docAcc) {
|
||||
const tree = { SECTION: [{ PARAGRAPH: [{ TEXT_LEAF: [] }] }] };
|
||||
|
||||
const divWithTransform = findAccessibleChildByID(docAcc, "div-transform");
|
||||
testAccessibleTree(divWithTransform, tree);
|
||||
await testBoundsWithContent(docAcc, "div-transform", browser);
|
||||
|
||||
// An accessible should still be created, even if the role is "presentation."
|
||||
const divPresentational = findAccessibleChildByID(
|
||||
docAcc,
|
||||
"div-presentational"
|
||||
);
|
||||
testAccessibleTree(divPresentational, tree);
|
||||
await testBoundsWithContent(docAcc, "div-presentational", browser);
|
||||
},
|
||||
{ topLevel: true, iframe: true, remoteIframe: true }
|
||||
);
|
||||
|
|
Загрузка…
Ссылка в новой задаче