• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Using NSApplescript while keeping UI responsive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using NSApplescript while keeping UI responsive


  • Subject: Re: Using NSApplescript while keeping UI responsive
  • From: Nathan Day <email@hidden>
  • Date: Thu, 29 Jul 2004 17:24:09 +1000

I have a class on my web site called NDAppleScriptObject which can be called from a sepereate thread. The trickiest part about executing scripts from anything other than the main thread is if you get any user interaction like display dialog, the dialog is displayed but you can not use it. osascript isn't a solution because it does not allow any user interaction. With NDAppleScriptObject you can intercept every AppleEvent sent and then forward it into the main thread.

On Wednesday, July 28, 2004, at 04:58AM, Edison Thomaz <email@hidden> wrote:

>Hi all,
>
>I've been playing with NSApplescript and for the most part it works really
>well. The problem is that with scripts that take a while to execute, my
>whole UI is essentially frozen. The obvious answer to that would be to do
>all the NSApplescript work on another thread, but NSApplescript is not
>thread-safe (part of AppKit). Is there any way to solve this dilemma?
>
>Thanks!
>
>Edison Thomaz
>_______________________________________________
>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.
>
>
>


Nathan Day
email@hidden
http://homepage.mac.com/nathan_day/
_______________________________________________
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.


References: 
 >Using NSApplescript while keeping UI responsive (From: Edison Thomaz <email@hidden>)

  • Prev by Date: Re: Bound UI elements not showing 'description' as expected
  • Next by Date: _lmFlags.ignoresAntialiasThreshold in NSLayoutManager
  • Previous by thread: Re: Using NSApplescript while keeping UI responsive
  • Next by thread: windowDidLoad
  • Index(es):
    • Date
    • Thread