// // MGMSound.h // SoundNote // // Created by Mr. Gecko on 9/23/10. // Copyright (c) 2011 Mr. Gecko's Media (James Coleman). All rights reserved. http://mrgeckosmedia.com/ // #if TARGET_OS_IPHONE #import #import #else #import #endif @class MGMSound; @protocol MGMSoundDelegate - (void)soundDidFinishPlaying:(MGMSound *)theSound; @end @protocol NSSoundDelegate; @interface MGMSound : NSObject #if TARGET_OS_IPHONE #else #endif { #if TARGET_OS_IPHONE AVAudioPlayer *sound; #else NSSound *sound; #endif id delegate; BOOL loops; } - (id)initWithContentsOfFile:(NSString *)theFile; - (id)initWithContentsOfURL:(NSURL *)theURL; - (id)initWithData:(NSData *)theData; - (void)setDelegate:(id)theDelegate; - (id)delegate; - (void)setLoops:(BOOL)shouldLoop; - (BOOL)loops; - (void)play; - (void)pause; - (void)stop; - (BOOL)isPlaying; @end