From b982e094a085c22fe9d13517c55eb896d65aa19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Bonaf=C3=A9?= <99195905+github-lucas-bon@users.noreply.github.com> Date: Mon, 8 Apr 2024 11:32:25 +0200 Subject: [PATCH] Update gms ads to latest 23.0.0 (#227) --- .../format/mediation/adapter/AdMobRecyclerViewAdapter.kt | 2 +- .../format/mediation/admob/AdMobScrollViewFragment.kt | 2 +- .../format/mediation/admob/AdMobWebViewFragment.kt | 2 +- .../buildSrc/src/main/java/tv/teads/AndroidLibConfig.kt | 4 ++-- TeadsSDKDemo/buildSrc/src/main/java/tv/teads/Libs.kt | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/adapter/AdMobRecyclerViewAdapter.kt b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/adapter/AdMobRecyclerViewAdapter.kt index 1af48dc..af05826 100644 --- a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/adapter/AdMobRecyclerViewAdapter.kt +++ b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/adapter/AdMobRecyclerViewAdapter.kt @@ -33,7 +33,7 @@ class AdMobRecyclerViewAdapter(admobBannerId: String, context: Context?, title: // 2. Setup the AdMob view adView.adUnitId = admobBannerId - adView.adSize = AdSize.MEDIUM_RECTANGLE + adView.setAdSize(AdSize.MEDIUM_RECTANGLE) // 3. Subsribe to the listener if needed adView.adListener = object : AdListener() { diff --git a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobScrollViewFragment.kt b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobScrollViewFragment.kt index ea12f23..6774412 100644 --- a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobScrollViewFragment.kt +++ b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobScrollViewFragment.kt @@ -43,7 +43,7 @@ class AdMobScrollViewFragment : BaseFragment() { // 2. Create AdMob view, setup and add it to view hierarchy val adView = AdView(view.context) adView.adUnitId = AdMobIdentifier.getAdUnitFromPid(pid) - adView.adSize = AdSize.MEDIUM_RECTANGLE + adView.setAdSize(AdSize.MEDIUM_RECTANGLE) binding.adSlotView.addView(adView, 0) // 3. Attach listener (will include Teads events) diff --git a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobWebViewFragment.kt b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobWebViewFragment.kt index 840b4a4..eaf8e7b 100644 --- a/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobWebViewFragment.kt +++ b/TeadsSDKDemo/app/src/main/java/tv/teads/teadssdkdemo/format/mediation/admob/AdMobWebViewFragment.kt @@ -60,7 +60,7 @@ class AdMobWebViewFragment : BaseFragment(), SyncAdWebView.Listener { webviewHelperSynch.registerAdView(adView) adView.adUnitId = AdMobIdentifier.getAdUnitFromPid(pid) - adView.adSize = AdSize.MEDIUM_RECTANGLE + adView.setAdSize(AdSize.MEDIUM_RECTANGLE) // 4. Create the TeadsAdapterListener mListener = object : TeadsAdapterListener { diff --git a/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/AndroidLibConfig.kt b/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/AndroidLibConfig.kt index deda19d..e083d99 100644 --- a/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/AndroidLibConfig.kt +++ b/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/AndroidLibConfig.kt @@ -1,7 +1,7 @@ package tv.teads object AndroidLibConfig { - const val compileSdk = 31 - const val minSdk = 19 + const val compileSdk = 33 + const val minSdk = 21 const val targetSdk = 28 } \ No newline at end of file diff --git a/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/Libs.kt b/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/Libs.kt index c8aefd6..67a94e5 100644 --- a/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/Libs.kt +++ b/TeadsSDKDemo/buildSrc/src/main/java/tv/teads/Libs.kt @@ -6,7 +6,7 @@ object Libs { const val APPLOVIN_SDK = "com.applovin:applovin-sdk:11.3.0" const val MATERIAL = "com.google.android.material:material:1.4.0" - const val PLAY_SERVICES_ADS = "com.google.android.gms:play-services-ads:20.2.0" + const val PLAY_SERVICES_ADS = "com.google.android.gms:play-services-ads:23.0.0" const val HUAWEI_IDENTIFIER = "com.huawei.hms:ads-identifier:3.4.28.313"