Skip to content

Commit 2ff4848

Browse files
Merge pull request #255 from teads/update-admob
updated sampleApp for Google Admob
2 parents 7dd56b6 + 1ddb468 commit 2ff4848

File tree

8 files changed

+111
-167
lines changed

8 files changed

+111
-167
lines changed

Gemfile.lock

Lines changed: 48 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,52 @@
11
GEM
22
remote: https://rubygems.org/
33
specs:
4-
CFPropertyList (3.0.5)
4+
CFPropertyList (3.0.7)
5+
base64
6+
nkf
57
rexml
6-
activesupport (6.1.7.6)
7-
concurrent-ruby (~> 1.0, >= 1.0.2)
8+
activesupport (7.2.2.1)
9+
base64
10+
benchmark (>= 0.3)
11+
bigdecimal
12+
concurrent-ruby (~> 1.0, >= 1.3.1)
13+
connection_pool (>= 2.2.5)
14+
drb
815
i18n (>= 1.6, < 2)
16+
logger (>= 1.4.2)
917
minitest (>= 5.1)
10-
tzinfo (~> 2.0)
11-
zeitwerk (~> 2.3)
12-
addressable (2.8.0)
13-
public_suffix (>= 2.0.2, < 5.0)
18+
securerandom (>= 0.3)
19+
tzinfo (~> 2.0, >= 2.0.5)
20+
addressable (2.8.7)
21+
public_suffix (>= 2.0.2, < 7.0)
1422
algoliasearch (1.27.5)
1523
httpclient (~> 2.8, >= 2.8.3)
1624
json (>= 1.5.1)
1725
atomos (0.1.3)
18-
claide (1.0.3)
19-
cocoapods (1.11.2)
26+
base64 (0.2.0)
27+
benchmark (0.4.0)
28+
bigdecimal (3.1.8)
29+
claide (1.1.0)
30+
cocoapods (1.16.2)
2031
addressable (~> 2.8)
2132
claide (>= 1.0.2, < 2.0)
22-
cocoapods-core (= 1.11.2)
33+
cocoapods-core (= 1.16.2)
2334
cocoapods-deintegrate (>= 1.0.3, < 2.0)
24-
cocoapods-downloader (>= 1.4.0, < 2.0)
35+
cocoapods-downloader (>= 2.1, < 3.0)
2536
cocoapods-plugins (>= 1.0.0, < 2.0)
2637
cocoapods-search (>= 1.0.0, < 2.0)
27-
cocoapods-trunk (>= 1.4.0, < 2.0)
38+
cocoapods-trunk (>= 1.6.0, < 2.0)
2839
cocoapods-try (>= 1.1.0, < 2.0)
2940
colored2 (~> 3.1)
3041
escape (~> 0.0.4)
3142
fourflusher (>= 2.3.0, < 3.0)
3243
gh_inspector (~> 1.0)
3344
molinillo (~> 0.8.0)
3445
nap (~> 1.0)
35-
ruby-macho (>= 1.0, < 3.0)
36-
xcodeproj (>= 1.21.0, < 2.0)
37-
cocoapods-core (1.11.2)
38-
activesupport (>= 5.0, < 7)
46+
ruby-macho (>= 2.3.0, < 3.0)
47+
xcodeproj (>= 1.27.0, < 2.0)
48+
cocoapods-core (1.16.2)
49+
activesupport (>= 5.0, < 8)
3950
addressable (~> 2.8)
4051
algoliasearch (~> 1.0)
4152
concurrent-ruby (~> 1.1)
@@ -45,7 +56,7 @@ GEM
4556
public_suffix (~> 4.0)
4657
typhoeus (~> 1.0)
4758
cocoapods-deintegrate (1.0.5)
48-
cocoapods-downloader (1.6.3)
59+
cocoapods-downloader (2.1)
4960
cocoapods-plugins (1.0.0)
5061
nap
5162
cocoapods-search (1.0.1)
@@ -54,47 +65,48 @@ GEM
5465
netrc (~> 0.11)
5566
cocoapods-try (1.2.0)
5667
colored2 (3.1.2)
57-
concurrent-ruby (1.2.2)
68+
concurrent-ruby (1.3.5)
69+
connection_pool (2.5.0)
70+
drb (2.2.1)
5871
escape (0.0.4)
59-
ethon (0.15.0)
72+
ethon (0.16.0)
6073
ffi (>= 1.15.0)
61-
ffi (1.15.4)
74+
ffi (1.17.1-arm64-darwin)
6275
fourflusher (2.3.1)
6376
fuzzy_match (2.0.4)
6477
gh_inspector (1.1.3)
6578
httpclient (2.8.3)
66-
i18n (1.14.1)
79+
i18n (1.14.7)
6780
concurrent-ruby (~> 1.0)
68-
json (2.6.1)
69-
minitest (5.19.0)
81+
json (2.9.0)
82+
logger (1.7.0)
83+
minitest (5.25.4)
7084
molinillo (0.8.0)
71-
nanaimo (0.3.0)
85+
nanaimo (0.4.0)
7286
nap (1.1.0)
7387
netrc (0.11.0)
74-
public_suffix (4.0.6)
75-
rexml (3.2.5)
88+
nkf (0.2.0)
89+
public_suffix (4.0.7)
90+
rexml (3.4.0)
7691
ruby-macho (2.5.1)
77-
typhoeus (1.4.0)
92+
securerandom (0.4.0)
93+
typhoeus (1.4.1)
7894
ethon (>= 0.9.0)
7995
tzinfo (2.0.6)
8096
concurrent-ruby (~> 1.0)
81-
xcodeproj (1.21.0)
97+
xcodeproj (1.27.0)
8298
CFPropertyList (>= 2.3.3, < 4.0)
8399
atomos (~> 0.1.3)
84100
claide (>= 1.0.2, < 2.0)
85101
colored2 (~> 3.1)
86-
nanaimo (~> 0.3.0)
87-
rexml (~> 3.2.4)
88-
zeitwerk (2.6.11)
102+
nanaimo (~> 0.4.0)
103+
rexml (>= 3.3.6, < 4.0)
89104

