summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordynaflash <[email protected]>2009-05-08 04:24:46 +0000
committerdynaflash <[email protected]>2009-05-08 04:24:46 +0000
commit242a3fda8463abef59022c2af96cba6f734250dc (patch)
treebcc17c8f72e58f3434e86bf96c4f5e276cd50c34
parentd53285a4bc003d29521f479a98e46b881b27a067 (diff)
MacGui: Preset Import / Export initial implementation and auto updating of built in presets.
- Preset Import / Export: -- Export is only available to custom user presets. -- Export is only the selected preset at this time. -- Exported presets will be tagged with their build number. -- Import of mutiple presets. --- Compatible with LinGui presets. --- NOT compatible with WinGui presets at this time. - Built-In preset auto-updating: -- Adds the key/value pair to the UserPresets.plist file for key "PresetBuildNumber". -- If the HandBrake.app build number as defined in the Info.plist key "CFBundleVersion" is > the built in presets "PresetBuildNumber" then the - (IBAction)addFactoryPresets:(id)sender is called to automagically update the built in presets. -- An alert window is shown along with a system beep ( can be turned off in Preferences -> Advanced for svn mavens and devs) to tell the user that the built in presets are going to be updated. -- NOTE: First launch of this build will initiate a built in preset update even though the built in presets are the same, since the build number will be added to the built in presets. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2405 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r--macosx/Controller.h11
-rw-r--r--macosx/Controller.mm183
-rw-r--r--macosx/English.lproj/MainMenu.xib57
-rw-r--r--macosx/English.lproj/Preferences.xib92
-rw-r--r--macosx/HBPreferencesController.m3
5 files changed, 319 insertions, 27 deletions
diff --git a/macosx/Controller.h b/macosx/Controller.h
index 6a8e587ba..87e7cd6a7 100644
--- a/macosx/Controller.h
+++ b/macosx/Controller.h
@@ -364,10 +364,19 @@ BOOL fIsDragging;
- (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;
diff --git a/macosx/Controller.mm b/macosx/Controller.mm
index 1164f0f29..40e42c731 100644
--- a/macosx/Controller.mm
+++ b/macosx/Controller.mm
@@ -6296,6 +6296,46 @@ return YES;
[self addFactoryPresets:nil];
}
[fPresetsOutlineView reloadData];
+
+ [self checkBuiltInsForUpdates];
+}
+
+- (void) checkBuiltInsForUpdates {
+
+ BOOL updateBuiltInPresets = NO;
+ int i = 0;
+ NSEnumerator *enumerator = [UserPresets objectEnumerator];
+ id tempObject;
+ while (tempObject = [enumerator nextObject])
+ {
+ /* iterate through the built in presets to see if any have an old build number */
+ NSMutableDictionary *thisPresetDict = tempObject;
+ /*Key Type == 0 is built in, and key PresetBuildNumber is the build number it was created with */
+ if ([[thisPresetDict objectForKey:@"Type"] intValue] == 0)
+ {
+ if (![thisPresetDict objectForKey:@"PresetBuildNumber"] || [[thisPresetDict objectForKey:@"PresetBuildNumber"] intValue] < [[[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleVersion"] intValue])
+ {
+ updateBuiltInPresets = YES;
+ }
+ }
+ i++;
+ }
+ /* if we have built in presets to update, then do so AlertBuiltInPresetUpdate*/
+ if ( updateBuiltInPresets == YES)
+ {
+ if( [[NSUserDefaults standardUserDefaults] boolForKey:@"AlertBuiltInPresetUpdate"] == YES)
+ {
+ /* Show an alert window that built in presets will be updated */
+ /*On Screen Notification*/
+ int status;
+ NSBeep();
+ status = NSRunAlertPanel(@"HandBrake has determined your built in presets are out of date...",@"HandBrake will now update your built-in presets.", @"OK", nil, nil);
+ [NSApp requestUserAttention:NSCriticalRequest];
+ }
+ /* when alert is dismissed, go ahead and update the built in presets */
+ [self addFactoryPresets:nil];
+ }
+
}
@@ -6383,6 +6423,9 @@ return YES;
- (NSDictionary *)createPreset
{
NSMutableDictionary *preset = [[NSMutableDictionary alloc] init];
+ /* Preset build number */
+ [preset setObject:[NSString stringWithFormat: @"%d", [[[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleVersion"] intValue]] forKey:@"PresetBuildNumber"];
+ [preset setObject:[fPresetNewName stringValue] forKey:@"PresetName"];
/* Get the New Preset Name from the field in the AddPresetPanel */
[preset setObject:[fPresetNewName stringValue] forKey:@"PresetName"];
/* Set whether or not this is to be a folder fPresetNewFolderCheck*/
@@ -6605,6 +6648,119 @@ return YES;
}
}
+
+#pragma mark -
+#pragma mark Import Export Preset(s)
+
+- (IBAction) browseExportPresetFile: (id) sender
+{
+ /* Open a panel to let the user choose where and how to save the export file */
+ NSSavePanel * panel = [NSSavePanel savePanel];
+ /* We get the current file name and path from the destination field here */
+ NSString *defaultExportDirectory = [NSString stringWithFormat: @"%@/Desktop/", NSHomeDirectory()];
+
+ [panel beginSheetForDirectory: defaultExportDirectory file: @"HB_Export.plist"
+ modalForWindow: fWindow modalDelegate: self
+ didEndSelector: @selector( browseExportPresetFileDone:returnCode:contextInfo: )
+ contextInfo: NULL];
+}
+
+- (void) browseExportPresetFileDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo
+{
+ if( returnCode == NSOKButton )
+ {
+ NSString *presetExportDirectory = [[sheet filename] stringByDeletingLastPathComponent];
+ NSString *exportPresetsFile = [sheet filename];
+ [[NSUserDefaults standardUserDefaults] setObject:presetExportDirectory forKey:@"LastPresetExportDirectory"];
+ /* We check for the presets.plist */
+ if ([[NSFileManager defaultManager] fileExistsAtPath:exportPresetsFile] == 0)
+ {
+ [[NSFileManager defaultManager] createFileAtPath:exportPresetsFile contents:nil attributes:nil];
+ }
+ NSMutableArray * presetsToExport = [[NSMutableArray alloc] initWithContentsOfFile:exportPresetsFile];
+ if (nil == presetsToExport)
+ {
+ presetsToExport = [[NSMutableArray alloc] init];
+
+ /* now get and add selected presets to export */
+
+ }
+ if ([fPresetsOutlineView selectedRow] >= 0 && [[[fPresetsOutlineView itemAtRow:[fPresetsOutlineView selectedRow]] objectForKey:@"Folder"] intValue] != 1)
+ {
+ [presetsToExport addObject:[fPresetsOutlineView itemAtRow:[fPresetsOutlineView selectedRow]]];
+ [presetsToExport writeToFile:exportPresetsFile atomically:YES];
+
+ }
+
+ }
+}
+
+
+- (IBAction) browseImportPresetFile: (id) sender
+{
+
+ NSOpenPanel * panel;
+
+ panel = [NSOpenPanel openPanel];
+ [panel setAllowsMultipleSelection: NO];
+ [panel setCanChooseFiles: YES];
+ [panel setCanChooseDirectories: NO ];
+ NSString * sourceDirectory;
+ if ([[NSUserDefaults standardUserDefaults] stringForKey:@"LastPresetImportDirectory"])
+ {
+ sourceDirectory = [[NSUserDefaults standardUserDefaults] stringForKey:@"LastPresetImportDirectory"];
+ }
+ else
+ {
+ sourceDirectory = @"~/Desktop";
+ sourceDirectory = [sourceDirectory stringByExpandingTildeInPath];
+ }
+ /* we open up the browse sources sheet here and call for browseSourcesDone after the sheet is closed
+ * to evaluate whether we want to specify a title, we pass the sender in the contextInfo variable
+ */
+ /* set this for allowed file types, not sure if we should allow xml or not */
+ NSArray *fileTypes = [NSArray arrayWithObjects:@"plist", @"xml", nil];
+ [panel beginSheetForDirectory: sourceDirectory file: nil types: fileTypes
+ modalForWindow: fWindow modalDelegate: self
+ didEndSelector: @selector( browseImportPresetDone:returnCode:contextInfo: )
+ contextInfo: sender];
+}
+
+- (void) browseImportPresetDone: (NSSavePanel *) sheet
+ returnCode: (int) returnCode contextInfo: (void *) contextInfo
+{
+ if( returnCode == NSOKButton )
+ {
+ NSString *importPresetsDirectory = [[sheet filename] stringByDeletingLastPathComponent];
+ NSString *importPresetsFile = [sheet filename];
+ [[NSUserDefaults standardUserDefaults] setObject:importPresetsDirectory forKey:@"LastPresetImportDirectory"];
+ /* NOTE: here we need to do some sanity checking to verify we do not hose up our presets file */
+ NSMutableArray * presetsToImport = [[NSMutableArray alloc] initWithContentsOfFile:importPresetsFile];
+ /* iterate though the new array of presets to import and add them to our presets array */
+ int i = 0;
+ NSEnumerator *enumerator = [presetsToImport objectEnumerator];
+ id tempObject;
+ while (tempObject = [enumerator nextObject])
+ {
+ /* make any changes to the incoming preset we see fit */
+ /* make sure the incoming preset is not tagged as default */
+ [tempObject setObject:[NSNumber numberWithInt:0] forKey:@"Default"];
+ /* prepend "(imported) to the name of the incoming preset for clarification since it can be changed */
+ NSString * prependedName = [@"(import) " stringByAppendingString:[tempObject objectForKey:@"PresetName"]] ;
+ [tempObject setObject:prependedName forKey:@"PresetName"];
+
+ /* actually add the new preset to our presets array */
+ [UserPresets addObject:tempObject];
+ i++;
+ }
+ [presetsToImport autorelease];
+ [self sortPresets];
+ [self addPreset];
+
+ }
+}
+
#pragma mark -
#pragma mark Manage Default Preset
@@ -6863,16 +7019,33 @@ return YES;
}
- /* We use this method to recreate new, updated factory
- presets */
+ /* We use this method to recreate new, updated factory presets */
- (IBAction)addFactoryPresets:(id)sender
{
-
- /* First, we delete any existing built in presets */
+
+ /* First, we delete any existing built in presets */
[self deleteFactoryPresets: sender];
/* Then we generate new built in presets programmatically with fPresetsBuiltin
- * which is all setup in HBPresets.h and HBPresets.m*/
+ * which is all setup in HBPresets.h and HBPresets.m*/
[fPresetsBuiltin generateBuiltinPresets:UserPresets];
+ /* update build number for built in presets */
+ /* iterate though the new array of presets to import and add them to our presets array */
+ int i = 0;
+ NSEnumerator *enumerator = [UserPresets objectEnumerator];
+ id tempObject;
+ while (tempObject = [enumerator nextObject])
+ {
+ /* Record the apps current build number in the PresetBuildNumber key */
+ if ([[tempObject objectForKey:@"Type"] intValue] == 0) // Type 0 is a built in preset
+ {
+ /* Preset build number */
+ [[UserPresets objectAtIndex:i] setObject:[NSString stringWithFormat: @"%d", [[[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleVersion"] intValue]] forKey:@"PresetBuildNumber"];
+ }
+ i++;
+ }
+ /* report the built in preset updating to the activity log */
+ [self writeToActivityLog: "built in presets updated to build number: %d", [[[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleVersion"] intValue]];
+
[self sortPresets];
[self addPreset];
diff --git a/macosx/English.lproj/MainMenu.xib b/macosx/English.lproj/MainMenu.xib
index da8f6db98..be20ff85f 100644
--- a/macosx/English.lproj/MainMenu.xib
+++ b/macosx/English.lproj/MainMenu.xib
@@ -8,6 +8,7 @@
<string key="IBDocument.HIToolboxVersion">353.00</string>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
+ <integer value="1949"/>
<integer value="2"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
@@ -3487,6 +3488,22 @@
<reference key="NSOnImage" ref="447995298"/>
<reference key="NSMixedImage" ref="760317610"/>
</object>
+ <object class="NSMenuItem" id="734454745">
+ <reference key="NSMenu" ref="112579544"/>
+ <string key="NSTitle">Export ...</string>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="447995298"/>
+ <reference key="NSMixedImage" ref="760317610"/>
+ </object>
+ <object class="NSMenuItem" id="685593004">
+ <reference key="NSMenu" ref="112579544"/>
+ <string key="NSTitle">Import ...</string>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="447995298"/>
+ <reference key="NSMixedImage" ref="760317610"/>
+ </object>
<object class="NSMenuItem" id="454042588">
<reference key="NSMenu" ref="112579544"/>
<string key="NSTitle">Select Default Preset</string>
@@ -6160,6 +6177,22 @@
</object>
<int key="connectionID">5187</int>
</object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">browseExportPresetFile:</string>
+ <reference key="source" ref="2258723"/>
+ <reference key="destination" ref="734454745"/>
+ </object>
+ <int key="connectionID">5191</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">browseImportPresetFile:</string>
+ <reference key="source" ref="2258723"/>
+ <reference key="destination" ref="685593004"/>
+ </object>
+ <int key="connectionID">5193</int>
+ </object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@@ -7441,6 +7474,8 @@
<reference ref="644928468"/>
<reference ref="180231"/>
<reference ref="454042588"/>
+ <reference ref="734454745"/>
+ <reference ref="685593004"/>
</object>
<reference key="parent" ref="226787934"/>
</object>
@@ -9332,6 +9367,16 @@
<reference key="object" ref="677126774"/>
<reference key="parent" ref="303369850"/>
</object>
+ <object class="IBObjectRecord">
+ <int key="objectID">5188</int>
+ <reference key="object" ref="734454745"/>
+ <reference key="parent" ref="112579544"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">5192</int>
+ <reference key="object" ref="685593004"/>
+ <reference key="parent" ref="112579544"/>
+ </object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
@@ -10078,6 +10123,8 @@
<string>5184.IBPluginDependency</string>
<string>5184.ImportedFromIB2</string>
<string>5185.IBPluginDependency</string>
+ <string>5188.IBPluginDependency</string>
+ <string>5192.IBPluginDependency</string>
<string>56.IBPluginDependency</string>
<string>56.ImportedFromIB2</string>
<string>57.IBPluginDependency</string>
@@ -10369,7 +10416,7 @@
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
- <string>{{195, 732}, {236, 93}}</string>
+ <string>{{195, 692}, {236, 133}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@@ -10863,6 +10910,8 @@
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
@@ -10897,7 +10946,7 @@
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">5187</int>
+ <int key="maxID">5193</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@@ -10923,7 +10972,9 @@
<string>audioTrackMixdownChanged:</string>
<string>audioTrackPopUpChanged:</string>
<string>autoSetM4vExtension:</string>
+ <string>browseExportPresetFile:</string>
<string>browseFile:</string>
+ <string>browseImportPresetFile:</string>
<string>browseSources:</string>
<string>calculateBitrate:</string>
<string>calculatePictureSizing:</string>
@@ -11014,6 +11065,8 @@
<string>id</string>
<string>id</string>
<string>id</string>
+ <string>id</string>
+ <string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="outlets">
diff --git a/macosx/English.lproj/Preferences.xib b/macosx/English.lproj/Preferences.xib
index 0ef8e5940..bb9f7001c 100644
--- a/macosx/English.lproj/Preferences.xib
+++ b/macosx/English.lproj/Preferences.xib
@@ -8,7 +8,6 @@
<string key="IBDocument.HIToolboxVersion">353.00</string>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
- <integer value="233"/>
<integer value="236"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
@@ -59,12 +58,12 @@
<object class="NSUserDefaultsController" id="580534391">
<object class="NSMutableArray" key="NSDeclaredKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
- <string>UseDvdNav</string>
+ <string>AlertBuiltInPresetUpdate</string>
</object>
<bool key="NSSharedInstance">YES</bool>
</object>
<object class="NSCustomView" id="1048779201">
- <reference key="NSNextResponder"/>
+ <nil key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -450,7 +449,6 @@
</object>
</object>
<string key="NSFrameSize">{492, 231}</string>
- <reference key="NSSuperview"/>
<string key="NSClassName">NSView</string>
<string key="NSExtension">NSControl</string>
</object>
@@ -806,7 +804,7 @@
<object class="NSButton" id="882188042">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{84, 201}, {367, 18}}</string>
+ <string key="NSFrame">{{84, 253}, {367, 18}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="197383193">
@@ -827,7 +825,7 @@
<object class="NSTextField" id="759266151">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{40, 202}, {41, 17}}</string>
+ <string key="NSFrame">{{40, 254}, {41, 17}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="488653412">
@@ -843,7 +841,7 @@
<object class="NSTextField" id="226601760">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{83, 179}, {301, 17}}</string>
+ <string key="NSFrame">{{83, 231}, {301, 17}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="1064438472">
@@ -859,7 +857,7 @@
<object class="NSTextField" id="701867067">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{37, 140}, {239, 17}}</string>
+ <string key="NSFrame">{{37, 192}, {239, 17}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="978611587">
@@ -875,7 +873,7 @@
<object class="NSTextField" id="173328305">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{71, 39}, {184, 17}}</string>
+ <string key="NSFrame">{{71, 91}, {184, 17}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="271531935">
@@ -891,7 +889,7 @@
<object class="NSTextField" id="899831697">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{40, 63}, {32, 17}}</string>
+ <string key="NSFrame">{{40, 115}, {32, 17}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="483848741">
@@ -907,7 +905,7 @@
<object class="NSButton" id="907177043">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{75, 61}, {367, 18}}</string>
+ <string key="NSFrame">{{75, 113}, {367, 18}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="869757541">
@@ -928,7 +926,7 @@
<object class="NSButton" id="745324926">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">256</int>
- <string key="NSFrame">{{41, 105}, {367, 18}}</string>
+ <string key="NSFrame">{{41, 157}, {367, 18}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="884409108">
@@ -946,10 +944,31 @@
<int key="NSPeriodicInterval">25</int>
</object>
</object>
+ <object class="NSButton" id="712613872">
+ <reference key="NSNextResponder" ref="23728330"/>
+ <int key="NSvFlags">256</int>
+ <string key="NSFrame">{{41, 56}, {269, 18}}</string>
+ <reference key="NSSuperview" ref="23728330"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="562265695">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Alert when updating built-in presets</string>
+ <reference key="NSSupport" ref="964910696"/>
+ <reference key="NSControlView" ref="712613872"/>
+ <int key="NSButtonFlags">1211912703</int>
+ <int key="NSButtonFlags2">2</int>
+ <reference key="NSAlternateImage" ref="1056213191"/>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
<object class="NSPopUpButton" id="772611942">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{276, 135}, {66, 22}}</string>
+ <string key="NSFrame">{{276, 187}, {66, 22}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSPopUpButtonCell" key="NSCell" id="413609467">
@@ -1038,7 +1057,7 @@
<object class="NSPopUpButton" id="822080053">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{386, 174}, {66, 22}}</string>
+ <string key="NSFrame">{{386, 226}, {66, 22}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSPopUpButtonCell" key="NSCell" id="434430620">
@@ -1113,7 +1132,7 @@
<object class="NSPopUpButton" id="895206300">
<reference key="NSNextResponder" ref="23728330"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{255, 34}, {66, 22}}</string>
+ <string key="NSFrame">{{255, 86}, {66, 22}}</string>
<reference key="NSSuperview" ref="23728330"/>
<bool key="NSEnabled">YES</bool>
<object class="NSPopUpButtonCell" key="NSCell" id="290473288">
@@ -1177,7 +1196,7 @@
</object>
</object>
</object>
- <string key="NSFrameSize">{480, 239}</string>
+ <string key="NSFrameSize">{479, 291}</string>
<reference key="NSSuperview"/>
<object class="NSMutableString" key="NSClassName">
<characters key="NS.bytes">NSView</characters>
@@ -1476,6 +1495,22 @@
</object>
<int key="connectionID">400</int>
</object>
+ <object class="IBConnectionRecord">
+ <object class="IBBindingConnection" key="connection">
+ <string key="label">value: values.AlertBuiltInPresetUpdate</string>
+ <reference key="source" ref="712613872"/>
+ <reference key="destination" ref="580534391"/>
+ <object class="NSNibBindingConnector" key="connector">
+ <reference key="NSSource" ref="712613872"/>
+ <reference key="NSDestination" ref="580534391"/>
+ <string key="NSLabel">value: values.AlertBuiltInPresetUpdate</string>
+ <string key="NSBinding">value</string>
+ <string key="NSKeyPath">values.AlertBuiltInPresetUpdate</string>
+ <int key="NSNibBindingConnectorVersion">2</int>
+ </object>
+ </object>
+ <int key="connectionID">403</int>
+ </object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@@ -1687,6 +1722,7 @@
<reference ref="822080053"/>
<reference ref="226601760"/>
<reference ref="745324926"/>
+ <reference ref="712613872"/>
</object>
<reference key="parent" ref="510204080"/>
<string key="objectName">Advanced</string>
@@ -2139,6 +2175,20 @@
<reference key="object" ref="884409108"/>
<reference key="parent" ref="745324926"/>
</object>
+ <object class="IBObjectRecord">
+ <int key="objectID">401</int>
+ <reference key="object" ref="712613872"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="562265695"/>
+ </object>
+ <reference key="parent" ref="23728330"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">402</int>
+ <reference key="object" ref="562265695"/>
+ <reference key="parent" ref="712613872"/>
+ </object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
@@ -2279,6 +2329,9 @@
<string>398.IBPluginDependency</string>
<string>398.ImportedFromIB2</string>
<string>399.IBPluginDependency</string>
+ <string>401.IBPluginDependency</string>
+ <string>401.ImportedFromIB2</string>
+ <string>402.IBPluginDependency</string>
<string>5.IBEditorWindowLastContentRect</string>
<string>5.IBWindowTemplateEditedContentRect</string>
<string>5.ImportedFromIB2</string>
@@ -2307,7 +2360,7 @@
<string>{{73, 774}, {500, 82}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
- <string>{{404, 534}, {480, 239}}</string>
+ <string>{{404, 482}, {479, 291}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>{{0, 650}, {500, 184}}</string>
@@ -2427,6 +2480,9 @@
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <reference ref="9"/>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{69, 656}, {500, 200}}</string>
<string>{{69, 656}, {500, 200}}</string>
<reference ref="9"/>
@@ -2460,7 +2516,7 @@
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">400</int>
+ <int key="maxID">403</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
diff --git a/macosx/HBPreferencesController.m b/macosx/HBPreferencesController.m
index 7f947e12b..0deddbf2f 100644
--- a/macosx/HBPreferencesController.m
+++ b/macosx/HBPreferencesController.m
@@ -59,7 +59,8 @@
@"NO", @"EncodeLogLocation",
@"10", @"PreviewsNumber",
@"", @"Drawer Size",
- @"0.25", @"x264CqSliderFractional",
+ @"0.25", @"x264CqSliderFractional",
+ @"YES", @"AlertBuiltInPresetUpdate",
nil]];
}