From fb84bcee05dbb2dda0e4d7498fd02ed386a9c3f0 Mon Sep 17 00:00:00 2001
From: chenqiyang <1406175257@qq.com>
Date: 星期五, 26 八月 2022 17:57:17 +0800
Subject: [PATCH] 更新全视通dll
---
ZigbeeApp/Home.Ios/AppDelegate.cs | 57 +++++++++++++++++++++++++++++++++++++++++++++------------
1 files changed, 45 insertions(+), 12 deletions(-)
diff --git a/ZigbeeApp/Home.Ios/AppDelegate.cs b/ZigbeeApp/Home.Ios/AppDelegate.cs
old mode 100755
new mode 100644
index 5f7c60e..3db7bf3
--- a/ZigbeeApp/Home.Ios/AppDelegate.cs
+++ b/ZigbeeApp/Home.Ios/AppDelegate.cs
@@ -1,4 +1,4 @@
-锘縰sing System;
+锘縰sing System;
using Foundation;
using Microsoft.AppCenter;
using Microsoft.AppCenter.Analytics;
@@ -25,6 +25,10 @@
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
{
+ //鍏ㄨ閫氳皟鐢‵inishedLaunch
+ Shared.IOS.HDLFVSDK.Video.FVapplication(application,new NSDictionary());
+
+
Shared.Application.IsGpsEnable = false;
Shared.Application.IsMusicEnable = false;
base.FinishedLaunching(application, launchOptions);
@@ -39,11 +43,16 @@
DeviceTokenAction += (deviceToken) =>
{
- Shared.Common.Config.Instance.RegistrationID = deviceToken;
+ if (!string.IsNullOrEmpty(deviceToken))
+ {
+ Shared.Common.Config.Instance.RegistrationID = deviceToken;
+ Shared.Common.Config.Instance.Save();
+ }
};
haveToSignOut = false;
if (launchOptions != null)
{
+
// check for a remote notification
if (launchOptions.ContainsKey(UIApplication.LaunchOptionsRemoteNotificationKey))
{
@@ -57,10 +66,10 @@
if (!string.IsNullOrEmpty(hiddenJson))
{
if (hiddenJson.Contains("cmtID"))
- {
-
- ///鐩墠鏍规嵁杩欎釜鍒ゆ柇鏄惁鏄彲瑙嗗璁叉暟鎹�
- // VideoMethod(hiddenJson);
+ {
+
+ ///鐩墠鏍规嵁杩欎釜鍒ゆ柇鏄惁鏄彲瑙嗗璁叉暟鎹�
+ // VideoMethod(hiddenJson);
}
else
{
@@ -87,15 +96,16 @@
}
}
}
-
-
+
+
}
}
}
}
AppCenter.Start("0ca801a2-742b-42fb-ba10-7ba4391371aa", typeof(Analytics), typeof(Crashes));
- GDMapKit.setGDApiKey("866fae25f336bc8d9a79b1d19267fffb");//楂樺痉鍦板浘key
+ GDMapKit.setGDApiKey("3889cdfa4ef10c0d43348ffa2c1017c8");//楂樺痉鍦板浘key
+
return true;
}
@@ -105,8 +115,11 @@
}
public override void DidReceiveRemoteNotification(UIApplication application, NSDictionary userInfo, Action<UIBackgroundFetchResult> completionHandler)
{
+
if (userInfo == null)
{
+ //var alert = new Alert("", "userInfo涓虹┖", "");
+ //alert.Show();
return;
}
Console.WriteLine(userInfo);
@@ -114,9 +127,16 @@
if (application.ApplicationState == UIApplicationState.Active || application.ApplicationState == UIApplicationState.Background)
{
NSString key_hiddenJson = new NSString("HiddenJson");
+ //var alert1 = new Alert("", "鏀跺埌鎺ㄩ�佷簡", "");
+ //alert1.Show();
if (userInfo.ContainsKey(key_hiddenJson))
{
- var hiddenJson = userInfo["HiddenJson"].ToString();
+
+ var hiddenJson = userInfo["HiddenJson"].ToString();
+
+ //var alert = new Alert("", hiddenJson, "");
+ //alert.Show();
+
if (string.IsNullOrEmpty(hiddenJson))
{
return;
@@ -126,7 +146,7 @@
{
///鐩墠鏍规嵁杩欎釜鍒ゆ柇鏄惁鏄彲瑙嗗璁叉暟鎹�
- VideoMethod(hiddenJson);
+ //VideoMethod(hiddenJson);
}
else
{
@@ -169,7 +189,7 @@
if (hiddenJson.Contains("cmtID"))
{
///鐩墠鏍规嵁杩欎釜鍒ゆ柇鏄惁鏄彲瑙嗗璁叉暟鎹�
- VideoMethod(hiddenJson);
+ //VideoMethod(hiddenJson);
}
else
{
@@ -240,6 +260,7 @@
public override void ReceivedRemoteNotification(UIApplication application, NSDictionary userInfo)
{
+
Console.WriteLine(userInfo);
if (application.ApplicationState == UIApplicationState.Active)
{
@@ -262,6 +283,7 @@
// or when the user quits the application and it begins the transition to the background state.
// Games should use this method to pause the game.
base.OnResignActivation(application);
+ Shared.IOS.HDLFVSDK.Video.FVapplicationWillResignActive(application);
}
public override void DidEnterBackground(UIApplication application)
@@ -271,10 +293,15 @@
//Shared.BusSocket.Stop ();On鍦ㄨ繖閲屽仠姝usSocket
ZigBee.Common.Application.FindGateWaySocket.Stop();
base.DidEnterBackground(application);
+ Shared.IOS.HDLFVSDK.Video.FVapplicationDidEnterBackground(application);
}
public override void WillEnterForeground(UIApplication application)
{
+ var internetStatus = GateWay.Ios.Reachability.InternetConnectionStatus();
+ Shared.Phone.UserCenter.HdlWifiLogic.Current.NetworkStateChanged((int)internetStatus);
+
+ //ZigBee.Common.Application.FindGateWaySocket.Start();
// Called as part of the transiton from background to active state.
// Here you can undo many of the changes made on entering the background.
System.Console.WriteLine("WillEnterForeground");
@@ -282,8 +309,11 @@
base.WillEnterForeground(application);
}
+
public override void OnActivated(UIApplication application)
{
+ //鍏ㄨ閫氳皟鐢˙ecomeActive
+ Shared.IOS.HDLFVSDK.Video.FVapplicationDidBecomeActive(application);
// Restart any tasks that were paused (or not yet started) while the application was inactive.
// If the application was previously in the background, optionally refresh the user interface.
base.OnActivated(application);
@@ -296,6 +326,9 @@
}
//妫�鏌ヨ繛鎺ヨ繙绋�
//浠g爜
+
+ //娓呴櫎瑙掓爣
+ CommonPage.Instance.clearBadgeNum();
}
public override void WillTerminate(UIApplication application)
--
Gitblit v1.8.0