Making Cocoa Application Scriptable
Making Cocoa Application Scriptable
- Subject: Making Cocoa Application Scriptable
- From: Andrei Tchijov <email@hidden>
- Date: Sat, 19 Aug 2006 07:55:13 -0400
Hi,
I think I am missing something very important, but I can not see
what. I am trying to make my application AppleScript Scriptable. I
was under impression that once you created proper *.scriptSuite and
*.scriptTerminology you should be able to see it in your app
dictionary in Script Editor. I can not. Below are MyApp.scriptSuite/
scriptTerminology. I reduced it to single class NSApplication with
single attribute and it still does not work. Can someone please take
a look and tell me what am I doing wrong:
You help will be highly appreciated,
Andrei Tchijov
P.S. I do have <key>NSAppleScriptEnabled</key><string>YES</string> in
my plist and MyApp.scriptSuite/scriptTerminology are get copied into
Contents/Resources folder inside my app.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://
www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Name</key>
<string>MyApp</string>
<key>AppleEventCode</key>
<string>avpn</string>
<key>Classes</key>
<dict>
<key>NSApplication</key>
<dict>
<key>AppleEventCode</key>
<string>capp</string>
<key>Superclass</key>
<string>NSCoreSuite.NSApplication</string>
<key>Attributes</key>
<dict>
<key>oneAttribute</key>
<dict>
<key>AppleEventCode</key>
<string>aone</string>
<key>Type</key>
<string>NSString</string>
</dict>
</dict>
</dict>
</dict>
</dict>
</plist>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://
www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Name</key>
<string>MyApp</string>
<key>Description</key>
<string>MyApp Scripting Suite</string>
<key>Classes</key>
<dict>
<key>NSApplication</key>
<dict>
<key>Name</key>
<string>application</string>
<key>PluralName</key>
<string>applications</string>
<key>Description</key>
<string>Top Applicaiton</string>
<key>Attributes</key>
<dict>
<key>oneAttribute</key>
<dict>
<key>Name</key>
<string>oneAttribute</string>
<key>Description</key>
<string>one attribute</string>
</dict>
</dict>
</dict>
</dict>
</dict>
</plist>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden