Re: [NSSound isPlaying] fails to indicate sound termination in Lion
Re: [NSSound isPlaying] fails to indicate sound termination in Lion
- Subject: Re: [NSSound isPlaying] fails to indicate sound termination in Lion
- From: Jay Reynolds Freeman <email@hidden>
- Date: Sun, 22 Jul 2012 18:43:23 -0700
What Ken, Fritz and Kyle are saying makes sense, but flies a little bit in the face of what "asynchronous" often means. (I won't quibble if Apple is doing it their own way, they often do.) It also doesn't explain why the same linked executable behaves one way under Snow Leopard and another way under Lion, and the documentation for [NSSound isPlaying] is written in a way that suggests the caller of that method is talking directly to the receiver (an instance of NSSound), not a message center somewhere; there is no hint that it cannot be used anywhere.)
I appreciate the advice and will play some more, but I would be obliged if someone at Apple would be willing to comment on what is going on (not clear if Ken, Kyle, or Fritz are Apple folks), and if anyone has any pointers to Apple documentation about what "asynchronous" means to them, I would be obliged.
Since my app has nothing to do while waiting for the sound to play, a polling loop on "isPlaying" is actually a good deal less code (only two lines) than setting up a delegate with "-sound:didFinishPlaying" implemented.
-- Jay Reynolds Freeman
---------------------
email@hidden
http://JayReynoldsFreeman.com (personal web site)
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden