public override void Exit(OnFinish <Result> exitListener) { MSDKLogin.LoginRetEvent -= OnLoginRetEvent; MSDKLogin.LoginBaseRetEvent -= OnLoginBaseRetEvent; MSDKNotice.NoticeRetEvent -= OnNoticeRetEvent; MSDKPush.PushBaseRetEvent -= OnPushBaseRetEvent; MSDKPush.PushNotificationEvent -= OnPushNotificationEvent; MSDKCrash.CrashBaseRetEvent -= OnCrashBaseRetEvent; MSDKPush.UnregisterPush("XG"); }
public override void DeleteTag(string tag, string channel = "") { if (channel == "" || channel == null) { MSDKPush.DeleteTag("XG", tag); } else { MSDKPush.DeleteTag(channel, tag); } }
public override void RegisterPush(OnFinish <RemoteNotification> callback = null, string account = "", string channel = "") { this.pushCallback = callback; if (channel == "" || channel == null) { MSDKPush.RegisterPush("XG", account); } else { MSDKPush.RegisterPush(channel, account); } }
public override void PushNotification(string content, int delay, int id) { MSDKLocalNotification message = new MSDKLocalNotification(); message.ActionType = 1; message.Type = 1; message.Content = content; message.Title = Application.productName; // 马上通知,本地推送会有五分钟的弹性时间,如果小于当前时间就是马上通知 message.Date = DateTime.Now.ToString("yyyyMMdd"); message.Hour = DateTime.Now.Hour.ToString(); message.Min = (DateTime.Now.Minute + delay).ToString(); MSDKPush.AddLocalNotification("XG", message); }
public override void InitGCloud(InitializeInfo cloudInfo) { MSDKLogin.LoginRetEvent += OnLoginRetEvent; MSDKLogin.LoginBaseRetEvent += OnLoginBaseRetEvent; MSDKNotice.NoticeRetEvent += OnNoticeRetEvent; MSDKPush.PushBaseRetEvent += OnPushBaseRetEvent; MSDKPush.PushNotificationEvent += OnPushNotificationEvent; MSDKCrash.CrashBaseRetEvent += OnCrashBaseRetEvent; IGCloud.Instance.Initialize(cloudInfo); RegisterDirCallback(); inited = true; MSDKPush.RegisterPush("XG"); MSDKReport.Init("Beacon,TDM"); MSDK.Init(); }
public override void CleanAllNotification() { MSDKPush.ClearLocalNotifications("XG"); }