Skip to content

Commit

Permalink
Merge pull request #77 from daixianceng/develop
Browse files Browse the repository at this point in the history
Upgrade sdk version
  • Loading branch information
BytesZero authored Aug 3, 2024
2 parents 6dcc4f0 + e113b9b commit cefc622
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 25 deletions.
2 changes: 1 addition & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@ dependencies {
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
// 广告 SDK
implementation 'com.pangle.cn:ads-sdk-pro:5.8.1.3'
implementation 'com.pangle.cn:ads-sdk-pro:6.1.0.7'
// compileOnly fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
}
Original file line number Diff line number Diff line change
Expand Up @@ -185,29 +185,7 @@ public void initAd(MethodCall call, final MethodChannel.Result result) {
.directDownloadNetworkType(directDownloadNetworkTypeList)// 直接下载的网络方式
.build();
// 初始化 SDK
TTAdSdk.init(activity.getApplicationContext(), config, new TTAdSdk.InitCallback() {
@Override
public void success() {
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
result.success(true);
}
});
}

@Override
public void fail(int code, String msg) {
Log.e(TAG, "fail: code = " + code + " msg = " + msg);
activity.runOnUiThread(new Runnable() {
@Override
public void run() {
result.success(false);
}
});

}
});
TTAdSdk.init(activity.getApplicationContext(), config);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ private int getMipmapId(String resName) {
}

@Override
public void onSplashLoadSuccess() {
public void onSplashLoadSuccess(CSJSplashAd csjSplashAd) {
Log.d(TAG, "onSplashLoadSuccess");
// 加载事件
AdEventHandler.getInstance().sendEvent(new AdEvent(this.posId, AdEventAction.onAdLoaded));
Expand Down

0 comments on commit cefc622

Please sign in to comment.