fix: Initial glitch when picking a photo in upside-down orientation

This was caused by OWSViewController.IsLandscapeOrientationEnabled being
hard-coded to return `NO`. Now, whether or not landscape orientation is
enabled will be based on whether the current device is an iPad.
pull/864/head
Arshak Aghakaryan 2 years ago
parent fbdb1ad690
commit 57dbad7e2e

@ -11,12 +11,12 @@ NS_ASSUME_NONNULL_BEGIN
BOOL IsLandscapeOrientationEnabled(void) BOOL IsLandscapeOrientationEnabled(void)
{ {
return NO; return UIDevice.currentDevice.isIPad;
} }
UIInterfaceOrientationMask DefaultUIInterfaceOrientationMask(void) UIInterfaceOrientationMask DefaultUIInterfaceOrientationMask(void)
{ {
return (IsLandscapeOrientationEnabled() ? UIInterfaceOrientationMaskAllButUpsideDown return (IsLandscapeOrientationEnabled() ? UIInterfaceOrientationMaskAll
: UIInterfaceOrientationMaskPortrait); : UIInterfaceOrientationMaskPortrait);
} }

Loading…
Cancel
Save