mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-30 09:21:28 +00:00
Various fixes
This commit is contained in:
parent
bcbff3a32d
commit
4251ee2c1b
@ -7558,6 +7558,7 @@ Sorry for the inconvenience.";
|
|||||||
"Chat.MultipleTypingMore" = "%@ and %@ others";
|
"Chat.MultipleTypingMore" = "%@ and %@ others";
|
||||||
|
|
||||||
"Group.Username.RemoveExistingUsernamesOrExtendInfo" = "You have reserved too many public links. Try revoking a link from an older group or channel, or upgrade to **Telegram Premium** to double the limit to **%@** public links.";
|
"Group.Username.RemoveExistingUsernamesOrExtendInfo" = "You have reserved too many public links. Try revoking a link from an older group or channel, or upgrade to **Telegram Premium** to double the limit to **%@** public links.";
|
||||||
|
"Group.Username.RemoveExistingUsernamesNoPremiumInfo" = "You have reserved too many public links. Try revoking the link from an older group or channel. We are working to let you increase this limit in the future.";
|
||||||
"Group.Username.RemoveExistingUsernamesFinalInfo" = "You have reserved too many public links. Try revoking the link from an older group or channel, or create a private one instead.";
|
"Group.Username.RemoveExistingUsernamesFinalInfo" = "You have reserved too many public links. Try revoking the link from an older group or channel, or create a private one instead.";
|
||||||
|
|
||||||
"OldChannels.TooManyCommunitiesText" = "You are a member of **%@** groups and channels. Please leave some before joining a new one or upgrade to **Telegram Premium** to double the limit to **%@** groups and channels.";
|
"OldChannels.TooManyCommunitiesText" = "You are a member of **%@** groups and channels. Please leave some before joining a new one or upgrade to **Telegram Premium** to double the limit to **%@** groups and channels.";
|
||||||
|
@ -910,7 +910,6 @@ open class NavigationController: UINavigationController, ContainableController,
|
|||||||
visibleRootModalDismissProgress = effectiveRootModalDismissProgress
|
visibleRootModalDismissProgress = effectiveRootModalDismissProgress
|
||||||
additionalModalFrameProgress = 1.0 - topModalDismissProgress
|
additionalModalFrameProgress = 1.0 - topModalDismissProgress
|
||||||
} else {
|
} else {
|
||||||
// effectiveRootModalDismissProgress = ((topModalIsFlat && !topFlatModalHasProgress) || isLandscape) ? 1.0 : topModalDismissProgress
|
|
||||||
effectiveRootModalDismissProgress = topModalDismissProgress
|
effectiveRootModalDismissProgress = topModalDismissProgress
|
||||||
visibleRootModalDismissProgress = effectiveRootModalDismissProgress
|
visibleRootModalDismissProgress = effectiveRootModalDismissProgress
|
||||||
additionalModalFrameProgress = 0.0
|
additionalModalFrameProgress = 0.0
|
||||||
|
@ -730,7 +730,19 @@ private func channelVisibilityControllerEntries(presentationData: PresentationDa
|
|||||||
|
|
||||||
if case .revokeNames = mode {
|
if case .revokeNames = mode {
|
||||||
let count = Int32(publicChannelsToRevoke?.count ?? 0)
|
let count = Int32(publicChannelsToRevoke?.count ?? 0)
|
||||||
entries.append(.linksLimitInfo(presentationData.theme, presentationData.strings.Group_Username_RemoveExistingUsernamesOrExtendInfo("\(premiumLimits.maxPublicLinksCount)").string, count, limits.maxPublicLinksCount, premiumLimits.maxPublicLinksCount, isPremiumDisabled))
|
|
||||||
|
let text: String
|
||||||
|
if count >= premiumLimits.maxPublicLinksCount {
|
||||||
|
text = presentationData.strings.Group_Username_RemoveExistingUsernamesFinalInfo
|
||||||
|
} else {
|
||||||
|
if isPremiumDisabled {
|
||||||
|
text = presentationData.strings.Group_Username_RemoveExistingUsernamesNoPremiumInfo
|
||||||
|
} else {
|
||||||
|
text = presentationData.strings.Group_Username_RemoveExistingUsernamesOrExtendInfo("\(premiumLimits.maxPublicLinksCount)").string
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
entries.append(.linksLimitInfo(presentationData.theme, text, count, limits.maxPublicLinksCount, premiumLimits.maxPublicLinksCount, isPremiumDisabled))
|
||||||
|
|
||||||
if let publicChannelsToRevoke = publicChannelsToRevoke {
|
if let publicChannelsToRevoke = publicChannelsToRevoke {
|
||||||
var index: Int32 = 0
|
var index: Int32 = 0
|
||||||
|
@ -1624,7 +1624,7 @@ private final class PremiumIntroScreenComponent: CombinedComponent {
|
|||||||
titleScale = 1.0 - fraction * 0.36
|
titleScale = 1.0 - fraction * 0.36
|
||||||
|
|
||||||
if state.otherPeerName != nil {
|
if state.otherPeerName != nil {
|
||||||
titleAlpha = min(1.0, fraction * 1.5)
|
titleAlpha = min(1.0, fraction * 1.1)
|
||||||
} else {
|
} else {
|
||||||
titleAlpha = 1.0
|
titleAlpha = 1.0
|
||||||
}
|
}
|
||||||
@ -1658,7 +1658,7 @@ private final class PremiumIntroScreenComponent: CombinedComponent {
|
|||||||
context.add(secondaryTitle
|
context.add(secondaryTitle
|
||||||
.position(CGPoint(x: context.availableSize.width / 2.0, y: max(topInset + 160.0 - titleOffset, environment.statusBarHeight + (environment.navigationHeight - environment.statusBarHeight) / 2.0)))
|
.position(CGPoint(x: context.availableSize.width / 2.0, y: max(topInset + 160.0 - titleOffset, environment.statusBarHeight + (environment.navigationHeight - environment.statusBarHeight) / 2.0)))
|
||||||
.scale(titleScale)
|
.scale(titleScale)
|
||||||
.opacity(1.0 - titleAlpha)
|
.opacity(max(0.0, 1.0 - titleAlpha * 1.8))
|
||||||
)
|
)
|
||||||
|
|
||||||
if state.isPremium == true {
|
if state.isPremium == true {
|
||||||
|
@ -281,10 +281,12 @@ class PremiumStarComponent: Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private func maybeAnimateIn() {
|
private func maybeAnimateIn() {
|
||||||
guard let scene = self.sceneView.scene, let node = scene.rootNode.childNode(withName: "star", recursively: false), let animateFrom = self.animateFrom, let containerView = self.containerView else {
|
guard let scene = self.sceneView.scene, let node = scene.rootNode.childNode(withName: "star", recursively: false), let animateFrom = self.animateFrom, var containerView = self.containerView else {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
containerView = containerView.subviews[2].subviews[1]
|
||||||
|
|
||||||
if let animationColor = self.animationColor {
|
if let animationColor = self.animationColor {
|
||||||
let newNode = node.clone()
|
let newNode = node.clone()
|
||||||
newNode.geometry = node.geometry?.copy() as? SCNGeometry
|
newNode.geometry = node.geometry?.copy() as? SCNGeometry
|
||||||
@ -323,6 +325,9 @@ class PremiumStarComponent: Component {
|
|||||||
self.sceneView.layer.animatePosition(from: sourcePosition, to: targetPosition, duration: 1.0, timingFunction: kCAMediaTimingFunctionSpring, completion: { _ in
|
self.sceneView.layer.animatePosition(from: sourcePosition, to: targetPosition, duration: 1.0, timingFunction: kCAMediaTimingFunctionSpring, completion: { _ in
|
||||||
self.addSubview(self.sceneView)
|
self.addSubview(self.sceneView)
|
||||||
self.sceneView.center = initialPosition
|
self.sceneView.center = initialPosition
|
||||||
|
})
|
||||||
|
|
||||||
|
Queue.mainQueue().after(0.4, {
|
||||||
animateFrom.alpha = 1.0
|
animateFrom.alpha = 1.0
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user