зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1385372 - Allow same id in aria-owns. r=surkov
This commit is contained in:
Родитель
419b26dee6
Коммит
b6d69628bd
|
@ -2108,6 +2108,10 @@ DocAccessible::DoARIAOwnsRelocation(Accessible* aOwner)
|
|||
"candidate", child, nullptr);
|
||||
#endif
|
||||
|
||||
if (owned->IndexOf(child) < idx) {
|
||||
continue; // ignore second entry of same ID
|
||||
}
|
||||
|
||||
// Same child on same position, no change.
|
||||
if (child->Parent() == aOwner) {
|
||||
int32_t indexInParent = child->IndexInParent();
|
||||
|
@ -2138,10 +2142,6 @@ DocAccessible::DoARIAOwnsRelocation(Accessible* aOwner)
|
|||
|
||||
MOZ_ASSERT(owned->SafeElementAt(idx) != child, "Already in place!");
|
||||
|
||||
if (owned->IndexOf(child) < idx) {
|
||||
continue; // ignore second entry of same ID
|
||||
}
|
||||
|
||||
// A new child is found, check for loops.
|
||||
if (child->Parent() != aOwner) {
|
||||
// Child is aria-owned by another container, skip.
|
||||
|
|
Загрузка…
Ссылка в новой задаче