90105
PLATFORMS
91-
arm64-darwin-21
92-
x86_64-darwin-19
93-
x86_64-darwin-20
94-
x86_64-linux
106+
arm64-darwin
95107

96108
DEPENDENCIES
97109
cocoapods (>= 1.10.2)
98110

99111
BUNDLED WITH
100-
2.3.13
112+
2.6.3

Podfile.lock

Lines changed: 25 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -1,76 +1,22 @@
11
PODS:
2-
- AppLovinSDK (11.11.4)
3-
- Google-Mobile-Ads-SDK (10.8.0):
4-
- GoogleAppMeasurement (< 11.0, >= 7.0)
2+
- AppLovinSDK (13.3.0)
3+
- Google-Mobile-Ads-SDK (12.5.0):
54
- GoogleUserMessagingPlatform (>= 1.1)
6-
- GoogleAppMeasurement (10.25.0):
7-
- GoogleAppMeasurement/AdIdSupport (= 10.25.0)
8-
- GoogleUtilities/AppDelegateSwizzler (~> 7.11)
9-
- GoogleUtilities/MethodSwizzler (~> 7.11)
10-
- GoogleUtilities/Network (~> 7.11)
11-
- "GoogleUtilities/NSData+zlib (~> 7.11)"
12-
- nanopb (< 2.30911.0, >= 2.30908.0)
13-
- GoogleAppMeasurement/AdIdSupport (10.25.0):
14-
- GoogleAppMeasurement/WithoutAdIdSupport (= 10.25.0)
15-
- GoogleUtilities/AppDelegateSwizzler (~> 7.11)
16-
- GoogleUtilities/MethodSwizzler (~> 7.11)
17-
- GoogleUtilities/Network (~> 7.11)
18-
- "GoogleUtilities/NSData+zlib (~> 7.11)"
19-
- nanopb (< 2.30911.0, >= 2.30908.0)
20-
- GoogleAppMeasurement/WithoutAdIdSupport (10.25.0):
21-
- GoogleUtilities/AppDelegateSwizzler (~> 7.11)
22-
- GoogleUtilities/MethodSwizzler (~> 7.11)
23-
- GoogleUtilities/Network (~> 7.11)
24-
- "GoogleUtilities/NSData+zlib (~> 7.11)"
25-
- nanopb (< 2.30911.0, >= 2.30908.0)
26-
- GoogleUserMessagingPlatform (2.0.1)
27-
- GoogleUtilities/AppDelegateSwizzler (7.13.2):
28-
- GoogleUtilities/Environment
29-
- GoogleUtilities/Logger
30-
- GoogleUtilities/Network
31-
- GoogleUtilities/Privacy
32-
- GoogleUtilities/Environment (7.13.2):
33-
- GoogleUtilities/Privacy
34-
- PromisesObjC (< 3.0, >= 1.2)
35-
- GoogleUtilities/Logger (7.13.2):
36-
- GoogleUtilities/Environment
37-
- GoogleUtilities/Privacy
38-
- GoogleUtilities/MethodSwizzler (7.13.2):
39-
- GoogleUtilities/Logger
40-
- GoogleUtilities/Privacy
41-
- GoogleUtilities/Network (7.13.2):
42-
- GoogleUtilities/Logger
43-
- "GoogleUtilities/NSData+zlib"
44-
- GoogleUtilities/Privacy
45-
- GoogleUtilities/Reachability
46-
- "GoogleUtilities/NSData+zlib (7.13.2)":
47-
- GoogleUtilities/Privacy
48-
- GoogleUtilities/Privacy (7.13.2)
49-
- GoogleUtilities/Reachability (7.13.2):
50-
- GoogleUtilities/Logger
51-
- GoogleUtilities/Privacy
52-
- nanopb (2.30910.0):
53-
- nanopb/decode (= 2.30910.0)
54-
- nanopb/encode (= 2.30910.0)
55-
- nanopb/decode (2.30910.0)
56-
- nanopb/encode (2.30910.0)
57-
- PromisesObjC (2.4.0)
58-
- Smart-Core-SDK (7.18.1)
59-
- Smart-Display-SDK (7.18.0):
60-
- Smart-Core-SDK (~> 7.18)
61-
- SwiftFormat/CLI (0.50.1)
62-
- TeadsAdMobAdapter (5.1.3):
5+
- GoogleUserMessagingPlatform (3.0.0)
6+
- Smart-Display-SDK (7.24.2)
7+
- SwiftFormat/CLI (0.56.3)
8+
- TeadsAdMobAdapter (5.1.9):
639
- Google-Mobile-Ads-SDK (>= 9.0.0)
64-
- TeadsSDK (= 5.1.3)
65-
- TeadsAppLovinAdapter (5.1.3):
10+
- TeadsSDK (= 5.1.9)
11+
- TeadsAppLovinAdapter (5.1.9):
6612
- AppLovinSDK (>= 11.5.1)
67-
- TeadsSDK (= 5.1.3)
68-
- TeadsSASAdapter (5.1.3):
13+
- TeadsSDK (= 5.1.9)
14+
- TeadsSASAdapter (5.1.9):
6915
- Smart-Display-SDK (>= 7.6.2)
70-
- TeadsSDK (= 5.1.3)
71-
- TeadsSDK (5.1.3):
72-
- TeadsSDK/Core (= 5.1.3)
73-
- TeadsSDK/Core (5.1.3)
16+
- TeadsSDK (= 5.1.9)
17+
- TeadsSDK (5.1.9):
18+
- TeadsSDK/Core (= 5.1.9)
19+
- TeadsSDK/Core (5.1.9)
7420

