From 8655407ab6987bb7268fab55b6380051f26668fe Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期三, 24 十一月 2021 10:17:15 +0800 Subject: [PATCH] 备份 --- HDL-ON_iOS/AppDelegate.cs | 43 ++++++++----------------------------------- 1 files changed, 8 insertions(+), 35 deletions(-) diff --git a/HDL-ON_iOS/AppDelegate.cs b/HDL-ON_iOS/AppDelegate.cs index 81d1d57..4568b86 100644 --- a/HDL-ON_iOS/AppDelegate.cs +++ b/HDL-ON_iOS/AppDelegate.cs @@ -11,7 +11,6 @@ using HDL_ON.DAL.Server; using Intents; using Other.Siri; -using HDLSceneSiri; namespace SharedMethod { @@ -279,32 +278,8 @@ // //RemoteInfo.Current.ReadMsgList(true); //} - #region Siri - // Request access to Siri - INPreferences.RequestSiriAuthorization((INSiriAuthorizationStatus status) => { - // Respond to returned status - switch (status) - { - case INSiriAuthorizationStatus.Authorized: - break; - case INSiriAuthorizationStatus.Denied: - break; - case INSiriAuthorizationStatus.NotDetermined: - break; - case INSiriAuthorizationStatus.Restricted: - break; - } - }); - - var language = INPreferences.SiriLanguageCode; - - // Take action based on language - if (language == "en-US") - { - // Do something... - } - - #endregion + //楂樺痉key + GDMapKit.setGDApiKey("f0635ea15c5d579c6e93d9f07a06da69"); Console.WriteLine("FinishedLaunching"); return true; @@ -477,10 +452,10 @@ - #region Siri + public override bool ContinueUserActivity(UIApplication application, NSUserActivity userActivity, UIApplicationRestorationHandler completionHandler) { - var intent = userActivity.GetInteraction()?.Intent as HDLRunSceneIntent; + var intent = userActivity.GetInteraction()?.Intent as HDLSceneSiri.HDLRunSceneIntent; if (!(intent is null)) { HandleIntent(intent); @@ -494,13 +469,13 @@ return false; } - void HandleIntent(HDLRunSceneIntent intent) + void HandleIntent(HDLSceneSiri.HDLRunSceneIntent intent) { - var handler = new HDLRunSceneIntentHandlder(); + var handler = new SiriKit.HDLRunSceneIntentHandlder(); handler.HandleRunScene(intent, (response) => { - if (response.Code != HDLRunSceneIntentResponseCode.Success) + if (response.Code != HDLSceneSiri.HDLRunSceneIntentResponseCode.Success) { - Console.WriteLine("Quantity must be greater than 0 to add to order"); + Console.WriteLine("Siri鎵ц澶辫触銆�"); } }); } @@ -517,8 +492,6 @@ //var segue = OrderHistoryTableViewController.SegueIdentifiers.SoupMenu; //orderHistoryViewController.PerformSegue(segue, null); } - #endregion - } -- Gitblit v1.8.0