V1.0.1(2) 集成topon
This commit is contained in:
parent
a3a483cfb5
commit
0c47735d26
@ -18,8 +18,8 @@ android {
|
||||
applicationId = "com.paint.ar.drawing"
|
||||
minSdk = 23
|
||||
targetSdk = 34
|
||||
versionCode = 1
|
||||
versionName = "1.0.0"
|
||||
versionCode = 2
|
||||
versionName = "1.0.1"
|
||||
setProperty(
|
||||
"archivesBaseName",
|
||||
"AR Paint Drawing_V" + versionName + "(${versionCode})_$timestamp"
|
||||
@ -70,7 +70,7 @@ dependencies {
|
||||
//noinspection GradleDependency
|
||||
implementation("androidx.camera:camera-extensions:${camerax_version}")
|
||||
|
||||
implementation(platform("com.google.firebase:firebase-bom:33.1.1"))
|
||||
implementation(platform("com.google.firebase:firebase-bom:33.7.0"))
|
||||
implementation("com.google.firebase:firebase-crashlytics")
|
||||
implementation("com.google.firebase:firebase-analytics")
|
||||
|
||||
|
||||
@ -6,6 +6,7 @@ import android.graphics.Typeface;
|
||||
import com.anythink.core.api.ATSDK;
|
||||
import com.anythink.core.api.NetTrafficeCallback;
|
||||
import com.paint.ar.drawing.ob.ObManager;
|
||||
import com.paint.ar.drawing.topon.AdManager;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
@ -21,9 +22,9 @@ public class MyApp extends android.app.Application {
|
||||
|
||||
public static MyApp app;
|
||||
|
||||
private String APPId ="";
|
||||
private String APPId ="h679200e7bcbc3";
|
||||
|
||||
private String AppKey ="";
|
||||
private String AppKey ="a6ad05d72569e4c67d2458cc8e548a764";
|
||||
|
||||
public static Typeface defaultFont;
|
||||
|
||||
@ -55,6 +56,8 @@ public class MyApp extends android.app.Application {
|
||||
}
|
||||
});
|
||||
ATSDK.init( this, APPId, AppKey);
|
||||
AdManager.loadAllAd();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -25,7 +25,7 @@ public class AllActivity extends AppCompatActivity {
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
AdManager.loadAllAd();
|
||||
preViewBinding = ActivityAllBinding.inflate(getLayoutInflater());
|
||||
setContentView(preViewBinding.getRoot());
|
||||
Utils.setStatusBarTextColor(this, true);
|
||||
|
||||
@ -36,6 +36,7 @@ import com.paint.ar.drawing.MyApp;
|
||||
import com.paint.ar.drawing.R;
|
||||
import com.paint.ar.drawing.ob.ObManager;
|
||||
import com.paint.ar.drawing.helper.Utils;
|
||||
import com.paint.ar.drawing.topon.AdManager;
|
||||
|
||||
public class CameraActivity extends AppCompatActivity implements View.OnTouchListener, View.OnClickListener {
|
||||
private CameraSelector cameraSelector;
|
||||
@ -78,7 +79,7 @@ public class CameraActivity extends AppCompatActivity implements View.OnTouchLis
|
||||
Utils.setStatusBarTextColor(this, true);
|
||||
Intent intent = getIntent();
|
||||
isMain = intent.getBooleanExtra(MyApp.Key_ISMAIN, false);
|
||||
|
||||
AdManager.loadAllAd();
|
||||
|
||||
previewView = findViewById(R.id.preview);
|
||||
imageView = findViewById(R.id.image);
|
||||
|
||||
@ -21,6 +21,7 @@ import com.paint.ar.drawing.fragment.FragmentAlbum;
|
||||
import com.paint.ar.drawing.fragment.FragmentLike;
|
||||
import com.paint.ar.drawing.fragment.MainFragment;
|
||||
import com.paint.ar.drawing.helper.Utils;
|
||||
import com.paint.ar.drawing.topon.AdManager;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -41,7 +42,7 @@ public class MainActivity extends AppCompatActivity {
|
||||
Utils.setStatusBarTextColor(this,true);
|
||||
binding = ActivityMainBinding.inflate(getLayoutInflater());
|
||||
setContentView(binding.getRoot());
|
||||
|
||||
AdManager.loadAllAd();
|
||||
fragmentAlbum = FragmentAlbum.newInstance();
|
||||
listFragment.add(MainFragment.newInstance());
|
||||
listFragment.add(fragmentAlbum);
|
||||
|
||||
@ -15,7 +15,7 @@ import com.paint.ar.drawing.topon.GoMainAction;
|
||||
public class WelActivity extends AppCompatActivity {
|
||||
|
||||
private ActivityWelcomeBinding binding;
|
||||
private long time = 1000;
|
||||
private long time = 11000;
|
||||
private CountDownTimer countDownTimer;
|
||||
|
||||
|
||||
|
||||
@ -26,10 +26,17 @@ public class AdManager {
|
||||
private static final int type_show_fail = 4;
|
||||
|
||||
|
||||
|
||||
private static final String place1Id = "";
|
||||
private static final String place2Id = "";
|
||||
private static final String place3Id = "";
|
||||
/**
|
||||
* AR_Inter_3
|
||||
* n67920105f1834
|
||||
* AR_Inter_2
|
||||
* n67920105b46c4
|
||||
* AR_Inter_1
|
||||
* n679201057e60c
|
||||
*/
|
||||
private static final String place1Id = "n67920105f1834";
|
||||
private static final String place2Id = "n67920105b46c4";
|
||||
private static final String place3Id = "n679201057e60c";
|
||||
|
||||
|
||||
private static boolean place1LoadFail = false;
|
||||
@ -122,7 +129,7 @@ public class AdManager {
|
||||
|
||||
@Override
|
||||
public void onInterstitialAdShow(ATAdInfo atAdInfo) {
|
||||
Log.d(MyApp.TAG, "AdShow " + atAdInfo.getShowId());
|
||||
Log.d(MyApp.TAG, "AdShow " + ad.mPlacementId);
|
||||
listener.showSuccess();
|
||||
ad.load();
|
||||
}
|
||||
@ -150,8 +157,6 @@ public class AdManager {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public static CountDownTimer showWelcomeAd(
|
||||
Activity activity,
|
||||
Long totalTim,
|
||||
@ -198,7 +203,6 @@ public class AdManager {
|
||||
}
|
||||
|
||||
|
||||
|
||||
private static void showAD(Activity activity, AdStatusAction action) {
|
||||
ATInterstitial readyAd = getReadyAd();
|
||||
if (readyAd != null) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user