From f9552749148625b444f18243f650b6e580b5bcfd Mon Sep 17 00:00:00 2001 From: shaojiankui <6077782@qq.com> Date: Mon, 24 Nov 2014 07:30:30 +0800 Subject: [PATCH] fix in ios8,with and height exchange error fix in ios8,with and height exchange error --- Classes/MGSplitViewController.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Classes/MGSplitViewController.m b/Classes/MGSplitViewController.m index 09ffe17..9b337d2 100644 --- a/Classes/MGSplitViewController.m +++ b/Classes/MGSplitViewController.m @@ -241,7 +241,8 @@ - (CGSize)splitViewSizeForOrientation:(UIInterfaceOrientation)theOrientation float height = fullScreenRect.size.height; // Correct for orientation. - if (UIInterfaceOrientationIsLandscape(theOrientation)) { + //fix in ios8,with and height exchange error + if ([[[UIDevice currentDevice]systemVersion] floatValue] < 8.0 && UIInterfaceOrientationIsLandscape(theOrientation)) { width = height; height = fullScreenRect.size.width; }