Allow media viewer to be rotated to any orientation
This commit is contained in:
parent
e0d53efecc
commit
0910baab6c
|
@ -165,6 +165,10 @@ extension MediaPreviewViewController {
|
|||
!viewModel.showingChrome
|
||||
}
|
||||
|
||||
override var supportedInterfaceOrientations: UIInterfaceOrientationMask {
|
||||
.all
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
extension MediaPreviewViewController {
|
||||
|
|
|
@ -369,6 +369,9 @@ extension MainTabBarController {
|
|||
updateAvatarButtonAppearance()
|
||||
}
|
||||
|
||||
override var supportedInterfaceOrientations: UIInterfaceOrientationMask {
|
||||
return UIDevice.current.userInterfaceIdiom == .phone ? .portrait : .all
|
||||
}
|
||||
}
|
||||
|
||||
extension MainTabBarController {
|
||||
|
|
|
@ -112,6 +112,10 @@ extension RootSplitViewController {
|
|||
|
||||
self.updateBehavior(size: size)
|
||||
}
|
||||
|
||||
override var supportedInterfaceOrientations: UIInterfaceOrientationMask {
|
||||
return UIDevice.current.userInterfaceIdiom == .phone ? .portrait : .all
|
||||
}
|
||||
|
||||
override func traitCollectionDidChange(_ previousTraitCollection: UITraitCollection?) {
|
||||
super.traitCollectionDidChange(previousTraitCollection)
|
||||
|
|
|
@ -64,13 +64,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||
}
|
||||
|
||||
extension AppDelegate {
|
||||
func application(_ application: UIApplication, supportedInterfaceOrientationsFor window: UIWindow?) -> UIInterfaceOrientationMask {
|
||||
return UIDevice.current.userInterfaceIdiom == .phone ? .portrait : .all
|
||||
}
|
||||
}
|
||||
|
||||
extension AppDelegate {
|
||||
|
||||
func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
|
||||
appContext.notificationService.deviceToken.value = deviceToken
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue