Re: using accessibilty API to move Finder windows - works, but last position not saved.
Re: using accessibilty API to move Finder windows - works, but last position not saved.
- Subject: Re: using accessibilty API to move Finder windows - works, but last position not saved.
- From: Bill Cheeseman <email@hidden>
- Date: Sun, 29 Oct 2006 04:13:52 -0400
- Thread-topic: using accessibilty API to move Finder windows - works, but last position not saved.
on 2006-10-29 3:59 AM, Clayton John at email@hidden wrote:
> Now - when I do the example above, but I resize that window using the
> accessibility API, then the size isn't saved! This is annoying some
> of my users, who expect that size and position to be recorded by the
> Finder, just as if they had resized the window in the normal way.
Yes, I see what you mean. It works that way here, too, using my UI Browser
product. I was initially tempted to say that this is because the
accessibility API considers a window to be "destroyed" when it is closed.
However, despite this, a closed Finder window remembers the status of its
toolbar (on/off) when it is "reopened," even if the toolbar button was
"clicked" using the accessibility API (I didn't test whether this is also
true when changing the icon view via the accessibility API).
So, apparently, the failure to remember its size is a Finder accessibility
bug, since manually resizing a Finder window is remembered when it is
"reopened."
I'm copying this message to the accessibility mailing list, because Apple
accessibility engineers lurk there. If you have access to Apple's bug
reporter, you should report this.
> Also - most Cocoa apps have an easy life, because the developer can
> simply type a name into the 'Auto Save Name' text field of a window
> in interface builder and viola, position saved - that's what you are
> referrring to in the last paragraph I think. Hmmmm... that gives me
> an idea, I wonder where that stuff gets written to? Maybe Finder is
> holding that per-path in a database somewhere? This is the kinda
> information I'd be looking to dig into I guess, in order to solve this.
Autosave name window position, size, etc., are generally saved in the
application's own preferences file.
> Other issues are coming to mind, like 'what if I *do* find this, and
> Finder is modifying the information at the same time?' But I'll
> cross that bridge when I come to it i think, presumably the Carbon
> API to work with the Finder DB's is well aware of this issue.
You'll certainly need to consider issues like this.
--
Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com
PreFab Software - http://www.prefab.com/scripting.html
The AppleScript Sourcebook - http://www.AppleScriptSourcebook.com
Vermont Recipes - http://www.stepwise.com/Articles/VermontRecipes
_______________________________________________
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