Scenario: I have an open app, I click its icon in the dock.
Is there a way of making it do something each time I click?
ie is there a method that notifies that the app has been clicked?
Thanks
PS I tried
on applicationDidBecomeActive_(aNotification)
log "here I am active"
applicationWillFinishLaunching_(me) -- this is where my code executes. (it all worked fine when I used to quit at the end of this)
end applicationDidBecomeActive_
also, in a regular applescript app, you can add a on reopen handler, so that every time you double click it will go to the reopen handler while the app is still running.