diff --git a/HandBrakeBatch.xcodeproj/project.pbxproj b/HandBrakeBatch.xcodeproj/project.pbxproj index 6d052f5..638e913 100644 --- a/HandBrakeBatch.xcodeproj/project.pbxproj +++ b/HandBrakeBatch.xcodeproj/project.pbxproj @@ -32,11 +32,12 @@ 0EEC804A1369B4EA00D05124 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 0EEC80481369B4EA00D05124 /* InfoPlist.strings */; }; 0EEC804D1369B4EA00D05124 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 0EEC804C1369B4EA00D05124 /* main.m */; }; 0EEC80531369B4EA00D05124 /* HandBrakeBatchAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 0EEC80521369B4EA00D05124 /* HandBrakeBatchAppDelegate.m */; }; - 0EEC80561369B4EA00D05124 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0EEC80541369B4EA00D05124 /* MainMenu.xib */; }; 0EF72315136CFCE100D223F4 /* gpl-3.0.txt in Resources */ = {isa = PBXBuildFile; fileRef = 0EF72314136CFCE100D223F4 /* gpl-3.0.txt */; }; 0EF8EF95136CFEB700884AE8 /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = 0EF8EF93136CFEB700884AE8 /* Credits.rtf */; }; 0EF8EFB1136D981000884AE8 /* Sparkle.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0EF8EFB0136D981000884AE8 /* Sparkle.framework */; }; 0EF8EFB6136D9D2200884AE8 /* Sparkle.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = 0EF8EFB0136D981000884AE8 /* Sparkle.framework */; }; + 4117F47616B40BED0091DCAD /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4117F47516B40BED0091DCAD /* MainMenu.xib */; }; + 4117F47916B411140091DCAD /* HBBAppFunctions.m in Sources */ = {isa = PBXBuildFile; fileRef = 4117F47816B411140091DCAD /* HBBAppFunctions.m */; }; /* End PBXBuildFile section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -106,10 +107,12 @@ 0EEC804C1369B4EA00D05124 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 0EEC80511369B4EA00D05124 /* HandBrakeBatchAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HandBrakeBatchAppDelegate.h; sourceTree = ""; }; 0EEC80521369B4EA00D05124 /* HandBrakeBatchAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = HandBrakeBatchAppDelegate.m; sourceTree = ""; }; - 0EEC80551369B4EA00D05124 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainMenu.xib; sourceTree = ""; }; 0EF72314136CFCE100D223F4 /* gpl-3.0.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "gpl-3.0.txt"; sourceTree = ""; }; 0EF8EF94136CFEB700884AE8 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = en; path = en.lproj/Credits.rtf; sourceTree = ""; }; 0EF8EFB0136D981000884AE8 /* Sparkle.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Sparkle.framework; sourceTree = ""; }; + 4117F47516B40BED0091DCAD /* MainMenu.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MainMenu.xib; sourceTree = ""; }; + 4117F47716B411130091DCAD /* HBBAppFunctions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBBAppFunctions.h; sourceTree = ""; }; + 4117F47816B411140091DCAD /* HBBAppFunctions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBBAppFunctions.m; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -158,7 +161,7 @@ 0E549260136C49BD0094563F /* xib */ = { isa = PBXGroup; children = ( - 0EEC80541369B4EA00D05124 /* MainMenu.xib */, + 4117F47516B40BED0091DCAD /* MainMenu.xib */, 0E18546A136C4222004B5558 /* HBBProgressWindow.xib */, 0E987E2013E4062C00A99716 /* Preferences.xib */, ); @@ -227,6 +230,8 @@ 0E108B6A136C47F200168057 /* HBBProgressController.m */, 0E933F9B14C47C8000A5BB1D /* HBBVideoScan.h */, 0E933F9C14C47C8000A5BB1D /* HBBVideoScan.m */, + 4117F47716B411130091DCAD /* HBBAppFunctions.h */, + 4117F47816B411140091DCAD /* HBBAppFunctions.m */, 0E549260136C49BD0094563F /* xib */, 0EEC80461369B4EA00D05124 /* Supporting Files */, ); @@ -304,7 +309,6 @@ buildActionMask = 2147483647; files = ( 0EEC804A1369B4EA00D05124 /* InfoPlist.strings in Resources */, - 0EEC80561369B4EA00D05124 /* MainMenu.xib in Resources */, 0E18546B136C4222004B5558 /* HBBProgressWindow.xib in Resources */, 0E9B490A136C874000FCDC68 /* Icon.icns in Resources */, 0EF72315136CFCE100D223F4 /* gpl-3.0.txt in Resources */, @@ -315,6 +319,7 @@ 0E6C285C14C288BC004A0FE5 /* iso639-2.db in Resources */, 0EE562F215BFFD8F0054359B /* HandBrakeCLI in Resources */, 0EC6D60415C002F70016775D /* manicure.rb in Resources */, + 4117F47616B40BED0091DCAD /* MainMenu.xib in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -335,6 +340,7 @@ 0E933F9D14C47C8000A5BB1D /* HBBVideoScan.m in Sources */, 0E337A4715144FCC006150DD /* RSRTVArrayController.m in Sources */, 0EB54A4C1596CDBC00EE2AB4 /* HBBDropView.m in Sources */, + 4117F47916B411140091DCAD /* HBBAppFunctions.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -349,14 +355,6 @@ name = InfoPlist.strings; sourceTree = ""; }; - 0EEC80541369B4EA00D05124 /* MainMenu.xib */ = { - isa = PBXVariantGroup; - children = ( - 0EEC80551369B4EA00D05124 /* en */, - ); - name = MainMenu.xib; - sourceTree = ""; - }; 0EF8EF93136CFEB700884AE8 /* Credits.rtf */ = { isa = PBXVariantGroup; children = ( @@ -419,6 +417,7 @@ buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ENABLE_OBJC_ARC = NO; + CODE_SIGN_IDENTITY = "iPhone Developer: Matt Maher (XF6YX54VVW)"; COMBINE_HIDPI_IMAGES = YES; COPY_PHASE_STRIP = NO; FRAMEWORK_SEARCH_PATHS = ( @@ -433,6 +432,7 @@ INFOPLIST_FILE = "HandBrakeBatch/HandBrakeBatch-Info.plist"; MACOSX_DEPLOYMENT_TARGET = 10.7; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE = ""; SDKROOT = macosx; WRAPPER_EXTENSION = app; }; diff --git a/HandBrakeBatch.xcodeproj/project.xcworkspace/xcuserdata/bladnman.xcuserdatad/UserInterfaceState.xcuserstate b/HandBrakeBatch.xcodeproj/project.xcworkspace/xcuserdata/bladnman.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..d18e7a3 Binary files /dev/null and b/HandBrakeBatch.xcodeproj/project.xcworkspace/xcuserdata/bladnman.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcdebugger/Breakpoints.xcbkptlist b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcdebugger/Breakpoints.xcbkptlist new file mode 100644 index 0000000..5227871 --- /dev/null +++ b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcdebugger/Breakpoints.xcbkptlist @@ -0,0 +1,14 @@ + + + + + + + diff --git a/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/HandBrakeBatch.xcscheme b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/HandBrakeBatch.xcscheme new file mode 100644 index 0000000..1db9c36 --- /dev/null +++ b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/HandBrakeBatch.xcscheme @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/xcschememanagement.plist b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..7bdb6a8 --- /dev/null +++ b/HandBrakeBatch.xcodeproj/xcuserdata/bladnman.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,22 @@ + + + + + SchemeUserState + + HandBrakeBatch.xcscheme + + orderHint + 0 + + + SuppressBuildableAutocreation + + 0EEC803A1369B4EA00D05124 + + primary + + + + + diff --git a/HandBrakeBatch/HBBAppFunctions.h b/HandBrakeBatch/HBBAppFunctions.h new file mode 100644 index 0000000..8f56389 --- /dev/null +++ b/HandBrakeBatch/HBBAppFunctions.h @@ -0,0 +1,28 @@ +// +// HBBAppFunctions.h +// HandBrakeBatch +// +// Created by Matt Maher on 1/26/13. +// +// + +#import + +@interface HBBAppFunctions : NSObject + + +// SEND TO APP ++ (NSString *) getSendToAppPath; ++ (void) setSendToAppPath:(NSString *)path; ++ (NSString *) getSendToAppName; ++ (NSImage *) getIconForSendToApp; ++ (void) setSendToAppName:(NSString *)name; ++ (BOOL) isSendToAppValid; ++ (void) clearAllSendToAppPreferences; ++ (void) openFileWithSendToApp:(NSString *) filePath; + + +// MMStringFunctions (partials) ++ (NSString *) fRightBackOf:(NSString *)substring inString:(NSString *)inString; ++ (BOOL) string:(NSString *)inString contains:(NSString *)substring; +@end diff --git a/HandBrakeBatch/HBBAppFunctions.m b/HandBrakeBatch/HBBAppFunctions.m new file mode 100644 index 0000000..7654ba1 --- /dev/null +++ b/HandBrakeBatch/HBBAppFunctions.m @@ -0,0 +1,99 @@ +// +// HBBAppFunctions.m +// HandBrakeBatch +// +// Created by Matt Maher on 1/26/13. +// +// + +#import "HBBAppFunctions.h" + +@implementation HBBAppFunctions + + + + + + +// --++-- --++-- --++-- --++-- --++-- --++-- +#pragma mark - +#pragma mark SEND TO APP (after conversion) +#pragma mark - +static NSString *PREF_SEND_FILE_TO_APP_PATH = @"HBBSendConvertedFileToAppPath"; +static NSString *PREF_SEND_FILE_TO_APP_NAME = @"HBBSendConvertedFileToAppName"; ++ (NSString *) getSendToAppPath { + return [[NSUserDefaults standardUserDefaults] objectForKey:PREF_SEND_FILE_TO_APP_PATH]; +} ++ (void) setSendToAppPath:(NSString *)path { + NSString *filePath = [path stringByReplacingOccurrencesOfString:@"file://localhost" withString:@""]; + filePath = [filePath stringByReplacingPercentEscapesUsingEncoding:NSStringEncodingConversionAllowLossy]; + [[NSUserDefaults standardUserDefaults] setObject:filePath forKey:PREF_SEND_FILE_TO_APP_PATH]; +} ++ (NSString *) getSendToAppName { + return [[NSUserDefaults standardUserDefaults] valueForKey:PREF_SEND_FILE_TO_APP_NAME]; +} ++ (void) setSendToAppName:(NSString *)name { + NSString *appName = [name stringByReplacingOccurrencesOfString: @".app" withString:@""]; + [[NSUserDefaults standardUserDefaults] setValue:appName forKey:PREF_SEND_FILE_TO_APP_NAME]; +} ++ (NSImage *) getIconForSendToApp { + if ([self isSendToAppValid]) { + return [[NSWorkspace sharedWorkspace] iconForFile:[self getSendToAppPath]]; + } + + return nil; +} ++ (BOOL) isSendToAppValid { + NSString *appPath = [self getSendToAppPath]; + + if ( ! appPath) { + return NO; + } + + NSURL *theURL = [NSURL fileURLWithPath:appPath isDirectory:NO]; + return ([theURL checkResourceIsReachableAndReturnError:nil] == YES); +} ++ (void) clearAllSendToAppPreferences { + [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREF_SEND_FILE_TO_APP_NAME]; + [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREF_SEND_FILE_TO_APP_PATH]; + [[NSUserDefaults standardUserDefaults] synchronize]; +} ++ (void) openFileWithSendToApp:(NSString *) filePath { + if ([self isSendToAppValid]) { + NSURL *fileURL = [NSURL fileURLWithPath: filePath]; + NSWorkspace * ws = [NSWorkspace sharedWorkspace]; + [ws openFile:[fileURL path] withApplication:[self getSendToAppPath]]; + } +} + + + +// --++-- --++-- --++-- --++-- --++-- --++-- +#pragma mark - +#pragma mark MMStringFunctions +#pragma mark - + ++ (NSString *) fRightBackOf:(NSString *)substring inString:(NSString *)inString { + if(inString == nil || substring == nil || [inString length] < 1 || [substring length] < 1) { + return @""; + } + + NSArray *parts = [inString componentsSeparatedByString:substring]; + + // does it exist? + if([parts count] < 1) { + return @""; + } + + return [parts objectAtIndex:([parts count] - 1)]; +} ++ (BOOL) string:(NSString *)inString contains:(NSString *)substring { + if(substring == nil || inString == nil || [substring length] < 1 || [inString length] < 1) { + return NO; + } + + NSRange range = [inString rangeOfString:substring]; + return range.location != NSNotFound; +} + +@end diff --git a/HandBrakeBatch/HBBProgressController.m b/HandBrakeBatch/HBBProgressController.m index 55540eb..b0465e8 100644 --- a/HandBrakeBatch/HBBProgressController.m +++ b/HandBrakeBatch/HBBProgressController.m @@ -13,6 +13,7 @@ #import "HBBProgressController.h" #import "HBBPresets.h" #import "HBBLangData.h" +#import "HBBAppFunctions.h" #define FILES_OK 0 #define FILE_EXISTS 1 @@ -396,6 +397,11 @@ -(void) taskCompleted:(NSNotification *)notification { [[NSFileManager defaultManager] moveItemAtURL:[[currentQueue objectAtIndex:0] tempOutputURL] toURL:[[currentQueue objectAtIndex:0] outputURL] error:nil]; [processedQueue addObject:[currentQueue objectAtIndex:0]]; + + // M.Maher 2013-01-26 + // hook to send file to external application after conversion + [self sendConvertedFileToExternalAppIfNeeded:[currentQueue objectAtIndex:0]]; + } else { // Conversion failed! Write log file and do not delete source [stdErrData writeToURL:[NSURL fileURLWithPath:logFilePath] atomically:NO]; @@ -493,7 +499,11 @@ -(void) taskCompleted:(NSNotification *)notification { [self prepareTask]; [backgroundTask launch]; } - +- (void) sendConvertedFileToExternalAppIfNeeded:(HBBInputFile *)inputFile { + if ([HBBAppFunctions isSendToAppValid]) { + [HBBAppFunctions openFileWithSendToApp:[inputFile outputPath]]; + } +} - (void) getData: (NSNotification *)aNotification { NSData *data = [[aNotification userInfo] objectForKey:NSFileHandleNotificationDataItem]; diff --git a/HandBrakeBatch/HandBrakeBatchAppDelegate.h b/HandBrakeBatch/HandBrakeBatchAppDelegate.h index c59c2cf..7eefb4f 100644 --- a/HandBrakeBatch/HandBrakeBatchAppDelegate.h +++ b/HandBrakeBatch/HandBrakeBatchAppDelegate.h @@ -35,7 +35,11 @@ IBOutlet NSButton *chooseOutputFolder; + IBOutlet NSButton *sendFileToCheckbox; + + IBOutlet NSImageView *sendToIconImage; NSString *appSupportFolder; + NSButton *chooseSendToApplication; } @property (assign) IBOutlet NSWindow *window; @@ -47,6 +51,8 @@ - (IBAction)presetSelected:(id)sender; - (IBAction)showPreferences:(id)sender; - (IBAction)donate:(id)sender; +- (IBAction)chooseSendToApplication:(id)sender; +- (IBAction)sendToApplicationClicked:(id)sender; -(void)processFiles:(NSURL *)url; diff --git a/HandBrakeBatch/HandBrakeBatchAppDelegate.m b/HandBrakeBatch/HandBrakeBatchAppDelegate.m index 9947b53..8d0b5d4 100644 --- a/HandBrakeBatch/HandBrakeBatchAppDelegate.m +++ b/HandBrakeBatch/HandBrakeBatchAppDelegate.m @@ -13,14 +13,16 @@ #import "HBBProgressController.h" #import "HBBPresets.h" #import "HBBDropView.h" +#import "HBBAppFunctions.h" @implementation HandBrakeBatchAppDelegate @synthesize window, inputFiles; -#pragma mark Initialization +#pragma mark Initialization - (id) init { + // Initialize application directory NSFileManager *fm = [NSFileManager defaultManager]; appSupportFolder = [[NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSUserDomainMask, YES) @@ -83,11 +85,11 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification [[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:@"http://donate.osomac.com/apps/2"]]; [[NSUserDefaults standardUserDefaults] setBool:true forKey:@"HBBNoDonation"]; break; - + case NSAlertAlternateReturn: [[NSUserDefaults standardUserDefaults] setBool:true forKey:@"HBBNoDonation"]; break; - + default: [[NSUserDefaults standardUserDefaults] setObject:[NSDate date] forKey:@"NSFirstLaunchDate"]; break; @@ -97,6 +99,9 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification // Add observer for arrangedObjects [fileNamesController addObserver:self forKeyPath:@"arrangedObjects" options:NSKeyValueObservingOptionNew context:nil]; + + // Set up send file to checkbox + [self redrawSendFileToCheckbox]; } - (void)windowWillClose:(NSNotification *)notification { @@ -112,6 +117,8 @@ - (void)windowWillClose:(NSNotification *)notification { /////////////////////////////////////// - (IBAction)chooseOutputFolder:(id)sender { + + NSOpenPanel *panel = [NSOpenPanel openPanel]; [panel setCanChooseFiles:NO]; @@ -129,7 +136,7 @@ - (IBAction)chooseOutputFolder:(id)sender { if (outputFolderExists) [panel setDirectoryURL:[NSURL fileURLWithPath:outputFolder]]; - + if ([panel runModal] == NSOKButton) { NSString *path = [[panel directoryURL] path]; @@ -190,6 +197,99 @@ -(BOOL) isDuplicate:(HBBInputFile *)file { return false; } + + + +// --++-- --++-- --++-- --++-- --++-- --++-- +#pragma mark - +#pragma mark Send File To: +#pragma mark - + +- (void) redrawSendFileToCheckbox { + if ([HBBAppFunctions isSendToAppValid]) { + [sendFileToCheckbox setState:NSOnState]; + } + + else { + [HBBAppFunctions clearAllSendToAppPreferences]; + [sendFileToCheckbox setState:NSOffState]; + } + + [self redrawSendFileToIcon]; +} +- (void) redrawSendFileToIcon { + [sendToIconImage setImage:[HBBAppFunctions getIconForSendToApp]]; +} + +- (IBAction)chooseSendToApplication:(id)sender { + + // OPEN panels cannot pre-select files the same as the + // SAVE panel does + // http://www.cocoabuilder.com/archive/cocoa/317726-setting-preselected-file-for-nsopenpanel.html + + // OPEN APP SELECTION PANEL + NSOpenPanel *panel = [NSOpenPanel openPanel]; + + [panel setCanChooseFiles:YES]; + [panel setCanChooseDirectories:NO]; + [panel setAllowsMultipleSelection:NO]; + [panel setCanCreateDirectories:NO]; + + NSString *appPath = [HBBAppFunctions getSendToAppPath]; + // I assume to receive /Users/Me/Applications/TheApp.app + // we can't use that as the preselection as it will browse + // the contents. We have to root one layer higher + NSString *fullAppName = [HBBAppFunctions fRightBackOf:@"/" inString:appPath]; + appPath = [appPath stringByReplacingOccurrencesOfString:fullAppName withString:@""]; + + // POINT THE SELECTION PANEL TO OUR OLD LOCATION + if ([HBBAppFunctions isSendToAppValid]) { + [panel setDirectoryURL:[NSURL fileURLWithPath:appPath]]; + } + + // NEW FILE SELECTED -- save it + if ([panel runModal] == NSOKButton) { + NSURL *firstPath = [[panel URLs] objectAtIndex:0]; + + //NSLog(@"App Selected: %@", [firstPath absoluteString]); + + // SAVE PATH + NSString *urlPath = [firstPath absoluteString]; + [HBBAppFunctions setSendToAppPath:urlPath]; + + // SAVE APP NAME + [HBBAppFunctions setSendToAppName:[firstPath lastPathComponent]]; + + // MAKE SURE SETTINGS ARE SAVED + [[NSUserDefaults standardUserDefaults] synchronize]; + + // Set up send file to checkbox + [self redrawSendFileToCheckbox]; + + } +} +- (IBAction)sendToApplicationClicked:(id)sender { + NSButtonCell *checkbox = (NSButtonCell *)sender; + if (checkbox) { + [checkbox setState:NSOffState]; + } + + BOOL hadPreviousValue = [HBBAppFunctions isSendToAppValid]; + + // no matter what we will remove pervious values, then + // call what is needed here + [HBBAppFunctions clearAllSendToAppPreferences]; + [self redrawSendFileToCheckbox]; + + // TRYING TO ENABLE + // call "chooseSendToApplication:" + if ( ! hadPreviousValue ) { + [self chooseSendToApplication:nil]; + } + +} + + // Recursively process files & directories -(void)processFiles:(NSURL *)url { NSArray *videoExtensions = [NSArray arrayWithObjects:@"3g2", @"3gp", @"asf", @"asx", @"avi", @"flv", @"mov", @"mp4", @"mpg", @"rm", @"srt", @"swf", @"vob", @"wmv", @"264", @"3gpp2", @"3mm", @"60d", @"aet", @"avd", @"avs", @"bdt2", @"bnp", @"box", @"bs4", @"byu", @"camv", @"dav", @"ddat", @"dif", @"dlx", @"dmsm3d", @"dnc", @"dv4", @"fbr", @"flx", @"gvp", @"h264", @"irf", @"iva", @"k3g", @"lrec", @"lsx", @"m1v", @"m2a", @"m4u", @"meta", @"mjpg", @"modd", @"moff", @"moov", @"movie", @"mp2v", @"mp4v", @"mpe", @"mpsub", @"mvc", @"mvex", @"mys", @"osp", @"par", @"playlist", @"pns", @"pssd", @"pva", @"pvr", @"qt", @"qtch", @"qtm", @"rp", @"rts", @"sbt", @"scn", @"sfd", @"sml", @"smv", @"spl", @"str", @"vcr", @"vem", @"vft", @"vfw", @"vid", @"video", @"vs4", @"vse", @"w32", @"wm", @"wot", @"787", @"am", @"anim", @"bix", @"cel", @"cvc", @"dsy", @"gl", @"grasp", @"gvi", @"ivs", @"lsf", @"m15", @"m4e", @"m75", @"mmv", @"mob", @"mpeg4", @"mpf", @"mpg2", @"mpv2", @"msh", @"mvb", @"pmv", @"rmd", @"rts", @"scm", @"sec", @"ssm", @"tdx", @"vdx", @"viv", @"vivo", @"vp3", @"aepx", @"ale", @"avp", @"avs", @"bdm", @"bik", @"bin", @"bsf", @"camproj", @"cpi", @"dat", @"divx", @"dmsm", @"dream", @"dvdmedia", @"dvr-ms", @"dzm", @"dzp", @"edl", @"f4v", @"fbr", @"fcproject", @"hdmov", @"imovieproj", @"ism", @"ismv", @"m2p", @"m4v", @"mkv", @"mod", @"moi", @"mpeg", @"mts", @"mxf", @"ogv", @"pds", @"prproj", @"psh", @"r3d", @"rcproject", @"rmvb", @"scm", @"smil", @"sqz", @"stx", @"swi", @"tix", @"trp", @"ts", @"veg", @"vf", @"vro", @"webm", @"wlmp", @"wtv", @"xvid", @"yuv", @"3gp2", @"3gpp", @"3p2", @"aaf", @"aep", @"aetx", @"ajp", @"amc", @"amv", @"amx", @"arcut", @"arf", @"avb", @"axm", @"bdmv", @"bdt3", @"bmk", @"camrec", @"cine", @"clpi", @"cmmp", @"cmmtpl", @"cmproj", @"cmrec", @"cst", @"d2v", @"d3v", @"dce", @"dck", @"dcr", @"dcr", @"dir", @"dmb", @"dmsd", @"dmsd3d", @"dmss", @"dpa", @"dpg", @"dv", @"dv-avi", @"dvr", @"dvx", @"dxr", @"dzt", @"evo", @"eye", @"f4p", @"fbz", @"fcp", @"flc", @"flh", @"fli", @"gfp", @"gts", @"hkm", @"ifo", @"imovieproject", @"ircp", @"ismc", @"ivf", @"ivr", @"izz", @"izzy", @"jts", @"jtv", @"m1pg", @"m21", @"m21", @"m2t", @"m2ts", @"m2v", @"mgv", @"mj2", @"mjp", @"mk3d", @"mnv", @"mp21", @"mp21", @"mpgindex", @"mpl", @"mpls", @"mpv", @"mqv", @"msdvd", @"mse", @"mswmm", @"mtv", @"mvd", @"mve", @"mvp", @"mvp", @"mvy", @"ncor", @"nsv", @"nuv", @"nvc", @"ogm", @"ogx", @"pgi", @"photoshow", @"piv", @"plproj", @"pmf", @"ppj", @"prel", @"pro", @"prtl", @"pxv", @"qtl", @"qtz", @"rcd", @"rdb", @"rec", @"rmd", @"rmp", @"rms", @"roq", @"rsx", @"rum", @"rv", @"rvl", @"sbk", @"scc", @"screenflow", @"seq", @"sfvidcap", @"siv", @"smi", @"smk", @"stl", @"svi", @"swt", @"tda3mt", @"tivo", @"tod", @"tp", @"tp0", @"tpd", @"tpr", @"tsp", @"tvs", @"usm", @"vc1", @"vcpf", @"vcv", @"vdo", @"vdr", @"vep", @"vfz", @"vgz", @"viewlet", @"vlab", @"vp6", @"vp7", @"vpj", @"vsp", @"wcp", @"wmd", @"wmmp", @"wmx", @"wp3", @"wpl", @"wvx", @"xej", @"xel", @"xesc", @"xfl", @"xlmv", @"zm1", @"zm2", @"zm3", @"zmv", @"iso", nil]; diff --git a/HandBrakeBatch/en.lproj/MainMenu.xib b/HandBrakeBatch/MainMenu.xib similarity index 72% rename from HandBrakeBatch/en.lproj/MainMenu.xib rename to HandBrakeBatch/MainMenu.xib index aeceab7..43d94d8 100644 --- a/HandBrakeBatch/en.lproj/MainMenu.xib +++ b/HandBrakeBatch/MainMenu.xib @@ -3,19 +3,22 @@ 1080 12C60 - 2843 + 2840 1187.34 625.00 com.apple.InterfaceBuilder.CocoaPlugin - 2843 + 2840 NSArrayController + NSBox NSButton NSButtonCell NSCustomObject NSCustomView + NSImageCell + NSImageView NSMenu NSMenuItem NSPathCell @@ -584,7 +587,7 @@ - 4 + 6 @@ -601,7 +604,7 @@ -2147483392 - {{1, 247}, {167, 15}} + {{1, 270}, {201, 16}} @@ -609,7 +612,7 @@ 1 _doScroller: - 0.81862745098039214 + 0.98529411764705888 @@ -659,117 +662,327 @@ 256 - + - 290 - {{152, 58}, {109, 26}} - - - - _NS:9 - YES - - -2076180416 - 2048 - - _NS:9 - - 109199360 - 129 - - - 400 - 75 - - YES - - OtherViews - - - - Do nothing - - 1048576 - 2147483647 - - - _popUpItemAction: - + 10 + + + + 274 + + + + 268 + + {{12, 60}, {139, 18}} + + + + _NS:9 + YES + + -2080374784 + 0 + Delete source files + + _NS:9 + + 1211912448 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + NO + + + + 268 + + {{12, 86}, {97, 18}} + + + + _NS:9 + YES + + 67108864 + 0 + Send file to: + + _NS:9 + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{163, 61}, {105, 16}} + + + + _NS:1505 + YES + + 68157504 + 272630784 + Are you sure? + + LucidaGrande + 12 + 16 + + _NS:1505 + + YES + + 6 + System + controlColor + + + + 1 + MC41MDE5NjA4MTQgMCAwLjI1MDk4MDQwNyAwLjYAA + + + NO + + + + 266 + {{10, 10}, {243, 26}} + + + + _NS:9 + YES + + -2076180416 + 2048 + + _NS:9 + + 109199360 + 129 + + + 400 + 75 + + + Do nothing + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + + Quit HBB + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + Put Mac to sleep + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + Shut down this Mac + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + + -1 + 1 + YES + YES + 2 + + NO + + + + 268 + {{12, 37}, {240, 17}} + + + + _NS:1535 + YES + + 68157504 + 272630784 + All finished: + + _NS:1535 + + + + + NO - - - Quit HBB - - 1048576 - 2147483647 - - - _popUpItemAction: - + + + 268 + {{130, 88}, {91, 17}} + + + + _NS:1535 + YES + + 67108928 + 272631808 + IDentify + + _NS:1535 + + + + + NO - - - Put Mac to sleep - - 1048576 - 2147483647 - - - _popUpItemAction: - + + + 265 + + {{220, 78}, {35, 32}} + + + + YES + + 67108864 + 134217728 + ... + + LucidaGrande + 9 + 3614 + + + -2038284288 + 129 + + + 200 + 25 + + NO - - - Shut down this Mac - - 1048576 - 2147483647 - - - _popUpItemAction: - + + + 268 + + + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + NSFilenamesPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT TIFF v4.0 pasteboard type + + {{108, 86}, {21, 21}} + + + + _NS:9 + YES + + 134217728 + 33554432 + _NS:9 + 0 + 0 + 0 + NO + + NO + YES - + {{1, 1}, {262, 116}} + + + + _NS:11 - -1 - 1 - YES - YES - 2 - - NO - - - - 292 - {{17, 63}, {133, 17}} + + {{4, 43}, {264, 132}} - - _NS:1535 - YES - - 68157504 - 272630784 - After the conversion - - _NS:1535 - - - 6 - System - controlColor - + + _NS:9 + {0, 0} + + 67108864 + 0 + After Conversion + + + + + 3 + MCAwLjgwMDAwMDAxMTkAA - - NO + + 1 + 0 + 2 + NO -2147482335 - {{150, 23}, {16, 16}} + {{150, 18}, {16, 16}} @@ -777,101 +990,14 @@ 20746 100 - - - 268 - {{24, 87}, {187, 41}} - - - - _NS:1505 - YES - - 68157504 - 272630784 - 4oenIEFyZSB5b3Ugc3VyZT8KTm8gZnVydGhlciB3YXJuaW5ncyE - - LucidaGrande - 13 - 16 - - _NS:1505 - - YES - - - 1 - MC41MDE5NjA4MTQgMCAwLjI1MDk4MDQwNyAwLjYAA - - - NO - - - - 268 - - {{22, 134}, {245, 18}} - - - _NS:9 - YES - - -2080374784 - 0 - Delete source files after conversion - - _NS:9 - - 1211912448 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - NO - - - - 268 - - {{117, 226}, {120, 18}} - - - _NS:9 - YES - - -2080374784 - 0 - Same as source - - _NS:9 - - 1211912448 - 2 - - - - - 200 - 25 - - NO - 289 - {{168, 13}, {96, 32}} + {{168, 8}, {96, 32}} + YES 67108864 @@ -888,195 +1014,264 @@ NO - - - 268 - - {{15, 162}, {100, 32}} - - - YES - - 67108864 - 134217728 - Choose… - - - -2038284288 - 129 - - - 200 - 25 - - NO - - - - 268 - {{18, 228}, {96, 17}} - - - - YES - - 68157504 - 272630784 - Output Folder: - - - - - - NO - - - - 268 - {{18, 317}, {119, 17}} - - - - YES - - 68157504 - 272630784 - HandBrake Preset: - - - - - - NO - - - - 266 - {{21, 198}, {237, 22}} - - - - YES - - -2073034687 - 272634880 - - - - YES - - - 6 - System - textColor - - - - NO - - + - 266 - {{18, 285}, {243, 26}} - - - - YES - - -2076180416 - 2048 - - - 109199360 - 129 - - - 400 - 75 - - - Item 2 - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - - - YES - - OtherViews - - - - Item 1 - - 1048576 - 2147483647 - - - _popUpItemAction: - + 10 + + + + 274 + + + + 268 + {{12, 121}, {119, 17}} + + + + YES + + 68157504 + 272630784 + HandBrake Preset: + + + + + + NO + + + + 266 + {{10, 93}, {243, 26}} + + + + YES + + -2076180416 + 2048 + + + 109199360 + 129 + + + 400 + 75 + + + Item 2 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + Item 1 + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + + Item 3 + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + + 1 + 1 + YES + YES + 2 + + NO + + + + 268 + {{12, 68}, {96, 17}} + + + + YES + + 68157504 + 272630784 + Output Folder: + + + + + + NO + + + + 265 + + {{162, 67}, {90, 18}} + + + + _NS:9 + YES + + -2080374784 + 0 + Same as source + + _NS:9 + + 1210863872 + 2 + + + + + 200 + 25 + + NO - - - - Item 3 - - 1048576 - 2147483647 - - - _popUpItemAction: - + + + 268 + {{12, 45}, {243, 13}} + + + + _NS:9 + {250, 750} + YES + + 67108864 + 272629760 + Warning: the source file might be overwritten! + + LucidaGrande + 10 + 16 + + _NS:9 + + + + 1 + MC41MDE5NjA4MTQgMCAwLjI1MDk4MDQwNyAwLjYAA + + + NO + + + + 266 + {{13, 41}, {237, 22}} + + + + YES + + -2073034687 + 272634880 + + + + YES + + + 6 + System + textColor + + + + NO + + + + 268 + + {{7, 8}, {100, 32}} + + + + YES + + 67108864 + 134217728 + Choose… + + + -2038284288 + 129 + + + 200 + 25 + + NO - + {{1, 1}, {262, 147}} + + + + _NS:11 - 1 - 1 - YES - YES - 2 - - NO - - - - 268 - {{21, 207}, {243, 13}} + + {{4, 180}, {264, 163}} - + _NS:9 - {250, 750} - YES - + {0, 0} + 67108864 - 272629760 - Warning: the source file might be overwritten! - - LucidaGrande - 10 - 16 - - _NS:9 - - + 0 + Conversion Settings + + + - 1 - MC41MDE5NjA4MTQgMCAwLjI1MDk4MDQwNyAwLjYAA + 3 + MCAwLjgwMDAwMDAxMTkAA - NO + + 1 + 0 + 2 + NO {{302, 0}, {278, 354}} - + NSView @@ -1300,30 +1495,6 @@ 565 - - - chooseOutputFolder: - - - - 564 - - - - presetSelected: - - - - 693 - - - - presetPopUp - - - - 694 - fileNamesView @@ -1349,20 +1520,68 @@ 815 - - content: arrangedObjects - - - - - - content: arrangedObjects - content - arrangedObjects - 2 - - - 591 + + chooseOutputFolder: + + + + 564 + + + + presetPopUp + + + + 694 + + + + presetSelected: + + + + 693 + + + + chooseSendToApplication + + + + 920 + + + + chooseSendToApplication: + + + + 921 + + + + sendToApplicationClicked: + + + + 926 + + + + sendFileToCheckbox + + + + 927 + + + + sendToIconImage + + + + 930 @@ -1383,19 +1602,19 @@ - value: values.OutputFolder - - - - - - value: values.OutputFolder - value - values.OutputFolder + content: arrangedObjects + + + + + + content: arrangedObjects + content + arrangedObjects 2 - 597 + 591 @@ -1413,6 +1632,22 @@ 734 + + + value: values.OutputFolder + + + + + + value: values.OutputFolder + value + values.OutputFolder + 2 + + + 597 + hidden: values.HBBDestinationSameAsSource @@ -1681,6 +1916,22 @@ 891 + + + value: values.HBBSendConvertedFileToAppName + + + + + + value: values.HBBSendConvertedFileToAppName + value + values.HBBSendConvertedFileToAppName + 2 + + + 924 + @@ -2062,116 +2313,154 @@ 607 - - - - - - - - - - - + + - 865 - + 807 + + + + + 539 + - + + Push Button - START - 866 - + 540 + + + + + 902 + - + + + + + + + - + - 867 - + 538 + - - - - + - + + Push Button - choose directory - 870 - - + 541 + + - 868 - - + 717 + + + + + - 862 - + 718 + + + + + 534 + - + - + + Pop Up Button - Preset - 863 - - + 545 + + + + + - 807 - - + 546 + + + + + + + - 747 - + 549 + + + + + 548 + + + + + 547 + + + + + 535 + - + - - Static Text - ⇧ Are you sure? No further warnings! + + Text Field - output dir - 748 - - + 544 + + - 740 - + 536 + - + - + - 741 - - + 543 + + - 717 - + 537 + - + - + - 718 - - + 542 + + 713 @@ -2179,7 +2468,8 @@ - + + Check Box - Same as source 714 @@ -2187,120 +2477,162 @@ - 539 - + 903 + - + + + + + + + + - 540 - - - - - 538 - + 740 + - + - + + Check Box - Delete when done - 541 - - + 741 + + - 537 - + 747 + - + - + + Static Text - ⇧ Are you sure? No further warnings! - 542 - - + 748 + + - 536 - + 865 + - + - + + Pop Up Button - Do after done - 543 - - + 866 + + + + + - 535 - + 867 + - + + + + - + - 544 - - + 893 + + - 534 - + 892 + + + + + 870 + + + + + 868 + + + + + 862 + - + - + - 545 - + 863 + + + + + 904 + - + - + + Push Button - choose directory - 546 - + 905 + + + + + 908 + - - - + - + + Check Box - Delete when done - 549 - - + 909 + + - 548 - - + 911 + + + + + - 547 - - + 912 + + - 892 - - + 928 + + + + + - 893 - - + 929 + + @@ -2409,13 +2741,23 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin - 893 + 930 @@ -2451,9 +2793,11 @@ NSObject id + id id id id + id id id @@ -2462,6 +2806,10 @@ chooseOutputFolder: id + + chooseSendToApplication: + id + displayLicense: id @@ -2474,6 +2822,10 @@ presetSelected: id + + sendToApplicationClicked: + id + showPreferences: id @@ -2491,6 +2843,8 @@ NSView NSArrayController NSPopUpButton + NSButton + NSImageView NSWindow @@ -2522,6 +2876,14 @@ presetPopUp NSPopUpButton + + sendFileToCheckbox + NSButton + + + sendToIconImage + NSImageView + window NSWindow