mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-02 20:55:48 +00:00
Add tooltips for removal success in Data Settings screen
This commit is contained in:
parent
7382d413a6
commit
c9bda0cecd
@ -5741,6 +5741,7 @@ Sorry for the inconvenience.";
|
||||
|
||||
"Notification.VoiceChatStarted" = "%1$@ started a voice chat";
|
||||
"Notification.VoiceChatEnded" = "Voice chat ended (%@)";
|
||||
"Notification.VoiceChatEndedGroup" = "%1$@ ended the voice chat (%2$@)";
|
||||
|
||||
"VoiceChat.Panel.TapToJoin" = "Tap to join";
|
||||
"VoiceChat.Panel.Members_0" = "%@ participants";
|
||||
@ -6446,3 +6447,13 @@ Sorry for the inconvenience.";
|
||||
"VoiceChat.ReminderNotify" = "We will notify you when it starts.";
|
||||
|
||||
"Checkout.SuccessfulTooltip" = "You paid %1$@ for %2$@.";
|
||||
|
||||
|
||||
"Privacy.ContactsReset.ContactsDeleted" = "All synced contacts deleted.";
|
||||
|
||||
"Privacy.DeleteDrafts.DraftsDeleted" = "All cloud drafts deleted.";
|
||||
|
||||
"Privacy.PaymentsClear.PaymentInfoCleared" = "Payment info cleared.";
|
||||
"Privacy.PaymentsClear.ShippingInfoCleared" = "Shipping info cleared.";
|
||||
"Privacy.PaymentsClear.AllInfoCleared" = "Payment and shipping info cleared.";
|
||||
|
||||
|
||||
@ -9,11 +9,11 @@ import TelegramPresentationData
|
||||
import TelegramUIPreferences
|
||||
import ItemListUI
|
||||
import PresentationDataUtils
|
||||
import OverlayStatusController
|
||||
import AccountContext
|
||||
import AlertUI
|
||||
import PresentationDataUtils
|
||||
import TelegramNotices
|
||||
import UndoUI
|
||||
|
||||
private final class DataPrivacyControllerArguments {
|
||||
let account: Account
|
||||
@ -368,7 +368,19 @@ public func dataPrivacyController(context: AccountContext) -> ViewController {
|
||||
return state
|
||||
}
|
||||
let presentationData = context.sharedContext.currentPresentationData.with { $0 }
|
||||
presentControllerImpl?(OverlayStatusController(theme: presentationData.theme, type: .success))
|
||||
let text: String?
|
||||
if info.contains([.paymentInfo, .shippingInfo]) {
|
||||
text = presentationData.strings.Privacy_PaymentsClear_AllInfoCleared
|
||||
} else if info.contains(.paymentInfo) {
|
||||
text = presentationData.strings.Privacy_PaymentsClear_PaymentInfoCleared
|
||||
} else if info.contains(.shippingInfo) {
|
||||
text = presentationData.strings.Privacy_PaymentsClear_ShippingInfoCleared
|
||||
} else {
|
||||
text = nil
|
||||
}
|
||||
if let text = text {
|
||||
presentControllerImpl?(UndoOverlayController(presentationData: presentationData, content: .succeed(text: text), elevatedLayout: false, action: { _ in return false }))
|
||||
}
|
||||
}))
|
||||
}
|
||||
dismissAction()
|
||||
@ -422,7 +434,7 @@ public func dataPrivacyController(context: AccountContext) -> ViewController {
|
||||
return state
|
||||
}
|
||||
let presentationData = context.sharedContext.currentPresentationData.with { $0 }
|
||||
presentControllerImpl?(OverlayStatusController(theme: presentationData.theme, type: .success))
|
||||
presentControllerImpl?(UndoOverlayController(presentationData: presentationData, content: .succeed(text: presentationData.strings.Privacy_ContactsSync_ContactsDeleted), elevatedLayout: false, action: { _ in return false }))
|
||||
}))
|
||||
}), TextAlertAction(type: .defaultAction, title: presentationData.strings.Common_Cancel, action: {})]))
|
||||
}
|
||||
@ -478,7 +490,7 @@ public func dataPrivacyController(context: AccountContext) -> ViewController {
|
||||
return state
|
||||
}
|
||||
let presentationData = context.sharedContext.currentPresentationData.with { $0 }
|
||||
presentControllerImpl?(OverlayStatusController(theme: presentationData.theme, type: .success))
|
||||
presentControllerImpl?(UndoOverlayController(presentationData: presentationData, content: .succeed(text: presentationData.strings.Privacy_DeleteDrafts_DraftsDeleted), elevatedLayout: false, action: { _ in return false }))
|
||||
}))
|
||||
}
|
||||
dismissAction()
|
||||
@ -530,7 +542,7 @@ public func dataPrivacyController(context: AccountContext) -> ViewController {
|
||||
|
||||
let controller = ItemListController(context: context, state: signal)
|
||||
presentControllerImpl = { [weak controller] c in
|
||||
controller?.present(c, in: .window(.root), with: ViewControllerPresentationArguments(presentationAnimation: .modalSheet))
|
||||
controller?.present(c, in: .window(.root))
|
||||
}
|
||||
|
||||
return controller
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user