Update submodules

This commit is contained in:
Peter 2018-12-18 08:34:14 +03:00
parent a42039186a
commit 7f9b63838d
12 changed files with 42 additions and 9 deletions

View File

@ -117,7 +117,7 @@ class ShareRootController: UIViewController {
setupSharedLogger(logsPath)
let applicationBindings = TelegramApplicationBindings(isMainApp: false, containerPath: appGroupUrl.path, openUrl: { _ in
let applicationBindings = TelegramApplicationBindings(isMainApp: false, containerPath: appGroupUrl.path, appSpecificScheme: BuildConfig.shared().appSpecificUrlScheme, openUrl: { _ in
}, openUniversalUrl: { _, completion in
completion.completion(false)
return
@ -186,6 +186,7 @@ class ShareRootController: UIViewController {
|> introduceError(ShareAuthorizationError.self)
|> map { dataAndSettings, data -> (Account, PostboxAccessChallengeData) in
accountCache = (account, accountManager)
updateLegacyLocalization(strings: dataAndSettings.presentationData.strings)
account.applicationContext = TelegramApplicationContext(applicationBindings: applicationBindings, accountManager: accountManager, account: account, initialPresentationDataAndSettings: dataAndSettings, postbox: account.postbox)
return (account, (data.views[.accessChallengeData] as! AccessChallengeDataView).data)
}

View File

@ -497,7 +497,7 @@ private enum QueuedWakeup: Int32 {
return managedCleanupAccounts(networkArguments: networkArguments, accountManager: manager, rootPath: rootPath, auxiliaryMethods: telegramAccountAuxiliaryMethods)
}).start()
let applicationBindings = TelegramApplicationBindings(isMainApp: true, containerPath: appGroupUrl.path, openUrl: { url in
let applicationBindings = TelegramApplicationBindings(isMainApp: true, containerPath: appGroupUrl.path, appSpecificScheme: BuildConfig.shared().appSpecificUrlScheme, openUrl: { url in
var parsedUrl = URL(string: url)
if let parsed = parsedUrl {
if parsed.scheme == nil || parsed.scheme!.isEmpty {

View File

@ -10,5 +10,6 @@
@property (nonatomic, readonly) bool isInternalBuild;
@property (nonatomic, readonly) bool isAppStoreBuild;
@property (nonatomic, readonly) int64_t appStoreId;
@property (nonatomic, strong, readonly) NSString * _Nonnull appSpecificUrlScheme;
@end

View File

@ -35,4 +35,8 @@
return APP_CONFIG_APPSTORE_ID;
}
- (NSString *)appSpecificUrlScheme {
return @(APP_SPECIFIC_URL_SCHEME);
}
@end

View File

@ -1,5 +1,6 @@
APP_NAME=Telegram Fork
APP_BUNDLE_ID=fork.telegram.Telegram-iOS
APP_SPECIFIC_URL_SCHEME=tg_fork
GLOBAL_CONSTANTS = APP_CONFIG_API_ID=94575 APP_CONFIG_API_HASH="\"a3406de8d171bb422bb6ddf3bbd800e2\"" APP_CONFIG_HOCKEYAPPID="\"\"" APP_CONFIG_IS_INTERNAL_BUILD=true APP_CONFIG_IS_APPSTORE_BUILD=false APP_CONFIG_APPSTORE_ID=0
GLOBAL_CONSTANTS = APP_CONFIG_API_ID=94575 APP_CONFIG_API_HASH="\"a3406de8d171bb422bb6ddf3bbd800e2\"" APP_CONFIG_HOCKEYAPPID="\"\"" APP_CONFIG_IS_INTERNAL_BUILD=true APP_CONFIG_IS_APPSTORE_BUILD=false APP_CONFIG_APPSTORE_ID=0 APP_SPECIFIC_URL_SCHEME="\"$(APP_SPECIFIC_URL_SCHEME)\""
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) $(GLOBAL_CONSTANTS)

View File

@ -42,6 +42,7 @@
<key>CFBundleURLSchemes</key>
<array>
<string>tg</string>
<string>$(APP_SPECIFIC_URL_SCHEME)</string>
</array>
</dict>
<dict>

View File

@ -61,7 +61,7 @@ func snapshotEnvironment(application: UIApplication, mainWindow: UIWindow, statu
}
}
let applicationBindings = TelegramApplicationBindings(isMainApp: true, containerPath: path, openUrl: { _ in
let applicationBindings = TelegramApplicationBindings(isMainApp: true, containerPath: path, appSpecificScheme: "tg", openUrl: { _ in
}, openUniversalUrl: { _, completion in
completion.completion(false)
}, canOpenUrl: { _ in

View File

@ -270,7 +270,9 @@
"Compose.TokenListPlaceholder" = "Whom would you like to message?";
"Compose.NewMessage" = "New Message";
"Compose.NewGroup" = "New Group";
"Compose.NewGroupTitle" = "New Group";
"Compose.NewEncryptedChat" = "New Secret Chat";
"Compose.NewEncryptedChatTitle" = "New Secret Chat";
"Compose.Create" = "Create";
// Contacts
@ -395,6 +397,7 @@
"Message.Contact" = "Contact";
"Message.File" = "File";
"Message.Sticker" = "Sticker";
"Message.StickerText" = "Sticker %@";
"Message.Audio" = "Voice Message";
"Message.ForwardedMessage" = "Forwarded Message\nFrom: %@";
"Message.Animation" = "GIF";
@ -583,6 +586,7 @@
"ChatSettings.AutomaticAudioDownload" = "AUTOMATIC AUDIO DOWNLOAD";
"ChatSettings.PrivateChats" = "Private Chats";
"ChatSettings.Groups" = "Groups";
"ChatSettings.Cache" = "Storage Usage";
// Usage
"Cache.Title" = "Storage Usage";
@ -736,6 +740,7 @@
"PrivacySettings.PrivacyTitle" = "PRIVACY";
"PrivacySettings.LastSeen" = "Last Seen";
"PrivacySettings.LastSeenTitle" = "Last Seen";
"PrivacySettings.LastSeenEverybody" = "Everybody";
"PrivacySettings.LastSeenContacts" = "My Contacts";
"PrivacySettings.LastSeenNobody" = "Nobody";
@ -3598,6 +3603,7 @@ Unused sets are archived when you add more.";
"WebSearch.RecentSearchPlaceholder" = "Your recent search queries will appear here";
"MessagePoll.LabelAnonymous" = "Anonymous Poll";
"MessagePoll.LabelClosed" = "Final Results";
"MessagePoll.VotedCount_0" = "%@ voted";
"MessagePoll.VotedCount_1" = "1 voted";
"MessagePoll.VotedCount_2" = "2 voted";
@ -3614,4 +3620,23 @@ Unused sets are archived when you add more.";
"CreatePoll.OptionsHeader" = "POLL OPTIONS";
"CreatePoll.OptionPlaceholder" = "Option";
"CreatePoll.AddOption" = "Add an Option";
"CreatePoll.OptionsInfo" = "You can add up to 10 options.";
"CreatePoll.AddMoreOptions_0" = "You can add %@ more options.";
"CreatePoll.AddMoreOptions_1" = "You can add 1 more option.";
"CreatePoll.AddMoreOptions_2" = "You can add 2 more options.";
"CreatePoll.AddMoreOptions_3_10" = "You can add %@ more options.";
"CreatePoll.AddMoreOptions_many" = "You can add %@ more options.";
"CreatePoll.AddMoreOptions_any" = "You can add %@ more options.";
"CreatePoll.AllOptionsAdded" = "You have added the maximum number of options.";
"CreatePoll.CancelConfirmation" = "Are you sure you want to discard this poll?";
"ForwardedPolls_1" = "Forwarded poll";
"ForwardedPolls_2" = "2 forwarded polls";
"ForwardedPolls_3_10" = "%@ forwarded polls";
"ForwardedPolls_any" = "%@ forwarded polls";
"ForwardedPolls_many" = "%@ forwarded polls";
"ForwardedPolls_0" = "%@ forwarded polls";
"Conversation.UnvotePoll" = "Unvote";
"Conversation.StopPoll" = "Stop Poll";

View File

@ -145,7 +145,7 @@ class TodayViewController: UIViewController, NCWidgetProviding {
for peer in peers {
let peerView = PeerView(account: account, peer: peer, tapped: { [weak self] in
if let strongSelf = self {
if let url = URL(string: "tg://localpeer?id=\(peer.id.toInt64())") {
if let url = URL(string: "\(BuildConfig.shared().appSpecificUrlScheme)://localpeer?id=\(peer.id.toInt64())") {
strongSelf.extensionContext?.open(url, completionHandler: nil)
}
}

@ -1 +1 @@
Subproject commit b4678360ae6a022e16d5e97f64cbda567490c36c
Subproject commit a751220feaf331f533d8d4afa8627fc0484fb2d9

@ -1 +1 @@
Subproject commit f207d30247500499a035db4cad309cb6aacc2941
Subproject commit e055885c52b34e7d78183ed09b8b18ce83ca9631

@ -1 +1 @@
Subproject commit 113f0384f630dd0cacbbeac24c1a5625a8200d73
Subproject commit 84a71e9adf9b6ea120db6ba96533c523bb8ddda5