From 9aeb66fdcb19e085ea75026286020794331d870e Mon Sep 17 00:00:00 2001 From: dynaflash Date: Sun, 30 Nov 2008 05:02:38 +0000 Subject: MacGui: Remove custome decomb option from preferences and Picture Settings - Remove the text field to enter a custom decomb string in the Preferences > Picture window - Change the NSPopup for decomb to a checkbox in Picture Settings. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1975 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- macosx/Controller.mm | 25 ++- macosx/English.lproj/PictureSettings.xib | 254 ++++++++----------------------- macosx/English.lproj/Preferences.xib | 97 +++--------- macosx/HBPreferencesController.m | 1 - macosx/PictureController.h | 2 +- macosx/PictureController.mm | 10 +- 6 files changed, 95 insertions(+), 294 deletions(-) diff --git a/macosx/Controller.mm b/macosx/Controller.mm index b2ddff7a5..bdebb6954 100644 --- a/macosx/Controller.mm +++ b/macosx/Controller.mm @@ -4083,26 +4083,25 @@ the user is using "Custom" settings by determining the sender*/ } /* Detelecine */ - if ([fPictureController detelecine]) { + if ([fPictureController detelecine]) + { [fPicSettingDetelecine setStringValue: @"Yes"]; } - else { - [fPicSettingDetelecine setStringValue: @"No"]; + else + { + [fPicSettingDetelecine setStringValue: @"Off"]; } /* Decomb */ - if ([fPictureController decomb] == 0) + if ([fPictureController decomb]) { - [fPicSettingDecomb setStringValue: @"Off"]; + [fPicSettingDecomb setStringValue: @"1:2:6:9:80:16:16"]; } - else if ([fPictureController decomb] == 1) + else { - [fPicSettingDecomb setStringValue: @"1:2:6:9:80:16:16"]; + [fPicSettingDecomb setStringValue: @"Off"]; } - else if ([fPictureController decomb] == 2) - { - [fPicSettingDecomb setStringValue:[[NSUserDefaults standardUserDefaults] stringForKey:@"DecombCustomString"]]; - } + /* VFR (Variable Frame Rate) */ @@ -5912,7 +5911,7 @@ return YES; job->pixel_ratio = [[chosenPreset objectForKey:@"PicturePAR"] intValue]; - /* If the preset has no objectForKey:@"UsesPictureFilters", then we know it is a legacy preset + /* If the preset has no objectForKey:@"UsesPictureFilters", then we know it is a legacy preset * and handle the filters here as before. * NOTE: This should be removed when the update presets code is done as we can be assured that legacy * presets are updated to work properly with new keys. @@ -6041,7 +6040,7 @@ return YES; /* Decomb */ /* Even though we currently allow for a custom setting for decomb, ultimately it will only have Off and * Default so we just pay attention to anything greater than 0 as 1 (Default). 0 is Off. */ - if ([[chosenPreset objectForKey:@"PictureDecomb"] intValue] > 0) + if ([[chosenPreset objectForKey:@"PictureDecomb"] intValue] == 1) { [fPictureController setDecomb:1]; } diff --git a/macosx/English.lproj/PictureSettings.xib b/macosx/English.lproj/PictureSettings.xib index b5e0cea8f..68ea6c435 100644 --- a/macosx/English.lproj/PictureSettings.xib +++ b/macosx/English.lproj/PictureSettings.xib @@ -8,7 +8,7 @@ 352.00 YES - + YES @@ -844,6 +844,27 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 25 + + + 256 + {{4, 10}, {82, 18}} + + YES + + 67239424 + 67239936 + Decomb: + + + 1210864127 + 2 + + + + 200 + 25 + + 256 @@ -962,92 +983,6 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA - - - 256 - {{75, 9}, {110, 15}} - - YES - - -2076049856 - 264192 - - - 109199615 - 1 - - - - - - 400 - 75 - - - Item1 - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - - - YES - - - OtherViews - - - YES - - - - Item2 - - 1048576 - 2147483647 - - - _popUpItemAction: - - - - - Item3 - - 1048576 - 2147483647 - - - _popUpItemAction: - - - - - 3 - YES - YES - 1 - - - - - 256 - {{18, 7}, {52, 17}} - - YES - - 67239424 - 71303168 - Decomb: - - - - - - 268 @@ -1623,22 +1558,6 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 184 - - - fDecombPopUp - - - - 193 - - - - SettingsChanged: - - - - 194 - fDeblockSlider @@ -1735,6 +1654,22 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 233 + + + fDecombCheck + + + + 238 + + + + SettingsChanged: + + + + 239 + @@ -1843,11 +1778,10 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA - - + @@ -2342,64 +2276,6 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA - - 185 - - - YES - - - - - - 186 - - - YES - - - - - - 187 - - - - - 188 - - - YES - - - - - - 189 - - - YES - - - - - - - - 190 - - - - - 191 - - - - - 192 - - - 195 @@ -2552,6 +2428,20 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA + + 236 + + + YES + + + + + + 237 + + + @@ -2594,20 +2484,8 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 18.IBPluginDependency 18.ImportedFromIB2 180.IBPluginDependency - 185.IBPluginDependency - 185.ImportedFromIB2 - 186.IBPluginDependency - 186.ImportedFromIB2 - 189.IBPluginDependency - 189.ImportedFromIB2 19.IBPluginDependency 19.ImportedFromIB2 - 190.IBPluginDependency - 190.ImportedFromIB2 - 191.IBPluginDependency - 191.ImportedFromIB2 - 192.IBPluginDependency - 192.ImportedFromIB2 195.IBPluginDependency 196.IBPluginDependency 197.IBPluginDependency @@ -2641,6 +2519,8 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 231.ImportedFromIB2 234.IBPluginDependency 235.IBPluginDependency + 236.IBPluginDependency + 236.ImportedFromIB2 25.IBPluginDependency 25.ImportedFromIB2 26.IBPluginDependency @@ -2747,18 +2627,6 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA 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 @@ -2835,10 +2703,12 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA com.apple.InterfaceBuilder.CocoaPlugin - {{302, 299}, {484, 557}} com.apple.InterfaceBuilder.CocoaPlugin - {{302, 299}, {484, 557}} + {{497, 299}, {484, 557}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{497, 299}, {484, 557}} {{221, 276}, {533, 580}} @@ -2877,7 +2747,7 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA - 235 + 239 @@ -2949,7 +2819,7 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA fDeblockCheck fDeblockField fDeblockSlider - fDecombPopUp + fDecombCheck fDeinterlacePopUp fDenoisePopUp fDetelecineCheck @@ -2985,7 +2855,7 @@ AAB0ZXh0AAAAAENvcHlyaWdodCBBcHBsZSBDb21wdXRlciwgSW5jLiwgMjAwNQAAAAA NSButton NSTextField NSSlider - NSPopUpButton + NSButton NSPopUpButton NSPopUpButton NSButton diff --git a/macosx/English.lproj/Preferences.xib b/macosx/English.lproj/Preferences.xib index 1602d5db9..4c88164b0 100644 --- a/macosx/English.lproj/Preferences.xib +++ b/macosx/English.lproj/Preferences.xib @@ -8,7 +8,7 @@ 352.00 YES - + YES @@ -148,7 +148,7 @@ 6 System controlTextColor - + 3 MAA @@ -353,50 +353,20 @@ NSControl - + 256 YES - - - 268 - {{207, 40}, {208, 22}} - - YES - - -1804468671 - 272630784 - - - - YES - - 6 - System - textBackgroundColor - - 3 - MQA - - - - 6 - System - textColor - - - - 268 - {{47, 42}, {155, 17}} + {{34, 42}, {432, 17}} YES 67239488 - 71304192 - Custom Decomb String: + 138413056 + Nothing here right now, but I am sure we will think of something @@ -405,6 +375,7 @@ {496, 82} + NSView NSResponder @@ -442,7 +413,15 @@ YES - + + 6 + System + textBackgroundColor + + 3 + MQA + + 10 YES @@ -719,7 +698,7 @@ NSResponder - + 256 YES @@ -904,7 +883,6 @@ {486, 123} - NSView @@ -1106,26 +1084,6 @@ 323 - - - value: values.DecombCustomString - - - - - - value: values.DecombCustomString - value - values.DecombCustomString - - NSContinuouslyUpdatesValue - - - 2 - - - 330 - value: values.EncodeLogLocation @@ -1308,7 +1266,6 @@ YES - Picture @@ -1509,20 +1466,6 @@ Application - - 324 - - - YES - - - - - - 325 - - - 326 @@ -1701,8 +1644,6 @@ 295.ImportedFromIB2 296.IBPluginDependency 296.ImportedFromIB2 - 324.IBPluginDependency - 325.IBPluginDependency 326.IBPluginDependency 327.IBPluginDependency 347.IBPluginDependency @@ -1737,7 +1678,7 @@ com.apple.InterfaceBuilder.CocoaPlugin {{220, 300}, {492, 189}} com.apple.InterfaceBuilder.CocoaPlugin - + {{0, 636}, {500, 209}} {{144, 376}, {496, 82}} com.apple.InterfaceBuilder.CocoaPlugin @@ -1796,8 +1737,6 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin diff --git a/macosx/HBPreferencesController.m b/macosx/HBPreferencesController.m index 7f2bc40f8..b51dacf8d 100644 --- a/macosx/HBPreferencesController.m +++ b/macosx/HBPreferencesController.m @@ -54,7 +54,6 @@ @"NO", @"DisableDvdAutoDetect", @"Alert Window", @"AlertWhenDone", @"1", @"LoggingLevel", - @"4:10:15:9:10:35:9", @"DecombCustomString", @"NO", @"EncodeLogLocation", @"10", @"PreviewsNumber", nil]]; diff --git a/macosx/PictureController.h b/macosx/PictureController.h index 6aa03f1a9..631a1d11c 100644 --- a/macosx/PictureController.h +++ b/macosx/PictureController.h @@ -37,7 +37,7 @@ IBOutlet NSTextField * fCropRightField; IBOutlet NSStepper * fCropRightStepper; IBOutlet NSPopUpButton * fDeinterlacePopUp; - IBOutlet NSPopUpButton * fDecombPopUp; + IBOutlet NSButton * fDecombCheck; IBOutlet NSButton * fDetelecineCheck; IBOutlet NSButton * fDeblockCheck; IBOutlet NSTextField * fDeblockField; diff --git a/macosx/PictureController.mm b/macosx/PictureController.mm index 7ba284f83..c0f5771af 100644 --- a/macosx/PictureController.mm +++ b/macosx/PictureController.mm @@ -161,6 +161,7 @@ [fDeinterlacePopUp selectItemAtIndex: fPictureFilterSettings.deinterlace]; [fDenoisePopUp selectItemAtIndex: fPictureFilterSettings.denoise]; [fDeblockCheck setState: fPictureFilterSettings.deblock]; + [fDecombCheck setState: fPictureFilterSettings.decomb]; fPicture = 0; MaxOutputWidth = title->width - job->crop[2] - job->crop[3]; @@ -191,13 +192,6 @@ are maintained across different sources */ /* Set denoises level according to the integer in the main window */ [fDenoisePopUp selectItemAtIndex: fPictureFilterSettings.denoise]; - /* we use a popup to show the decomb settings */ - [fDecombPopUp removeAllItems]; - [fDecombPopUp addItemWithTitle: @"None"]; - [fDecombPopUp addItemWithTitle: @"Default"]; - [fDecombPopUp addItemWithTitle: @"Custom"]; - /* Set denoises level according to the integer in the main window */ - [fDecombPopUp selectItemAtIndex: fPictureFilterSettings.decomb]; } @@ -417,7 +411,7 @@ are maintained across different sources */ fPictureFilterSettings.deblock = [fDeblockField intValue]; } - fPictureFilterSettings.decomb = [fDecombPopUp indexOfSelectedItem]; + fPictureFilterSettings.decomb = [fDecombCheck state]; if( job->keep_ratio ) { -- cgit v1.2.3