修复 iOS FlutterSceneDelegate 下微信开放标签冷启动回调#770
Merged
Merged
Conversation
Member
|
Thank you. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题说明
iOS App 使用
FlutterSceneDelegate时,通过微信开放标签wx-open-launch-app冷启动 App,自定义微信 URL Scheme 会通过UISceneConnectionOptions.urlContexts传入。fluwx 当前处理了
UIApplicationDelegate.application:openURL:options:,但没有处理 UIScene 对应的冷启动入口,导致:registerApi()正常返回true;WeChatLaunchFromWXRequest;extMsg。修改内容
handleOrCacheOpenURL:;scene:openURLContexts:,处理 App 运行期间收到的自定义 URL Scheme;scene:willConnectToSession:options:,处理冷启动时connectionOptions.URLContexts中的 URL;_cachedOpenUrlRequest和attemptToResumeMsgFromWx()流程;测试结果
已在 iOS 真机 Profile 模式下测试:
registerApi()返回true;WeChatLaunchFromWXRequest;extMsg;关联问题
Fixes #769
Related to #733
Follow-up to #755