X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;ds=sidebyside;f=macosx%2FController.h;h=f9634abe901bbb999b1217008b1f76341fea89a7;hb=4b72a63eb61a01275493c4bfb51ba02152d1c5e1;hp=744fe111e853177911187f7efaed97b32ab911a3;hpb=1a96a49ae60a0a6532d6f631f912f15e5f3614d7;p=handbrake-jp%2Fhandbrake-jp-git.git
diff --git a/macosx/Controller.h b/macosx/Controller.h
index 744fe111..f9634abe 100644
--- a/macosx/Controller.h
+++ b/macosx/Controller.h
@@ -1,85 +1,131 @@
/* $Id: Controller.h,v 1.35 2005/08/01 14:29:50 titer Exp $
This file is part of the HandBrake source code.
- Homepage: .
+ Homepage: .
It may be used under the terms of the GNU General Public License. */
-#include
-#include
+#import
+#import
#include "hb.h"
+#import "ChapterTitles.h"
+#import "HBSubtitles.h"
+#import "PictureController.h"
+#import "HBPreviewController.h"
+#import "HBQueueController.h"
+#import "HBAdvancedController.h"
+#import "HBPreferencesController.h"
+#import "HBPresets.h"
+#import "HBAudioController.h"
+
+extern NSString *HBContainerChangedNotification;
+extern NSString *keyContainerTag;
+extern NSString *HBTitleChangedNotification;
+extern NSString *keyTitleTag;
-#include "ChapterTitles.h"
-#include "ScanController.h"
-#include "PictureController.h"
-#include "QueueController.h"
-#import "MVMenuButton.h"
@class HBOutputPanelController;
-@interface HBController : NSObject
+/* We subclass NSView so that our drags show both the icon as well as PresetName columns */
+@interface HBPresetsOutlineView : NSOutlineView
+{
+BOOL fIsDragging;
+
+}
+@end
+
+@interface HBController : NSObject
{
+ NSImage * fApplicationIcon;
IBOutlet NSWindow * fWindow;
-
- /* Scan panel */
- IBOutlet ScanController * fScanController;
- IBOutlet NSPanel * fScanPanel;
-
- /* Picture panel */
- IBOutlet PictureController * fPictureController;
- IBOutlet NSPanel * fPicturePanel;
-
+
+ /* Main Menu Outlets */
+ NSMenuItem * fOpenSourceTitleMMenu;
+
+ /* Source Title Scan Outlets */
+ IBOutlet NSPanel * fScanSrcTitlePanel;
+ IBOutlet NSTextField * fScanSrcTitlePathField;
+ IBOutlet NSTextField * fSrcDsplyNameTitleScan;
+ IBOutlet NSTextField * fScanSrcTitleNumField;
+ IBOutlet NSButton * fScanSrcTitleCancelButton;
+ IBOutlet NSButton * fScanSrcTitleOpenButton;
+
+
+ /* Picture Settings */
+ PictureController * fPictureController;
+
+ /* Picture Preview */
+ PreviewController * fPreviewController;
+
+ /* Advanced options tab */
+ HBAdvancedController * fAdvancedOptions;
+ IBOutlet NSBox * fAdvancedView;
+
+ HBPreferencesController * fPreferencesController;
+
/* Queue panel */
- IBOutlet QueueController * fQueueController;
- IBOutlet NSPanel * fQueuePanel;
+ HBQueueController * fQueueController;
IBOutlet NSTextField * fQueueStatus;
-
- /* Menu Items */
- /* File Menu */
- IBOutlet NSMenu * fMenuBarFileMenu;
- IBOutlet NSMenuItem * fMenuOpenSource;
- IBOutlet NSMenuItem * fMenuAddToQueue;
- IBOutlet NSMenuItem * fMenuStartEncode;
- IBOutlet NSMenuItem * fMenuPauseEncode;
- /* Window Menu */
- IBOutlet NSMenu * fMenuBarWindowMenu;
- IBOutlet NSMenuItem * fMenuPresetsDrawerToggle;
- IBOutlet NSMenuItem * fMenuQueuePanelShow;
- IBOutlet NSMenuItem * fMenuPicturePanelShow;
- IBOutlet NSMenuItem * fMenuActivityWindowShow;
+
+ /* Output panel */
+ HBOutputPanelController *outputPanel;
/* Source box */
IBOutlet NSProgressIndicator * fScanIndicator;
NSString * sourceDisplayName;
- IBOutlet NSTextField * fScanStatus;
- IBOutlet NSTextField * fSrcDVD1Field;
IBOutlet NSTextField * fSrcDVD2Field;
IBOutlet NSTextField * fSrcTitleField;
IBOutlet NSPopUpButton * fSrcTitlePopUp;
+
+
+ /* lib dvd nav specific */
+ IBOutlet NSTextField * fSrcAngleLabel;
+ IBOutlet NSPopUpButton * fSrcAnglePopUp;
+
+ /* Source start and end points */
+ IBOutlet NSPopUpButton * fEncodeStartStopPopUp;
+ /* pts based start / stop */
+ IBOutlet NSTextField * fSrcTimeStartEncodingField;
+ IBOutlet NSTextField * fSrcTimeEndEncodingField;
+ /* frame based based start / stop */
+ IBOutlet NSTextField * fSrcFrameStartEncodingField;
+ IBOutlet NSTextField * fSrcFrameEndEncodingField;
+
IBOutlet NSTextField * fSrcChapterField;
IBOutlet NSPopUpButton * fSrcChapterStartPopUp;
IBOutlet NSTextField * fSrcChapterToField;
IBOutlet NSPopUpButton * fSrcChapterEndPopUp;
+
+ /* Source duration information */
IBOutlet NSTextField * fSrcDuration1Field;
IBOutlet NSTextField * fSrcDuration2Field;
/* Destination box */
IBOutlet NSTextField * fDstFormatField;
IBOutlet NSPopUpButton * fDstFormatPopUp;
- IBOutlet NSButton * fDstMpgLargeFileCheck;
- IBOutlet NSTextField * fDstCodecsField;
- IBOutlet NSPopUpButton * fDstCodecsPopUp;
+
IBOutlet NSTextField * fDstFile1Field;
IBOutlet NSTextField * fDstFile2Field;
IBOutlet NSButton * fDstBrowseButton;
+ /* MP4 Options */
+ // Creates 64 bit mp4's that allow file sizes over 4gb
+ IBOutlet NSButton * fDstMp4LargeFileCheck;
+ // Optimizes mp4's for http
+ IBOutlet NSButton * fDstMp4HttpOptFileCheck;
+ // Creates iPod compatible mp4's (add ipod uuid atom)
+ IBOutlet NSButton * fDstMp4iPodFileCheck;
/* Video box */
+ IBOutlet NSButton * fFrameratePfrCheck;
+
IBOutlet NSTextField * fVidRateField;
IBOutlet NSPopUpButton * fVidRatePopUp;
IBOutlet NSTextField * fVidEncoderField;
IBOutlet NSPopUpButton * fVidEncoderPopUp;
IBOutlet NSTextField * fVidQualityField;
+ IBOutlet NSTextField * fVidQualityRFLabel;
+ IBOutlet NSTextField * fVidQualityRFField;
IBOutlet NSMatrix * fVidQualityMatrix;
IBOutlet NSButtonCell * fVidTargetCell;
IBOutlet NSTextField * fVidTargetSizeField;
@@ -87,44 +133,17 @@
IBOutlet NSTextField * fVidBitrateField;
IBOutlet NSButtonCell * fVidConstantCell;
IBOutlet NSSlider * fVidQualitySlider;
- IBOutlet NSButton * fVidGrayscaleCheck;
IBOutlet NSButton * fVidTwoPassCheck;
IBOutlet NSButton * fVidTurboPassCheck;
- /* Picture Settings box */
- IBOutlet NSTextField * fPicLabelSettings;
- IBOutlet NSTextField * fPicLabelSrc;
- IBOutlet NSTextField * fPicLabelOutp;
- IBOutlet NSTextField * fPicLabelAr;
- IBOutlet NSTextField * fPicLabelDeinter;
- IBOutlet NSTextField * fPicLabelSrcX;
- IBOutlet NSTextField * fPicLabelOutputX;
+ /* Status read out fileds for picture sizing */
+ IBOutlet NSTextField * fPictureSizeField;
+ IBOutlet NSTextField * fPictureCroppingField;
+
+ /* Status read out fileds for video filters */
+ IBOutlet NSTextField * fVideoFiltersField;
- IBOutlet NSTextField * fPicSrcWidth;
- IBOutlet NSTextField * fPicSrcHeight;
- IBOutlet NSTextField * fPicSettingWidth;
- IBOutlet NSTextField * fPicSettingHeight;
- IBOutlet NSTextField * fPicSettingARkeep;
- IBOutlet NSTextField * fPicSettingPAR;
- IBOutlet NSTextField * fPicSettingDeinterlace;
- IBOutlet NSTextField * fPicSettingDeinterlaceDsply;
- IBOutlet NSTextField * fPicSettingARkeepDsply;
- IBOutlet NSTextField * fPicSettingPARDsply;
- IBOutlet NSTextField * fPicSettingAutoCropLabel;
- IBOutlet NSTextField * fPicSettingAutoCrop;
- IBOutlet NSTextField * fPicSettingAutoCropDsply;
- IBOutlet NSTextField * fPicSettingDetelecine;
- IBOutlet NSTextField * fPicSettingDetelecineLabel;
- IBOutlet NSTextField * fPicSettingDenoise;
- IBOutlet NSTextField * fPicSettingDenoiseDsply;
- IBOutlet NSTextField * fPicSettingDenoiseLabel;
-
- IBOutlet NSTextField * fPicLabelAnamorphic;
- IBOutlet NSTextField * fPicLabelPAROutp;
- IBOutlet NSTextField * fPicLabelPAROutputX;
- IBOutlet NSTextField * fPicSettingPARWidth;
- IBOutlet NSTextField * fPicSettingPARHeight;
- /* Picture variables */
+ /* Picture variables */
int PicOrigOutputWidth;
int PicOrigOutputHeight;
int AutoCropTop;
@@ -135,86 +154,45 @@
IBOutlet NSTextField * fSubField;
IBOutlet NSPopUpButton * fSubPopUp;
IBOutlet NSButton * fSubForcedCheck;
-
- /* Audio box */
- IBOutlet NSTextField * fAudLang1Field;
- IBOutlet NSPopUpButton * fAudLang1PopUp;
- IBOutlet NSTextField * fAudLang2Field;
- IBOutlet NSPopUpButton * fAudLang2PopUp;
- /* New Audio Mix PopUps */
- IBOutlet NSTextField * fAudTrack1MixLabel;
- IBOutlet NSPopUpButton * fAudTrack1MixPopUp;
- IBOutlet NSTextField * fAudTrack2MixLabel;
- IBOutlet NSPopUpButton * fAudTrack2MixPopUp;
-
- IBOutlet NSTextField * fAudRateField;
- IBOutlet NSPopUpButton * fAudRatePopUp;
- IBOutlet NSTextField * fAudBitrateField;
- IBOutlet NSPopUpButton * fAudBitratePopUp;
+
+ IBOutlet NSTableView * fSubtitlesTable;
+ HBSubtitles * fSubtitlesDelegate;
+ IBOutlet NSButton * fBrowseSrtFileButton;
+
+ /* New Audio box */
+ IBOutlet HBAudioController * fAudioDelegate;
+
/* Chapters box */
IBOutlet NSButton * fCreateChapterMarkers;
IBOutlet NSTableView * fChapterTable;
- ChapterTitles * fChapterTitlesDelegate;
+ IBOutlet NSButton * fLoadChaptersButton;
+ IBOutlet NSButton * fSaveChaptersButton;
+ IBOutlet NSTableColumn * fChapterTableNameColumn;
+ ChapterTitles * fChapterTitlesDelegate;
/* Bottom */
- IBOutlet NSButton * fPictureButton;
IBOutlet NSTextField * fStatusField;
IBOutlet NSProgressIndicator * fRipIndicator;
- IBOutlet NSButton * fShowQuButton;
- IBOutlet NSButton * fAddToQuButton;
- IBOutlet NSButton * fPauseButton;
- IBOutlet NSButton * fRipButton;
-
- /* Advanced Tab for opts fX264optView*/
- IBOutlet NSView * fX264optView;
- IBOutlet NSTextField * fX264optViewTitleLabel;
- IBOutlet NSTextField * fDisplayX264OptionsLabel;
- IBOutlet NSTextField * fDisplayX264Options;
- IBOutlet NSTextField * fX264optBframesLabel;
- IBOutlet NSPopUpButton * fX264optBframesPopUp;
- IBOutlet NSTextField * fX264optRefLabel;
- IBOutlet NSPopUpButton * fX264optRefPopUp;
- IBOutlet NSTextField * fX264optNfpskipLabel;
- IBOutlet NSButton * fX264optNfpskipSwitch;
- IBOutlet NSTextField * fX264optNodctdcmtLabel;
- IBOutlet NSButton * fX264optNodctdcmtSwitch;
- IBOutlet NSTextField * fX264optSubmeLabel;
- IBOutlet NSPopUpButton * fX264optSubmePopUp;
- IBOutlet NSTextField * fX264optTrellisLabel;
- IBOutlet NSPopUpButton * fX264optTrellisPopUp;
- IBOutlet NSTextField * fX264optMixedRefsLabel;
- IBOutlet NSButton * fX264optMixedRefsSwitch;
- IBOutlet NSTextField * fX264optMotionEstLabel;
- IBOutlet NSPopUpButton * fX264optMotionEstPopUp;
- IBOutlet NSTextField * fX264optMERangeLabel;
- IBOutlet NSPopUpButton * fX264optMERangePopUp;
- IBOutlet NSTextField * fX264optWeightBLabel;
- IBOutlet NSButton * fX264optWeightBSwitch;
- IBOutlet NSTextField * fX264optBRDOLabel;
- IBOutlet NSButton * fX264optBRDOSwitch;
- IBOutlet NSTextField * fX264optBPyramidLabel;
- IBOutlet NSButton * fX264optBPyramidSwitch;
- IBOutlet NSTextField * fX264optBiMELabel;
- IBOutlet NSButton * fX264optBiMESwitch;
- IBOutlet NSTextField * fX264optDirectPredLabel;
- IBOutlet NSPopUpButton * fX264optDirectPredPopUp;
- IBOutlet NSTextField * fX264optDeblockLabel;
- IBOutlet NSPopUpButton * fX264optAlphaDeblockPopUp;
- IBOutlet NSPopUpButton * fX264optBetaDeblockPopUp;
- IBOutlet NSTextField * fX264optAnalyseLabel;
- IBOutlet NSPopUpButton * fX264optAnalysePopUp;
- IBOutlet NSTextField * fX264opt8x8dctLabel;
- IBOutlet NSButton * fX264opt8x8dctSwitch;
- IBOutlet NSTextField * fX264optCabacLabel;
- IBOutlet NSButton * fX264optCabacSwitch;
+ BOOL fRipIndicatorShown;
+
+ /* Queue File variables */
+ NSString * QueueFile;
+ NSMutableArray * QueueFileArray;
+ int currentQueueEncodeIndex; // Used to track the currently encoding queueu item
/* User Preset variables here */
-
+ HBPresets * fPresetsBuiltin;
IBOutlet NSDrawer * fPresetDrawer;
IBOutlet NSTextField * fPresetNewName;
IBOutlet NSTextField * fPresetNewDesc;
IBOutlet NSPopUpButton * fPresetNewPicSettingsPopUp;
+ IBOutlet NSTextField * fPresetNewPicWidth;
+ IBOutlet NSTextField * fPresetNewPicHeight;
+ IBOutlet NSBox * fPresetNewPicWidthHeightBox;
+
+ IBOutlet NSButton * fPresetNewPicFiltersCheck;
+ IBOutlet NSButton * fPresetNewFolderCheck;
IBOutlet NSTextField * fPresetSelectedDisplay;
NSString * AppSupportDirectory;
@@ -224,151 +202,223 @@
NSMutableDictionary * chosenPreset;
int curUserPresetChosenNum;
- int presetHbDefault; // this is 1 in "Default" preset key
- int presetUserDefault;// this is 2 in "Default" preset key
+ NSMutableDictionary *presetHbDefault; // this is 1 in "Default" preset key
+ NSMutableDictionary *presetUserDefault;// this is 2 in "Default" preset key
+ NSMutableDictionary *presetUserDefaultParent;
+ NSMutableDictionary *presetUserDefaultParentParent;
+ int presetCurrentBuiltInCount; // keeps track of the current number of built in presets
IBOutlet NSPanel * fAddPresetPanel;
- IBOutlet NSTableView * tableView;
- IBOutlet NSButton * fPresetsAdd;
- IBOutlet NSButton * fPresetsDelete;
- IBOutlet MVMenuButton * fPresetsActionButton;
- IBOutlet NSMenu * fPresetsActionMenu;
+ /* NSOutline View for the presets */
+ NSArray *fDraggedNodes;
+ IBOutlet HBPresetsOutlineView * fPresetsOutlineView;
+ IBOutlet NSButton * fPresetsAdd;
+ IBOutlet NSButton * fPresetsDelete;
+ IBOutlet NSPopUpButton * fPresetsActionButton;
+
hb_handle_t * fHandle;
+
+ /* Queue variables */
+ int hbInstanceNum; //stores the number of HandBrake instances currently running
+ hb_handle_t * fQueueEncodeLibhb; // libhb for HB Encoding
hb_title_t * fTitle;
+ hb_title_t * fQueueEncodeTitle;
+ int fEncodingQueueItem; // corresponds to the index of fJobGroups encoding item
+ int fPendingCount; // Number of various kinds of job groups in fJobGroups.
+ int fCompletedCount;
+ int fCanceledCount;
+ int fWorkingCount;
+
+ int fqueueEditRescanItemNum; // queue array item to be reloaded into the main window
+ int pidNum; // The pid number for this instance
+ NSString * currentQueueEncodeNameString;
+
/* integer to set to determine the previous state
of encode 0==idle, 1==encoding, 2==cancelled*/
int fEncodeState;
int currentScanCount;
int currentSuccessfulScanCount;
+ BOOL SuccessfulScan;
+ BOOL applyQueueToScan;
NSString * currentSource;
- HBOutputPanelController *outputPanel;
-
- BOOL startButtonEnabled;
- BOOL pauseButtonEnabled;
- BOOL AddToQueueButtonEnabled;
- BOOL stopOrStart;
- BOOL resumeOrPause;
+ NSString * browsedSourceDisplayName;
+
+ double dockIconProgress;
+ BOOL hasValidPresetSelected;
}
+- (int) getPidnum;
+- (IBAction) showAboutPanel:(id)sender;
+
+- (void) writeToActivityLog:(const char *) format, ...;
+- (IBAction) browseSources: (id) sender;
+- (void) browseSourcesDone: (NSOpenPanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+- (IBAction) showSourceTitleScanPanel: (id) sender;
+- (IBAction) closeSourceTitleScanPanel: (id) sender;
+- (void) performScan:(NSString *) scanPath scanTitleNum: (int) scanTitleNum;
+- (IBAction) showNewScan: (id) sender;
+
+
+- (IBAction) cancelScanning:(id)sender;
+
+- (void) updateUI: (NSTimer *) timer;
+- (void) enableUI: (bool) enable;
+- (IBAction) encodeStartStopPopUpChanged: (id) sender;
+- (IBAction) titlePopUpChanged: (id) sender;
+- (IBAction) chapterPopUpChanged: (id) sender;
+- (IBAction) startEndSecValueChanged: (id) sender;
+- (IBAction) startEndFrameValueChanged: (id) sender;
+
-- (void) TranslateStrings;
+- (IBAction) formatPopUpChanged: (id) sender;
+- (IBAction) videoEncoderPopUpChanged: (id) sender;
+- (IBAction) autoSetM4vExtension: (id) sender;
+- (IBAction) twoPassCheckboxChanged: (id) sender;
+- (IBAction) videoFrameRateChanged: (id) sender;
+- (void) prepareJob;
+- (IBAction) browseFile: (id) sender;
+- (void) browseFileDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
-- (void) UpdateUI: (NSTimer *) timer;
-- (void) EnableUI: (bool) enable;
-- (IBAction) ShowNewScan: (id) sender;
-- (IBAction) ShowScanPanel: (id) sender;
+- (IBAction) videoMatrixChanged: (id) sender;
-- (IBAction) TitlePopUpChanged: (id) sender;
-- (IBAction) ChapterPopUpChanged: (id) sender;
+- (IBAction) qualitySliderChanged: (id) sender;
+- (void) setupQualitySlider;
-- (IBAction) FormatPopUpChanged: (id) sender;
-- (IBAction) CodecsPopUpChanged: (id) sender;
-- (IBAction) EncoderPopUpChanged: (id) sender;
-- (IBAction) TwoPassCheckboxChanged: (id) sender;
-- (IBAction ) VideoFrameRateChanged: (id) sender;
-- (IBAction) SetEnabledStateOfAudioMixdownControls: (id) sender;
-- (IBAction) AddAllAudioTracksToPopUp: (id) sender;
-- (IBAction) SelectAudioTrackInPopUp: (id) sender searchPrefixString: (NSString *) searchPrefixString selectIndexIfNotFound: (int) selectIndexIfNotFound;
-- (IBAction) AudioTrackPopUpChanged: (id) sender;
-- (IBAction) AudioTrackPopUpChanged: (id) sender mixdownToUse: (int) mixdownToUse;
-- (IBAction) AudioTrackMixdownChanged: (id) sender;
-- (IBAction) SubtitleSelectionChanged: (id) sender;
+- (IBAction) browseImportSrtFile: (id) sender;
+- (void) browseImportSrtFileDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
-- (IBAction) BrowseFile: (id) sender;
-- (void) BrowseFileDone: (NSSavePanel *) sheet
- returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+- (IBAction) showPicturePanel: (id) sender;
+- (void) picturePanelFullScreen;
+- (void) picturePanelWindowed;
+- (IBAction) showPreviewWindow: (id) sender;
+- (void)pictureSettingsDidChange;
+- (IBAction) calculatePictureSizing: (id) sender;
+- (IBAction) openMainWindow: (id) sender;
-- (IBAction) VideoMatrixChanged: (id) sender;
-- (IBAction) QualitySliderChanged: (id) sender;
+/* Queue File Stuff */
+- (void) loadQueueFile;
+- (NSDictionary *)createQueueFileItem;
+- (void)saveQueueFileItem;
+- (void) incrementQueueItemDone:(int) queueItemDoneIndexNum;
+- (void) performNewQueueScan:(NSString *) scanPath scanTitleNum: (int) scanTitleNum;
+- (void) processNewQueueEncode;
+- (void) clearQueueEncodedItems;
+/* Queue Editing */
+- (IBAction)applyQueueSettingsToMainWindow:(id)sender;
+- (IBAction)rescanQueueItemToMainWindow:(NSString *) scanPath scanTitleNum: (int) scanTitleNum selectedQueueItem: (int) selectedQueueItem;
-- (IBAction) ShowPicturePanel: (id) sender;
-- (IBAction) CalculatePictureSizing: (id) sender;
-- (IBAction) OpenMainWindow: (id) sender;
-- (IBAction) AddToQueue: (id) sender;
-- (IBAction) ShowQueuePanel: (id) sender;
+- (void) removeQueueFileItem:(int) queueItemToRemove;
+- (void) clearQueueAllItems;
+- (void)moveObjectsInQueueArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex;
+- (void)getQueueStats;
+- (void)setQueueEncodingItemsAsPending;
+- (IBAction) addToQueue: (id) sender;
+- (void) overwriteAddToQueueAlertDone: (NSWindow *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+- (void) doAddToQueue;
+
+- (IBAction) showQueueWindow:(id)sender;
+
+- (IBAction)showPreferencesWindow:(id)sender;
- (IBAction) Rip: (id) sender;
-- (void) OverwriteAlertDone: (NSWindow *) sheet
- returnCode: (int) returnCode contextInfo: (void *) contextInfo;
-- (void) UpdateAlertDone: (NSWindow *) sheet
- returnCode: (int) returnCode contextInfo: (void *) contextInfo;
-- (void) _Rip;
+- (void) overWriteAlertDone: (NSWindow *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+- (void) doRip;
+
- (IBAction) Cancel: (id) sender;
-- (void) _Cancel: (NSWindow *) sheet returnCode: (int) returnCode
- contextInfo: (void *) contextInfo;
+- (void) doCancelCurrentJob;
+- (void) doCancelCurrentJobAndStop;
- (IBAction) Pause: (id) sender;
-- (IBAction) CalculateBitrate: (id) sender;
-- (void) controlTextDidBeginEditing: (NSNotification *) notification;
-- (void) controlTextDidEndEditing: (NSNotification *) notification;
+- (IBAction) calculateBitrate: (id) sender;
- (void) controlTextDidChange: (NSNotification *) notification;
-- (IBAction) OpenHomepage: (id) sender;
-- (IBAction) OpenForums: (id) sender;
-- (IBAction) OpenUserGuide: (id) sender;
-
-// x264 Advanced Panel Methods
-- (IBAction) X264AdvancedOptionsSet: (id) sender;
-- (IBAction) X264AdvancedOptionsStandardizeOptString: (id) sender;
-- (IBAction) X264AdvancedOptionsSetCurrentSettings: (id) sender;
-- (NSString *) X264AdvancedOptionsStandardizeOptNames:(NSString *) cleanOptNameString;
-- (IBAction) X264AdvancedOptionsChanged: (id) sender;
+- (IBAction) openHomepage: (id) sender;
+- (IBAction) openForums: (id) sender;
+- (IBAction) openUserGuide: (id) sender;
// Preset Methods Here
+
+/* These are required by the NSOutlineView Datasource Delegate */
+/* We use this to deterimine children of an item */
+- (id)outlineView:(NSOutlineView *)fPresetsOutlineView child:(NSInteger)index ofItem:(id)item;
+/* We use this to determine if an item should be expandable */
+- (BOOL)outlineView:(NSOutlineView *)fPresetsOutlineView isItemExpandable:(id)item;
+/* used to specify the number of levels to show for each item */
+- (int)outlineView:(NSOutlineView *)fPresetsOutlineView numberOfChildrenOfItem:(id)item;
+/* Used to tell the outline view which information is to be displayed per item */
+- (id)outlineView:(NSOutlineView *)fPresetsOutlineView objectValueForTableColumn:(NSTableColumn *)tableColumn byItem:(id)item;
+/* Use to customize the font and display characteristics of the title cell */
+- (void)outlineView:(NSOutlineView *)fPresetsOutlineView willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)tableColumn item:(id)item;
+/* We use this to edit the name field in the outline view */
+- (void)outlineView:(NSOutlineView *)fPresetsOutlineView setObjectValue:(id)object forTableColumn:(NSTableColumn *)tableColumn byItem:(id)item;
+/* We use this to provide tooltips for the items in the presets outline view */
+- (NSString *)outlineView:(NSOutlineView *)fPresetsOutlineView toolTipForCell:(NSCell *)cell rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)tc item:(id)item mouseLocation:(NSPoint)mouseLocation;
+- (void) checkBuiltInsForUpdates;
+/* We use this to actually select the preset and act accordingly */
+- (IBAction)selectPreset:(id)sender;
+
+/* Export / Import Presets */
+- (IBAction) browseExportPresetFile: (id) sender;
+- (void) browseExportPresetFileDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+
+- (IBAction) browseImportPresetFile: (id) sender;
+- (void) browseImportPresetDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+
+/* Manage User presets */
- (void) loadPresets;
-- (IBAction) CustomSettingUsed: (id) sender;
-- (IBAction) ShowAddPresetPanel: (id) sender;
-- (IBAction) CloseAddPresetPanel: (id) sender;
-- (NSDictionary *)CreatePreset;
-- (NSDictionary *)CreateIpodLowPreset;
-- (NSDictionary *)CreateIpodHighPreset;
-- (NSDictionary *)CreateAppleTVPreset;
-- (NSDictionary *)CreatePSThreePreset;
-- (NSDictionary *)CreatePSPPreset;
-- (NSDictionary *)CreateNormalPreset;
-- (NSDictionary *)CreateClassicPreset;
-- (NSDictionary *)CreateQuickTimePreset;
-- (NSDictionary *)CreateFilmPreset;
-- (NSDictionary *)CreateTelevisionPreset;
-- (NSDictionary *)CreateAnimationPreset;
-- (NSDictionary *)CreateBedlamPreset;
-- (NSDictionary *)CreateiPhonePreset;
-- (NSDictionary *)CreateDeuxSixQuatrePreset;
-- (NSDictionary *)CreateBrokePreset;
-- (NSDictionary *)CreateBlindPreset;
-- (NSDictionary *)CreateCRFPreset;
-
-- (IBAction) RevertPictureSizeToMax:(id)sender;
-
-- (IBAction)SetDefaultPreset:(id)sender;
-- (IBAction)SelectDefaultPreset:(id)sender;
+- (IBAction) customSettingUsed: (id) sender;
+- (IBAction) showAddPresetPanel: (id) sender;
+- (IBAction) addPresetPicDropdownChanged: (id) sender;
+- (IBAction) closeAddPresetPanel: (id) sender;
+- (NSDictionary *)createPreset;
+
+- (IBAction) revertPictureSizeToMax:(id)sender;
+
+- (IBAction)setDefaultPreset:(id)sender;
+- (IBAction)selectDefaultPreset:(id)sender;
- (void) savePreset;
-- (IBAction)AddFactoryPresets:(id)sender;
-- (IBAction)DeleteFactoryPresets:(id)sender;
-- (IBAction)AddUserPreset:(id)sender;
-- (void)AddPreset;
-- (IBAction)InsertPreset:(id)sender;
-- (IBAction)DeletePreset:(id)sender;
-- (IBAction)GetDefaultPresets:(id)sender;
-- (IBAction)tableViewSelected:(id)sender;
-// NSTableDataSource methods
-- (int)numberOfRowsInTableView:(NSTableView *)aTableView;
-- (id)tableView:(NSTableView *)aTableView
- objectValueForTableColumn:(NSTableColumn *)aTableColumn
- row:(int)rowIndex;
-- (void)tableView:(NSTableView *)aTableView
- setObjectValue:(id)anObject
- forTableColumn:(NSTableColumn *)aTableColumn
- row:(int)rowIndex;
-// To determine user presets cell display properties
-- (void)tableView:(NSTableView *)aTableView
- willDisplayCell:(id)aCell forTableColumn:(NSTableColumn *)aTableColumn
- row:(int)rowIndex;
+- (void)sortPresets;
+- (IBAction)addFactoryPresets:(id)sender;
+- (IBAction)deleteFactoryPresets:(id)sender;
+- (IBAction)addUserPreset:(id)sender;
+- (void)addPreset;
+- (IBAction)insertPreset:(id)sender;
+- (IBAction)deletePreset:(id)sender;
+- (IBAction)getDefaultPresets:(id)sender;
+-(void)sendToMetaX:(NSString *) filePath;
// Growl methods
- (NSDictionary *) registrationDictionaryForGrowl;
--(IBAction)showGrowlDoneNotification:(id)sender;
+-(void)showGrowlDoneNotification:(NSString *) filePath;
- (IBAction)showDebugOutputPanel:(id)sender;
- (void)setupToolbar;
+
+- (void) prepareJobForPreview;
+- (void) remindUserOfSleepOrShutdown;
+
+- (void)moveObjectsInPresetsArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex;
+
+- (int) hbInstances;
+
+// Chapter files methods
+- (IBAction) browseForChapterFile: (id) sender;
+- (void) browseForChapterFileDone: (NSOpenPanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+
+- (IBAction) browseForChapterFileSave: (id) sender;
+- (void) browseForChapterFileSaveDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo;
+
++ (unsigned int) maximumNumberOfAllowedAudioTracks;
+@property (nonatomic, assign) BOOL hasValidPresetSelected;
+- (IBAction) addAllAudioTracks: (id) sender;
+
@end