mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-29 11:25:38 +00:00
Fix iPad rotation
This commit is contained in:
parent
ece4f6ed86
commit
c16de1fcd9
@ -172,7 +172,7 @@ private final class CallVideoNode: ASDisplayNode {
|
|||||||
self.currentCornerRadius = cornerRadius
|
self.currentCornerRadius = cornerRadius
|
||||||
|
|
||||||
var rotationAngle: CGFloat
|
var rotationAngle: CGFloat
|
||||||
if isOutgoing {
|
if isOutgoing && isCompactLayout {
|
||||||
rotationAngle = CGFloat.pi / 2.0
|
rotationAngle = CGFloat.pi / 2.0
|
||||||
} else {
|
} else {
|
||||||
switch self.currentOrientation {
|
switch self.currentOrientation {
|
||||||
@ -181,9 +181,17 @@ private final class CallVideoNode: ASDisplayNode {
|
|||||||
case .rotation90:
|
case .rotation90:
|
||||||
rotationAngle = CGFloat.pi / 2.0
|
rotationAngle = CGFloat.pi / 2.0
|
||||||
case .rotation180:
|
case .rotation180:
|
||||||
|
if isCompactLayout {
|
||||||
rotationAngle = CGFloat.pi
|
rotationAngle = CGFloat.pi
|
||||||
|
} else {
|
||||||
|
rotationAngle = 0.0
|
||||||
|
}
|
||||||
case .rotation270:
|
case .rotation270:
|
||||||
|
if isCompactLayout {
|
||||||
rotationAngle = -CGFloat.pi / 2.0
|
rotationAngle = -CGFloat.pi / 2.0
|
||||||
|
} else {
|
||||||
|
rotationAngle = CGFloat.pi / 2.0
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var additionalAngle: CGFloat = 0.0
|
var additionalAngle: CGFloat = 0.0
|
||||||
|
|||||||
@ -1 +1 @@
|
|||||||
Subproject commit 744762e065ddcde3a20c1c434fcc7c456aac3126
|
Subproject commit b906b5a955f1e6e195cb91c4513d4cb7b3620ea6
|
||||||
Loading…
x
Reference in New Issue
Block a user