Re: How to make an application non-executable?
Re: How to make an application non-executable?
- Subject: Re: How to make an application non-executable?
- From: Bill Cheeseman <email@hidden>
- Date: Sun, 18 Jul 2004 05:36:17 -0400
on 2004-07-18 4:39 AM, Bill Cheeseman at email@hidden wrote:
>
on 2004-07-17 8:30 AM, Brent Gulanowski at email@hidden wrote:
>
>
> But if it's
>
> inside your "setup" app bundle, it should be "invisible" to the Finder
>
> and Launch Services. No? A few tests should suffice to determine
>
> anyway.
>
>
That's the question. Everybody guesses that this is so, but nobody has
>
authoritatively said so. Even an authoritative assertion could be wrong due
>
to bugs. Testing cannot provide a definitive answer because I might overlook
>
a method that does find and launch it inside the "setup" bundle.
Actually, I've just found a situation where this is in fact a problem. It is
limited to AppleScript, but that's what I'm working on.
If an executable application, "Master," is located inside the
Contents/Resources folder of another application package, "Setup," an
AppleScript 'tell' statement addressed to Master will find and launch it
under these circumstances:
1. "Master" is a scriptable application. In my case, it is configured as a
scriptable faceless background application, which is one common form for
scripting additions, loosely speaking.
2. User writes a script that includes a 'tell application "Master"'
statement.
3. User clicks the Compile button in Script Editor.
4. Script Editor can't find Master.app (so far, so good), so it presents a
dialog listing all scriptable applications on the computer and invites the
user to select the right one.
5. Master.app is included in the list. THIS IS THE PROBLEM.
6. User selects Master.app in the list and dismisses the dialog.
7. From now on, when the script is run it launches Master.app -- even though
Master.app is located inside the Resources folder of Setup.app.
Step 5 is a design bug in AppleScript or Script Editor, I believe.
AppleScript in the most recent releases of Mac OS X is supposed to recognize
scripting additions inside application bundles, but only if they are in a
folder named "Scripting Additions" (with a space). I don't know whether this
is supposed to include scripting additions, loosely speaking, in the form of
scriptable faceless background applications, although it probably should.
But I believe the "where is it" dialog presented by Script Editor is wrong
to include an application bundle inside any folder other than a "Scripting
Additions" folder in the list of scriptable applications that can be
selected and executed.
--
Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com
The AppleScript Sourcebook -
http://www.AppleScriptSourcebook.com
Vermont Recipes -
http://www.stepwise.com/Articles/VermontRecipes
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.