mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2026-01-06 05:02:54 +00:00
Add phone number validation block removal animation
This commit is contained in:
@@ -143,7 +143,7 @@ public final class ChangePhoneNumberIntroController: ViewController {
|
||||
}
|
||||
|
||||
func proceed() {
|
||||
self.present(textAlertController(context: self.context, title: nil, text: self.presentationData.strings.PhoneNumberHelp_Alert, actions: [TextAlertAction(type: .defaultAction, title: self.presentationData.strings.Common_Cancel, action: {}), TextAlertAction(type: .genericAction, title: self.presentationData.strings.Common_OK, action: { [weak self] in
|
||||
self.present(textAlertController(context: self.context, title: nil, text: self.presentationData.strings.PhoneNumberHelp_Alert, actions: [TextAlertAction(type: .defaultAction, title: self.presentationData.strings.Common_Cancel, action: {}), TextAlertAction(type: .genericAction, title: self.presentationData.strings.TwoFactorSetup_Email_Action, action: { [weak self] in
|
||||
if let strongSelf = self {
|
||||
(strongSelf.navigationController as? NavigationController)?.replaceTopController(ChangePhoneNumberController(context: strongSelf.context), animated: true)
|
||||
}
|
||||
|
||||
@@ -2925,7 +2925,7 @@ private final class PeerInfoScreenNode: ViewControllerTracingNode, UIScrollViewD
|
||||
var currentCallsPrivate: Bool?
|
||||
var previousVideoCallsAvailable: Bool? = true
|
||||
var currentVideoCallsAvailable: Bool?
|
||||
|
||||
|
||||
if let previousCachedData = previousData?.cachedData as? CachedUserData, let cachedData = data.cachedData as? CachedUserData {
|
||||
previousCallsPrivate = previousCachedData.callsPrivate ?? false
|
||||
currentCallsPrivate = cachedData.callsPrivate
|
||||
@@ -2934,10 +2934,12 @@ private final class PeerInfoScreenNode: ViewControllerTracingNode, UIScrollViewD
|
||||
currentVideoCallsAvailable = cachedData.videoCallsAvailable
|
||||
}
|
||||
|
||||
if let previousSuggestPhoneNumberConfirmation = previousData?.globalSettings?.suggestPhoneNumberConfirmation, previousSuggestPhoneNumberConfirmation != data.globalSettings?.suggestPhoneNumberConfirmation {
|
||||
infoUpdated = true
|
||||
}
|
||||
if previousCallsPrivate != currentCallsPrivate || previousVideoCallsAvailable != currentVideoCallsAvailable {
|
||||
infoUpdated = true
|
||||
}
|
||||
|
||||
if (previousCall == nil) != (currentCall == nil) {
|
||||
infoUpdated = true
|
||||
}
|
||||
@@ -5869,7 +5871,9 @@ private final class PeerInfoScreenNode: ViewControllerTracingNode, UIScrollViewD
|
||||
}
|
||||
for sectionId in removeRegularSections {
|
||||
if let sectionNode = self.regularSections.removeValue(forKey: sectionId) {
|
||||
sectionNode.removeFromSupernode()
|
||||
transition.updateAlpha(node: sectionNode, alpha: 0.0, completion: { [weak sectionNode] _ in
|
||||
sectionNode?.removeFromSupernode()
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user