All pastes #715828 Raw Edit

Mine

public text v1 · immutable
#715828 ·published 2007-09-26 14:31 UTC
rendered paste body
Index: macosx/Controller.mm
===================================================================
--- macosx/Controller.mm	(revision 990)
+++ macosx/Controller.mm	(working copy)
@@ -1074,6 +1074,7 @@
 	   }
        
 	}
+    
 }
 
 -(IBAction)showGrowlDoneNotification:(id)sender
@@ -2006,6 +2007,24 @@
 	[self audioTrackPopUpChanged: fAudLang2PopUp];
 	/* lets call tableViewSelected to make sure that any preset we have selected is enforced after a title change */
 	[self tableViewSelected:NULL];
+    
+        /* Set the default framerate according to whats detected */
+    if (fTitle->rate_base == 1126125) // 23.976 NTSC Film
+    {
+    [fVidRatePopUp selectItemAtIndex: 5];
+    }
+    else if (fTitle->rate_base == 1080000) // 25 PAL Film/Video
+    {
+    [fVidRatePopUp selectItemAtIndex: 7];
+    }
+    else if (fTitle->rate_base == 900900) // 29.97 NTSC Video
+    {
+    [fVidRatePopUp selectItemAtIndex: 8];
+    }
+    else
+    {
+    [fVidRatePopUp selectItemAtIndex: 0]; // Garbage Collect into "Same as Source".
+    }
 }
 
 - (IBAction) chapterPopUpChanged: (id) sender
@@ -4334,8 +4353,9 @@
 			[fVidQualitySlider setFloatValue: [[chosenPreset valueForKey:@"VideoQualitySlider"] floatValue]];
 			[self videoMatrixChanged: NULL];
 			
-			/* Video framerate */
-			[fVidRatePopUp selectItemWithTitle: [NSString stringWithFormat:[chosenPreset valueForKey:@"VideoFramerate"]]];
+			/* Video framerate we no longer set the video framerate according to the popup
+               But, lets leave it here commented out in case we think of another, more graceful way to handle it*/
+			//[fVidRatePopUp selectItemWithTitle: [NSString stringWithFormat:[chosenPreset valueForKey:@"VideoFramerate"]]];
 			
 			/* GrayScale */
 			[fVidGrayscaleCheck setState:[[chosenPreset objectForKey:@"VideoGrayScale"] intValue]];