зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1775361: Wait for a show event on the imagemap before querying its firstChild r=eeejay
Differential Revision: https://phabricator.services.mozilla.com/D150175
This commit is contained in:
Родитель
a003e72c03
Коммит
08c0e3cd98
|
@ -784,7 +784,13 @@ async function contentSpawnMutation(browser, waitFor, func, args = []) {
|
|||
}
|
||||
|
||||
async function waitForImageMap(browser, accDoc, id = "imgmap") {
|
||||
const acc = findAccessibleChildByID(accDoc, id);
|
||||
let acc = findAccessibleChildByID(accDoc, id);
|
||||
|
||||
if (!acc) {
|
||||
const onShow = waitForEvent(EVENT_SHOW, id);
|
||||
acc = (await onShow).accessible;
|
||||
}
|
||||
|
||||
if (acc.firstChild) {
|
||||
return;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче