Preserve author-specified reference order in AtkRelationSet

BrowserAccessibility::GetTargetNodesForRelation was converting the
correctly-ordered vector of AxIds into a set, causing the target order
to be based on when the accessible object was created. This order does
not necessarily correspond to the position in the accessibility tree,
let alone to the author-provided order.

This situation wasn't problematic because of the few ARIA properties
whose value is an ID reference list, none were likely being used for
assistive technology navigation. Because aria-details is changing to
support multiple targets for which ATs will be expected to provide
navigation, we need to start preserving the author-specified reference
order.

There are only a few properties for which there are multiple targets,
and the list of referenced IDs for those properties is expected to be
quite small. Thus converting the vector to a set doesn't buy us much.
Therefore, return the target nodes as a vector, checking for duplicate
AxIds.

Bug: 1047988
Change-Id: I8352a073b71cc1863cbd25326d0cd48a4abd3d2f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2034690
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Commit-Queue: Joanmarie Diggs <jdiggs@igalia.com>
Cr-Commit-Position: refs/heads/master@{#738216}
7 files changed