更新推送SDK

This commit is contained in:
玉峰 2025-09-10 18:07:22 +08:00
parent 295b16d3cd
commit 926512a0f4
3 changed files with 18 additions and 0 deletions

View File

@ -180,6 +180,16 @@ namespace EFSDK
SDKCall("initSDK", mappingInfo);
ActionCallback?.Invoke(ActionType.SDK_INIT_Succ, string.Empty);
}
/// <summary>
/// 当游戏进程启动之后,可以接收响应的时候(一般在游戏内事件上报相关内容初始化完毕调用即可,参数传true),调用这个方法通知SDK,
/// SDK收到通知后会开始将SDK侧的事件回传给游戏,作事件上报
/// </summary>
/// <param name="active">传 true</param>
public void SetGameActive(bool active)
{
SDKCall("onGameActive", active);
}
/// <summary>
/// 展示WebView

View File

@ -109,6 +109,11 @@ namespace WZ
return pid;
}
private void OnApplicationFocus(bool hasFocus)
{
EFSdk.get().SetGameActive(hasFocus);
}
}
}

View File

@ -1,6 +1,7 @@
using System;
using System.Globalization;
using AdjustSdk;
using EFSDK;
using Firebase.Extensions;
using Firebase.Messaging;
using Firebase.RemoteConfig;
@ -38,6 +39,8 @@ namespace WZ
AdsSDKManager.Instance.RefreshAdsData();
//AB测试分组参数
GroupSet();
//推送事件
EFSdk.get().SetGameActive(true);
// adjust卸载监控