Re: Combining event handlers
Re: Combining event handlers
- Subject: Re: Combining event handlers
- From: has <email@hidden>
- Date: Wed, 2 Nov 2005 10:52:31 +0000
Lee Noble wrote:
>I may be wrong but I'm sure I'd seen in the dim and distant past back
>in OS8 that it was possible to combine handlers so you only need one
>block of code instead of two or more.
I think you're imagining it. Standard solution is to put the shared code into its own handler which the other handlers call as appropriate, e.g.:
on run
doStuff(missing value, {})
end run
on adding folder items to actionFolder after receiving actionFiles
doStuff(actionFolder, actionFiles)
end adding folder items to
on doStuff(actionFolder, actionFiles)
...
end doStuff
has
--
http://freespace.virgin.net/hamish.sanderson/
_______________________________________________
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