7521
DEPENDENCIES:
7622
- SwiftFormat/CLI
@@ -83,12 +29,7 @@ SPEC REPOS:
8329
trunk:
8430
- AppLovinSDK
8531
- Google-Mobile-Ads-SDK
86-
- GoogleAppMeasurement
8732
- GoogleUserMessagingPlatform
88-
- GoogleUtilities
89-
- nanopb
90-
- PromisesObjC
91-
- Smart-Core-SDK
9233
- Smart-Display-SDK
9334
- SwiftFormat
9435
- TeadsAdMobAdapter
@@ -97,21 +38,16 @@ SPEC REPOS:
9738
- TeadsSDK
9839

9940
SPEC CHECKSUMS:
100-
AppLovinSDK: 5c667a790725d9529c01c3f3acf12ab195865fbb
101-
Google-Mobile-Ads-SDK: 69daa7fb42061b425340706e382e87fab3e666a3
102-
GoogleAppMeasurement: 9abf64b682732fed36da827aa2a68f0221fd2356
103-
GoogleUserMessagingPlatform: 5f8b30daf181805317b6b985bb51c1ff3beca054
104-
GoogleUtilities: c56430aef51a1aa57b25da78c3f8397e522c67b7
105-
nanopb: 438bc412db1928dac798aa6fd75726007be04262
106-
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
107-
Smart-Core-SDK: 7f2b321a2f8a4233481db716a30a2715d2fafbd1
108-
Smart-Display-SDK: 83450dd0befaa55f08779a8c67c30bd6d8e80ee9
109-
SwiftFormat: e73212c71908404e333da34e303772b9e516ac9b
110-
TeadsAdMobAdapter: 8ad84ae86c9ab730a50a3e03962757ed4e9b533c
111-
TeadsAppLovinAdapter: 96548a65bdcf7bb277a0c904844faeba6600b556
112-
TeadsSASAdapter: 0858cce43492dea028838a7d289b5928d10becdb
113-
TeadsSDK: 2063418accbe371f3a98cadd933e53763dd5affd
41+
AppLovinSDK: 5ed9dbada0de5a80e4546116994470011ed01f53
42+
Google-Mobile-Ads-SDK: 6df9aadcee32bce0ff05bcad56ef2c88a4a5e82b
43+
GoogleUserMessagingPlatform: f8d0cdad3ca835406755d0a69aa634f00e76d576
44+
Smart-Display-SDK: e2c9c881236a0a9f0f6e99e2a2410ca74d9bb41a
45+
SwiftFormat: 46eb9be6acdde74fcaca9275af5ebddd412e3484
46+
TeadsAdMobAdapter: 6f1dbe5f94ddedf05521b90a85b93b91f5df1bfc
47+
TeadsAppLovinAdapter: 4f0938276a8a1fd87651072995cc8705cb143ea1
48+
TeadsSASAdapter: 5776247b330061ec940cc53d36221c6ea92491f0
49+
TeadsSDK: b4b36872a12f71771cf4883ad2c47902c1fddea1
11450

