Skip to content

Commit

Permalink
Fix an issue that the alert will disappear when a keyboard is present…
Browse files Browse the repository at this point in the history
…ed in iOS 8 (landscpe)
  • Loading branch information
oscarfung committed Apr 29, 2015
1 parent 8659198 commit 6e0360d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ - (void)keyboardWillShow: (NSNotification *)notification
CGSize keyboardSize = [[[notification userInfo] objectForKey:UIKeyboardFrameBeginUserInfoKey] CGRectValue].size;

UIInterfaceOrientation interfaceOrientation = [[UIApplication sharedApplication] statusBarOrientation];
if (UIInterfaceOrientationIsLandscape(interfaceOrientation)) {
if (UIInterfaceOrientationIsLandscape(interfaceOrientation) && NSFoundationVersionNumber <= NSFoundationVersionNumber_iOS_7_1) {
CGFloat tmp = keyboardSize.height;
keyboardSize.height = keyboardSize.width;
keyboardSize.width = tmp;
Expand Down

0 comments on commit 6e0360d

Please sign in to comment.