fix rotated
This commit is contained in:
@@ -211,19 +211,12 @@ open class ContainerController: NSObject {
|
||||
@objc func rotated() {
|
||||
|
||||
let orint = UIDevice.current.orientation
|
||||
if orint == .faceUp || orint == .faceDown { return }
|
||||
if orint == .faceUp || orint == .faceDown || orint == .portraitUpsideDown { return }
|
||||
|
||||
if ContainerDevice.orientation == oldOrientation { return }
|
||||
oldOrientation = ContainerDevice.orientation
|
||||
|
||||
if isPortrait {
|
||||
shadowButton.isHidden = !layout.backgroundShadowShow
|
||||
} else {
|
||||
if let landscapeShadowShow = layout.landscapeBackgroundShadowShow {
|
||||
shadowButton.isHidden = !landscapeShadowShow
|
||||
} else {
|
||||
shadowButton.isHidden = !layout.backgroundShadowShow
|
||||
}
|
||||
}
|
||||
shadowHiddenCheck()
|
||||
|
||||
delegate?.containerControllerRotation(self)
|
||||
|
||||
@@ -870,7 +863,7 @@ open class ContainerController: NSObject {
|
||||
|
||||
}
|
||||
|
||||
func shadowLevelAlpha(positionY: CGFloat) {
|
||||
func shadowHiddenCheck() {
|
||||
|
||||
if isPortrait {
|
||||
shadowButton.isHidden = !layout.backgroundShadowShow
|
||||
@@ -881,6 +874,11 @@ open class ContainerController: NSObject {
|
||||
shadowButton.isHidden = !layout.backgroundShadowShow
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func shadowLevelAlpha(positionY: CGFloat) {
|
||||
|
||||
shadowHiddenCheck()
|
||||
|
||||
let alphaMax: CGFloat = 0.45
|
||||
|
||||
|
||||
@@ -108,6 +108,10 @@ class MapsViewController: StoryboardController, MapsContainerControllerDelegate,
|
||||
// MARK: - Rotation Callback
|
||||
|
||||
@objc func rotated() {
|
||||
|
||||
let orint = UIDevice.current.orientation
|
||||
if orint == .faceUp || orint == .faceDown || orint == .portraitUpsideDown { return }
|
||||
|
||||
updateMapViewTopPadding()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user