115-
PODFILE CHECKSUM: fa6163c00fa56eb713479bbd6ca7c09858dd3e55
51+
PODFILE CHECKSUM: 90ba34fb8d06e815de4fcb93225e749cd700095a
11652

117-
COCOAPODS: 1.15.2
53+
COCOAPODS: 1.16.2

TeadsSampleApp.xcodeproj/project.pbxproj

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -681,11 +681,13 @@
681681
);
682682
inputPaths = (
683683
"${PODS_ROOT}/Target Support Files/Pods-TeadsSampleApp/Pods-TeadsSampleApp-resources.sh",
684-
"${PODS_ROOT}/AppLovinSDK/applovin-ios-sdk-11.11.4/AppLovinSDKResources.bundle",
684+
"${PODS_CONFIGURATION_BUILD_DIR}/Google-Mobile-Ads-SDK/GoogleMobileAdsResources.bundle",
685+
"${PODS_CONFIGURATION_BUILD_DIR}/GoogleUserMessagingPlatform/UserMessagingPlatformResources.bundle",
685686
);
686687
name = "[CP] Copy Pods Resources";
687688
outputPaths = (
688-
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AppLovinSDKResources.bundle",
689+
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/GoogleMobileAdsResources.bundle",
690+
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/UserMessagingPlatformResources.bundle",
689691
);
690692
runOnlyForDeploymentPostprocessing = 0;
691693
shellPath = /bin/sh;
@@ -699,20 +701,14 @@
699701
);
700702
inputPaths = (
701703
"${PODS_ROOT}/Target Support Files/Pods-TeadsSampleApp/Pods-TeadsSampleApp-frameworks.sh",
702-
"${BUILT_PRODUCTS_DIR}/GoogleUtilities/GoogleUtilities.framework",
703-
"${BUILT_PRODUCTS_DIR}/PromisesObjC/FBLPromises.framework",
704-
"${BUILT_PRODUCTS_DIR}/nanopb/nanopb.framework",
705-
"${PODS_XCFRAMEWORKS_BUILD_DIR}/Smart-Core-SDK/SCSCoreKit.framework/SCSCoreKit",
704+
"${PODS_XCFRAMEWORKS_BUILD_DIR}/AppLovinSDK/AppLovinSDK.framework/AppLovinSDK",
706705
"${PODS_XCFRAMEWORKS_BUILD_DIR}/Smart-Display-SDK/SASDisplayKit.framework/SASDisplayKit",
707706
"${PODS_XCFRAMEWORKS_BUILD_DIR}/TeadsSDK/Core/TeadsSDK.framework/TeadsSDK",
708707
"${PODS_XCFRAMEWORKS_BUILD_DIR}/TeadsSDK/Core/OMSDK_Teadstv.framework/OMSDK_Teadstv",
709708
);
710709
name = "[CP] Embed Pods Frameworks";
711710
outputPaths = (
712-
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/GoogleUtilities.framework",
713-
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FBLPromises.framework",
714-
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/nanopb.framework",
715-
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/SCSCoreKit.framework",
711+
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/AppLovinSDK.framework",
716712
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/SASDisplayKit.framework",
717713
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/TeadsSDK.framework",
718714
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/OMSDK_Teadstv.framework",

TeadsSampleApp/Cells/AdmobNativeAdTableViewCell.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ import GoogleMobileAds
99
import UIKit
1010

1111
class AdmobNativeAdTableViewCell: UITableViewCell {
12-
@IBOutlet var nativeAdView: GADNativeAdView!
12+
@IBOutlet var nativeAdView: NativeAdView!
1313
}

TeadsSampleApp/Controllers/InRead/Admob/ScrollView/InReadAdmobScrollViewController.swift

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func requestPermission() {
4040
}
4141

4242
class InReadAdmobScrollViewController: TeadsViewController {
43-
var bannerView: GAMBannerView!
43+
var bannerView: AdManagerBannerView!
4444
@IBOutlet var slotView: UIView!
4545
@IBOutlet var slotViewHeightConstraint: NSLayoutConstraint!
4646

@@ -84,30 +84,30 @@ class InReadAdmobScrollViewController: TeadsViewController {
8484
}
8585
}
8686

87-
extension InReadAdmobScrollViewController: GADBannerViewDelegate {
88-
func bannerViewDidReceiveAd(_: GADBannerView) {
87+
extension InReadAdmobScrollViewController: BannerViewDelegate {
88+
func bannerViewDidReceiveAd(_: BannerView) {
8989
// not used
9090
}
9191

9292
/// Tells the delegate an ad request failed.
93-
func bannerView(_: GADBannerView, didFailToReceiveAdWithError error: Error) {
93+
func bannerView(_: BannerView, didFailToReceiveAdWithError error: Error) {
9494
resizeAd(height: 0)
9595
print("adView:didFailToReceiveAdWithError: \(error.localizedDescription)")
9696
}
9797

9898
/// Tells the delegate that a full-screen view will be presented in response
9999
/// to the user clicking on an ad.
100-
func bannerViewWillPresentScreen(_: GADBannerView) {
100+
func bannerViewWillPresentScreen(_: BannerView) {
101101
// not used
102102
}
103103

104104
/// Tells the delegate that the full-screen view will be dismissed.
105-
func bannerViewWillDismissScreen(_: GADBannerView) {
105+
func bannerViewWillDismissScreen(_: BannerView) {
106106
// not used
107107
}
108108

109109
/// Tells the delegate that the full-screen view has been dismissed.
110-
func bannerViewDidDismissScreen(_: GADBannerView) {
110+
func bannerViewDidDismissScreen(_: BannerView) {
111111
// not used
112112
}
113113
}

0 commit comments

Comments
 (0)