Bug 1668936 - Return element when calling AXUIElementForTextMarker in entry. r=morgan

Differential Revision: https://phabricator.services.mozilla.com/D92309
This commit is contained in:
Eitan Isaacson 2020-10-06 22:19:11 +00:00
parent 7293c05ee8
commit 10dfa8214c
3 changed files with 15 additions and 19 deletions

View File

@ -513,7 +513,7 @@ Accessible* HyperTextAccessibleWrap::LeafAtOffset(int32_t aOffset) {
}
child = text->GetChildAt(childIdx);
if (!child || nsAccUtils::MustPrune(child)) {
if (!child || nsAccUtils::MustPrune(text)) {
return text;
}

View File

@ -10,10 +10,6 @@ function testRangeAtMarker(macDoc, marker, attribute, expected, msg) {
}
function testUIElement(macDoc, marker, msg, expectedRole, expectedValue) {
if (!expectedRole && !expectedValue) {
todo(false, "Bug 1668936 - AXUIElementForTextMarker returns nil");
return;
}
let elem = macDoc.getParameterizedAttributeValue(
"AXUIElementForTextMarker",
marker

View File

@ -1920,71 +1920,71 @@
lines: ["I deceived you, mom.", "I deceived you, mom.", "I deceived you, mom."],
words: ["I", " "],
element: ["AXStaticText", "I "] },
{ style: "I deceived you, mom.",
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: [" ", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["deceived", " "],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: [" ", "you"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["you", "you"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["deceived you", "deceived you", "deceived you"],
words: ["you", "you"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: "deceived you",
paragraph: "deceived you",
lines: ["I deceived you, mom.", "I deceived you, mom.", "I deceived you, mom."],
words: ["you", "deceived"],
element: [null, null] },
element: ["AXTextField", "deceived you"] },
{ style: ", mom.",
paragraph: "I deceived you, mom.",
lines: ["I deceived you, mom.", "I deceived you, mom.", "I deceived you, mom."],