Unique ID for elements
Unique ID for elements
- Subject: Unique ID for elements
- From: "Ian Archer" <email@hidden>
- Date: Fri, 10 Nov 2006 11:12:49 -0500
I want to maintain some state about UI elements that are accessed.
One problem I'm facing is that there does not seem to be a way to
refer to an element by some globally (or even application-specific)
ID.
Let's say I'm monitoring the focused widget and I want to keep state
about when the last time that widget was focused. The simplest way to
do this would be to maintain a dictionary mapping the ID of the widget
to a time stamp. However, the absence of an ID makes this impossible!
I thought about creating an ID for an element based its path from the
root element, but I don't know that it's a safe assumption that this
path won't change over the course of a process's life span. Another
approach would be to compare each item in the time stamp dictionary
for equality using CFEqual, but this is an O(n) approach.
Is there a way to get a unique ID from an AXUIElementRef?
If not, is it something that would be feasible given the way in which
accessibility is implemented? If this is the case, would this
functionality be worth submitting a bug report for?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Accessibility-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden