diff options
author | Rodeo <[email protected]> | 2013-04-12 20:14:05 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2013-04-12 20:14:05 +0000 |
commit | 3d9d937ed4c21aa6ffde4710d044de71fc54330e (patch) | |
tree | 9ef03cf51f8572e092e4e57cd83cdab420af90ec /macosx/Controller.m | |
parent | da8a0f3ace2b71ef1cbb911d194dd1f9561017b0 (diff) |
MacGui: simplify queue display code.
Add detailed summaries to the queue item dictionary and use them in HBQueueController.
This helps remove a lot of duplicate logic.
Uses existing methods pictureSettingsSummary, pictureFiltersSummary and new muxerOptionsSummary.
Also add a few height rows for long lines that often wrap to a second row.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5398 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx/Controller.m')
-rw-r--r-- | macosx/Controller.m | 45 |
1 files changed, 34 insertions, 11 deletions
diff --git a/macosx/Controller.m b/macosx/Controller.m index f0b20f379..893e65473 100644 --- a/macosx/Controller.m +++ b/macosx/Controller.m @@ -2664,17 +2664,14 @@ fWorkingCount = 0; [queueFileJob setObject:[NSNumber numberWithFloat:fTitle->job->anamorphic.dar_height] forKey:@"PicturePARDisplayHeight"]; } - - /* Summary for the queue display */ - NSString *pictureSizingSummary = [NSString stringWithFormat:@"%@", - [fPictureController getPictureSizeInfoString]]; - if (fTitle->job->anamorphic.mode != 1) - { - pictureSizingSummary = [pictureSizingSummary - stringByAppendingFormat:@", Modulus: %d", - fTitle->job->modulus]; - } - [queueFileJob setObject:pictureSizingSummary forKey:@"PictureSizingSummary"]; + + /* Text summaries of various settings */ + [queueFileJob setObject:[NSString stringWithString:[self pictureSettingsSummary]] + forKey:@"PictureSettingsSummary"]; + [queueFileJob setObject:[NSString stringWithString:[self pictureFiltersSummary]] + forKey:@"PictureFiltersSummary"]; + [queueFileJob setObject:[NSString stringWithString:[self muxerOptionsSummary]] + forKey:@"MuxerOptionsSummary"]; /* Set crop settings here */ [queueFileJob setObject:[NSNumber numberWithInt:[fPictureController autoCrop]] forKey:@"PictureAutoCrop"]; @@ -5889,6 +5886,32 @@ the user is using "Custom" settings by determining the sender*/ return [NSString stringWithString:summary]; } +- (NSString*) muxerOptionsSummary +{ + NSMutableString *summary = [NSMutableString stringWithString:@""]; + if (([fDstFormatPopUp selectedItem]) && + [[fDstFormatPopUp selectedItem] tag] == HB_MUX_MP4) + { + if ([fDstMp4LargeFileCheck state]) + { + [summary appendString:@" - Large file size"]; + } + if ([fDstMp4HttpOptFileCheck state]) + { + [summary appendString:@" - Web optimized"]; + } + if ([fDstMp4iPodFileCheck state]) + { + [summary appendString:@" - iPod 5G support"]; + } + } + if ([summary hasPrefix:@" - "]) + { + [summary deleteCharactersInRange:NSMakeRange(0, 3)]; + } + return [NSString stringWithString:summary]; +} + #pragma mark - #pragma mark - Audio and Subtitles |