1 /*****************************************************************************\ 2 Snes9x - Portable Super Nintendo Entertainment System (TM) emulator. 3 This file is licensed under the Snes9x License. 4 For further information, consult the LICENSE file in the root directory. 5 \*****************************************************************************/ 6 7 /*********************************************************************************** 8 SNES9X for Mac OS (c) Copyright John Stiles 9 10 Snes9x for Mac OS X 11 12 (c) Copyright 2001 - 2011 zones 13 (c) Copyright 2002 - 2005 107 14 (c) Copyright 2002 PB1400c 15 (c) Copyright 2004 Alexander and Sander 16 (c) Copyright 2004 - 2005 Steven Seeger 17 (c) Copyright 2005 Ryan Vogt 18 ***********************************************************************************/ 19 20 21 #ifndef _mac_musicbox_h_ 22 #define _mac_musicbox_h_ 23 24 #define kMBXSoundEmulation 1 25 #define kMBXWholeEmulation 2 26 27 @interface MusicBoxController : NSObject 28 { 29 IBOutlet id window; 30 IBOutlet id gametitle; 31 IBOutlet id disclosure; 32 IBOutlet id rewind; 33 IBOutlet id indicator; 34 IBOutlet id led; 35 36 float mbxClosedHeight, 37 mbxOpenedHeight; 38 39 NSTimer *timer; 40 pthread_t mbxThread; 41 } 42 43 - (id) init; 44 - (void) dealloc; 45 - (void) windowWillClose: (NSNotification *) aNotification; 46 - (NSWindow *) window; 47 - (IBAction) handlePauseButton: (id) sender; 48 - (IBAction) handleRewindButton: (id) sender; 49 - (IBAction) handleEffectButton: (id) sender; 50 - (IBAction) handleChannelButton: (id) sender; 51 - (IBAction) handleDisclosureButton: (id) sender; 52 - (void) updateIndicator: (NSTimer *) aTimer; 53 54 @end 55 56 @interface MusicBoxIndicatorView : NSView 57 { 58 float mbxOffsetX, 59 mbxOffsetY, 60 mbxBarWidth, 61 mbxBarHeight, 62 mbxBarSpace, 63 mbxLRSpace, 64 mbxRightBarX, 65 yyscale; 66 67 float mbxViewWidth, 68 mbxViewHeight, 69 mbxMarginX, 70 mbxMarginY; 71 72 short prevLMax[8], 73 prevRMax[8], 74 prevLVol[8], 75 prevRVol[8]; 76 77 long long barTimeL[8], 78 barTimeR[8]; 79 } 80 81 - (id) initWithFrame: (NSRect) frame; 82 - (void) drawRect: (NSRect) rect; 83 84 @end 85 86 extern volatile Boolean mboxPause; 87 88 void MusicBoxDialog (void); 89 90 #endif 91