]> granicus.if.org Git - handbrake/commitdiff
MacGui: fix autocrop.
authorritsuka <damiog@gmail.com>
Fri, 1 May 2015 15:13:00 +0000 (15:13 +0000)
committerritsuka <damiog@gmail.com>
Fri, 1 May 2015 15:13:00 +0000 (15:13 +0000)
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7144 b64f7644-9d1e-0410-96f1-a4d463321fa5

macosx/HBPicture.m

index 8c83d91fc108d46355219495fbd33a5c78406ec7..68ae97b5af527163ef45ed9b9f4a7eb09641e3f9 100644 (file)
@@ -61,14 +61,21 @@ NSString * const HBPictureChangedNotification = @"HBPictureChangedNotification";
     self = [self init];
     if (self)
     {
-        _width = title.hb_title->geometry.width;
-        _height = title.hb_title->geometry.height;
+        hb_title_t *hb_title = title.hb_title;
 
-        _sourceWidth = title.hb_title->geometry.width;
-        _sourceHeight = title.hb_title->geometry.height;
+        _width = hb_title->geometry.width;
+        _height = hb_title->geometry.height;
 
-        _sourceParNum = title.hb_title->geometry.par.num;
-        _sourceParDen = title.hb_title->geometry.par.den;
+        _sourceWidth = hb_title->geometry.width;
+        _sourceHeight = hb_title->geometry.height;
+
+        _sourceParNum = hb_title->geometry.par.num;
+        _sourceParDen = hb_title->geometry.par.den;
+
+        _autoCropTop    = hb_title->crop[0];
+        _autoCropBottom = hb_title->crop[1];
+        _autoCropLeft   = hb_title->crop[2];
+        _autoCropRight  = hb_title->crop[3];
 
         [self validateSettings];