diff --git a/Objective-C/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.m b/Objective-C/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.m index a7c8d56..f1f42ad 100644 --- a/Objective-C/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.m +++ b/Objective-C/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.m @@ -16,6 +16,8 @@ @implementation AppDelegate - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + // Get InMobiCMP SDK version + NSLog(@"InMobiCMP SDK Version: %@", [[ChoiceCmp shared] sdkVersion]); // Initialise InMobiCMP [self startChoice]; @@ -131,4 +133,9 @@ - (void)userDidMoveToOtherState { NSLog(@"%@", NSStringFromSelector(_cmd)); } +- (void)cmpUIStatusChangedWithInfo:(DisplayInfo * _Nonnull)info { + NSLog(@"%@", NSStringFromSelector(_cmd), info.gbcShown); +} + + @end diff --git a/Objective-C/InMobiCMP Demo - iOS/Podfile b/Objective-C/InMobiCMP Demo - iOS/Podfile index fa08393..bffda19 100644 --- a/Objective-C/InMobiCMP Demo - iOS/Podfile +++ b/Objective-C/InMobiCMP Demo - iOS/Podfile @@ -4,6 +4,6 @@ target 'InMobiCMP Demo - iOS' do use_frameworks! # Pods for InMobiCMP Demo - iOS - pod 'InMobiCMP', '2.0.1' + pod 'InMobiCMP', '2.1.0' end diff --git a/Swift/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.swift b/Swift/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.swift index 525a2c5..b43681c 100644 --- a/Swift/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.swift +++ b/Swift/InMobiCMP Demo - iOS/InMobiCMP Demo - iOS/AppDelegate.swift @@ -39,6 +39,9 @@ class AppDelegate: UIResponder, UIApplicationDelegate { func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { + // Get InMobiCMP SDK Version + print("InMobiCMP SDK Version: \(ChoiceCmp.shared.sdkVersion)") + // Initalise InMobi CMP startChoice() @@ -85,10 +88,10 @@ class AppDelegate: UIResponder, UIApplicationDelegate { extension AppDelegate: ChoiceCmpDelegate, CCPADelegate, GoogleBasicConsentDelegate { func cmpDidLoad(info: InMobiCMP.PingResponse) { - print(#function) + print("\(#function), usRegulationApplies: \(info.usRegulationApplies)") } - func cmpDidShow(info: InMobiCMP.PingResponse) { + func cmpUIStatusChanged(info: InMobiCMP.DisplayInfo) { print(#function) } diff --git a/Swift/InMobiCMP Demo - iOS/Podfile b/Swift/InMobiCMP Demo - iOS/Podfile index fa08393..bffda19 100644 --- a/Swift/InMobiCMP Demo - iOS/Podfile +++ b/Swift/InMobiCMP Demo - iOS/Podfile @@ -4,6 +4,6 @@ target 'InMobiCMP Demo - iOS' do use_frameworks! # Pods for InMobiCMP Demo - iOS - pod 'InMobiCMP', '2.0.1' + pod 'InMobiCMP', '2.1.0' end diff --git a/readme.md b/readme.md index 60c684c..afa32d5 100644 --- a/readme.md +++ b/readme.md @@ -181,7 +181,12 @@ The startChoice method sets up and starts the InMobi CMP with the defined colors } ``` - +- Get the InMobiCMP SDK Version +```swift +var inMobiCMPVersion: String { + ChoiceCmp.shared.sdkVersion +} +``` - Delegates @@ -191,10 +196,15 @@ Implement the necessary delegate methods to handle consent responses: extension AppDelegate: ChoiceCmpDelegate, CCPADelegate, GoogleBasicConsentDelegate { func cmpDidLoad(info: InMobiCMP.PingResponse) { print(#function) + print("US Regulation Applies: \(info.usRegulationApplies)") } - func cmpDidShow(info: InMobiCMP.PingResponse) { - print(#function) + func cmpUIStatusChanged(info: DisplayInfo) { + print("\(#function), Display Status: \(info.displayStatus)") + print("\(#function), Display Message: \(info.displayMessage)") + print("\(#function), Regulation Shown: \(info.regulationShown)") + print("\(#function), GBC Shown : \(info.gbcShown)") + } func didReceiveIABVendorConsent(gdprData: InMobiCMP.GDPRData, updated: Bool) {