Who Owns An Application?
Who Owns An Application?
- Subject: Who Owns An Application?
- From: Luther Fuller <email@hidden>
- Date: Wed, 21 Jun 2006 17:02:44 -0500
I'm going to state this as a general problem, rather than discuss my
particular situation.
Suppose A is an application that owns data, D. Further, another
AppleScripted application, B, is accessing and modifying data D via
A. When B is finished, it quits. Usually, B runs only a few seconds,
but it could run for a few tens of seconds if there is lots of data
to process.
The problem is that B does not own A. Application A has a user
interface and the user can operate A at any time, even while B is
running. The user can quit A or close a window, causing B to error if
its running. I have done this by accident and while I didn't lose any
data, D, I think this is a dangerous situation.
The solution is for application B to acquire total ownership of
application A until B is finished. I don't know of any way to do
this, however.
One possible work-around in B is to
tell application "A" to display dialog ...
This puts a dialog in front of A which prevents the user from
clicking in A ... A just beeps. Unfortunately, (1) the dialog has a
button which the user CAN click and (2) the dialog has a button which
the user MUST click.
Application B could hide application A, then show it when finished,
but this looks really ugly to the user to have windows suddenly
disappear. And the user can go around this by clicking A's Dock icon.
Is there any way for application B to establish exclusive ownership
of application A, excluding all user interaction with A, until
application B is finished, thus protecting data D?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden