diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/Info.plist b/Frameworks/OMSDK-Static_Prebidorg.xcframework/Info.plist index 5de4432f9..b8ed3eb54 100644 --- a/Frameworks/OMSDK-Static_Prebidorg.xcframework/Info.plist +++ b/Frameworks/OMSDK-Static_Prebidorg.xcframework/Info.plist @@ -8,35 +8,66 @@ HeadersPath Headers LibraryIdentifier - ios-arm64_armv7 + ios-arm64_i386_x86_64-simulator LibraryPath libAppVerificationLibrary.a SupportedArchitectures arm64 - armv7 + i386 + x86_64 SupportedPlatform ios + SupportedPlatformVariant + simulator HeadersPath Headers LibraryIdentifier - ios-arm64_i386_x86_64-simulator + tvos-arm64_x86_64-simulator LibraryPath libAppVerificationLibrary.a SupportedArchitectures arm64 - i386 x86_64 SupportedPlatform - ios + tvos SupportedPlatformVariant simulator + + HeadersPath + Headers + LibraryIdentifier + tvos-arm64 + LibraryPath + libAppVerificationLibrary.a + SupportedArchitectures + + arm64 + + SupportedPlatform + tvos + + + HeadersPath + Headers + LibraryIdentifier + ios-arm64_armv7 + LibraryPath + libAppVerificationLibrary.a + SupportedArchitectures + + arm64 + armv7 + + SupportedPlatform + ios + CFBundlePackageType XFWK diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDAdSessionContext.h b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDAdSessionContext.h index 141dd3cc9..4db81ef40 100644 --- a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDAdSessionContext.h +++ b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDAdSessionContext.h @@ -3,7 +3,11 @@ // #import + +#if !(TARGET_OS_TV) #import +#endif + #import "OMIDPartner.h" #import "OMIDVerificationScriptResource.h" @@ -17,6 +21,8 @@ NS_ASSUME_NONNULL_BEGIN - (null_unspecified instancetype)init NS_UNAVAILABLE; +#if !(TARGET_OS_TV) + /** * Initializes a new ad session context providing reference to partner and web view where * the OM SDK JavaScript service has been injected. @@ -38,6 +44,8 @@ NS_ASSUME_NONNULL_BEGIN contentUrl:(nullable NSString *)contentUrl customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#endif + /** * Initializes a new ad session context providing reference to partner and a list of * script resources which should be managed by OMID. @@ -62,6 +70,7 @@ NS_ASSUME_NONNULL_BEGIN customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#if !(TARGET_OS_TV) /** * Initializes a new ad session context providing reference to partner and web view where * OM SDK JavaScript service has been injected. @@ -83,6 +92,7 @@ NS_ASSUME_NONNULL_BEGIN contentUrl:(nullable NSString *)contentUrl customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#endif @end diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDSDK.h b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDSDK.h index a20b1e462..578322426 100644 --- a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDSDK.h +++ b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/Headers/OMIDSDK.h @@ -7,6 +7,8 @@ #import +NS_ASSUME_NONNULL_BEGIN; + /** * This application level class will be called by all integration partners to ensure OM SDK has been activated before calling any other API methods. * Any attempt to use other API methods prior to activation will result in an error. @@ -20,25 +22,37 @@ /** * The current semantic version of the integrated OMID library. */ -+ (nonnull NSString *)versionString; ++ (NSString *)versionString; /** * Shared OMIDSDK instance. */ -@property(class, readonly, nonnull) OMIDPrebidorgSDK *sharedInstance +@property(class, readonly) OMIDPrebidorgSDK *sharedInstance NS_SWIFT_NAME(shared); /** - * A Boolean value indicating whether the OMID library has been activated. + * A Boolean value indicating whether OM SDK has been activated. * - * The value of this property is YES if the OMID library has already been activated. Allows the integration partner to check that they are compatible with the running OMID library version. + * @discussion Check that OM SDK is active prior to creating any ad sessions. */ -@property(atomic, readonly, getter = isActive) BOOL active; +@property(atomic, readonly, getter=isActive) BOOL active; /** - * Enables the integration partner to activate OMID. + * Activate OM SDK before calling other API methods. + * + * @discussion Activation sets up the OM SDK environment. In CTV apps (running tvOS), `activate` should be called on launch in + * order to capture a "last activity" timestamp on launch and each time the user foregrounds the app). + * + * @return Boolean indicating success. */ - (BOOL)activate; +/** + * Update the last activity time + * After activating OM SDK in CTV apps, refresh the "last activity" timestamp in response to user input prior to starting an ad session. + */ +- (void)updateLastActivity; + @end +NS_ASSUME_NONNULL_END; diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/libAppVerificationLibrary.a b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/libAppVerificationLibrary.a index 3e180c7f1..2da33fa57 100644 Binary files a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/libAppVerificationLibrary.a and b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_armv7/libAppVerificationLibrary.a differ diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDAdSessionContext.h b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDAdSessionContext.h index 141dd3cc9..4db81ef40 100644 --- a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDAdSessionContext.h +++ b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDAdSessionContext.h @@ -3,7 +3,11 @@ // #import + +#if !(TARGET_OS_TV) #import +#endif + #import "OMIDPartner.h" #import "OMIDVerificationScriptResource.h" @@ -17,6 +21,8 @@ NS_ASSUME_NONNULL_BEGIN - (null_unspecified instancetype)init NS_UNAVAILABLE; +#if !(TARGET_OS_TV) + /** * Initializes a new ad session context providing reference to partner and web view where * the OM SDK JavaScript service has been injected. @@ -38,6 +44,8 @@ NS_ASSUME_NONNULL_BEGIN contentUrl:(nullable NSString *)contentUrl customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#endif + /** * Initializes a new ad session context providing reference to partner and a list of * script resources which should be managed by OMID. @@ -62,6 +70,7 @@ NS_ASSUME_NONNULL_BEGIN customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#if !(TARGET_OS_TV) /** * Initializes a new ad session context providing reference to partner and web view where * OM SDK JavaScript service has been injected. @@ -83,6 +92,7 @@ NS_ASSUME_NONNULL_BEGIN contentUrl:(nullable NSString *)contentUrl customReferenceIdentifier:(nullable NSString *)customReferenceIdentifier error:(NSError *_Nullable *_Nullable)error; +#endif @end diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDSDK.h b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDSDK.h index a20b1e462..578322426 100644 --- a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDSDK.h +++ b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/Headers/OMIDSDK.h @@ -7,6 +7,8 @@ #import +NS_ASSUME_NONNULL_BEGIN; + /** * This application level class will be called by all integration partners to ensure OM SDK has been activated before calling any other API methods. * Any attempt to use other API methods prior to activation will result in an error. @@ -20,25 +22,37 @@ /** * The current semantic version of the integrated OMID library. */ -+ (nonnull NSString *)versionString; ++ (NSString *)versionString; /** * Shared OMIDSDK instance. */ -@property(class, readonly, nonnull) OMIDPrebidorgSDK *sharedInstance +@property(class, readonly) OMIDPrebidorgSDK *sharedInstance NS_SWIFT_NAME(shared); /** - * A Boolean value indicating whether the OMID library has been activated. + * A Boolean value indicating whether OM SDK has been activated. * - * The value of this property is YES if the OMID library has already been activated. Allows the integration partner to check that they are compatible with the running OMID library version. + * @discussion Check that OM SDK is active prior to creating any ad sessions. */ -@property(atomic, readonly, getter = isActive) BOOL active; +@property(atomic, readonly, getter=isActive) BOOL active; /** - * Enables the integration partner to activate OMID. + * Activate OM SDK before calling other API methods. + * + * @discussion Activation sets up the OM SDK environment. In CTV apps (running tvOS), `activate` should be called on launch in + * order to capture a "last activity" timestamp on launch and each time the user foregrounds the app). + * + * @return Boolean indicating success. */ - (BOOL)activate; +/** + * Update the last activity time + * After activating OM SDK in CTV apps, refresh the "last activity" timestamp in response to user input prior to starting an ad session. + */ +- (void)updateLastActivity; + @end +NS_ASSUME_NONNULL_END; diff --git a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/libAppVerificationLibrary.a b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/libAppVerificationLibrary.a index 48b1b0d8f..e8d729562 100644 Binary files a/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/libAppVerificationLibrary.a and b/Frameworks/OMSDK-Static_Prebidorg.xcframework/ios-arm64_i386_x86_64-simulator/libAppVerificationLibrary.a differ diff --git a/PrebidMobile/PrebidMobileRendering/Assets/omsdk.js b/PrebidMobile/PrebidMobileRendering/Assets/omsdk.js index 18deb341f..130e06127 100644 --- a/PrebidMobile/PrebidMobileRendering/Assets/omsdk.js +++ b/PrebidMobile/PrebidMobileRendering/Assets/omsdk.js @@ -2,78 +2,77 @@ 'use strict';var n;function aa(a){var b=0;return function(){return bc&&(c=Math.max(c+e,0));cf&&w.yh){m=!0;break}}m&&(c+=Math.round(l)*Math.round(k))}}return c} -function Ba(a,b){a=C(a);for(var c=[],d=[],e=0;eMath.abs(f-c))||(f=b.x,f=f>e||.01>Math.abs(f-e));(e=f)||(e=b.endY,e=eMath.abs(e-d));(d=e)||(b=b.y,d=b>a||.01>Math.abs(b-a));b=!d}return b}function D(a,b){for(var c=!1,d=0;dd.time&&(d=b[e]);c=d;a.g=Kb(c.rootBounds);a.a=Kb(c.boundingClientRect);a.v=Kb(c.intersectionRect);a.H=!!c.isIntersecting;vb(a)}}catch(f){a.m(),eb(a.G,'generic','Problem handling IntersectionObserver callback: '+f.message)}},{root:null,rootMargin:'0px',threshold:[0,.1,.2,.3,.4,.5,.6,.7,.8,.9,1]})} -function Jb(a){a.f.ResizeObserver?a.l||(a.l=Lb(a,function(){return Nb(a)}),a.l.observe(a.b)):(a.o||(a.o=function(){return Nb(a)},(0,a.f.addEventListener)('resize',a.o)),a.j||(a.j=new MutationObserver(function(){return Nb(a)}),a.j.observe(a.b,{childList:!1,attributes:!0,subtree:!1})))}function Nb(a){a.b&&!Ib(a.b)&&(Hb(a),Fb(a))}function Lb(a,b){return new a.f.ResizeObserver(b)}function Kb(a){if(a&&null!==a.x&&null!==a.y&&null!==a.width&&null!==a.height)return new B(a,!1)};function Ob(a){return a&&M(a)?Object.entries(a).reduce(function(b,c){var d=p(c);c=d.next().value;d=d.next().value;return b&&N(c)&&null!=d&&M(d)&&N(d.resourceUrl)},!0):!1};function T(a,b,c,d){this.b=a;this.method=b;this.version=c;this.a=d}function Pb(a){return!!a&&void 0!==a.omid_message_guid&&void 0!==a.omid_message_method&&void 0!==a.omid_message_version&&'string'===typeof a.omid_message_guid&&'string'===typeof a.omid_message_method&&'string'===typeof a.omid_message_version&&(void 0===a.omid_message_args||void 0!==a.omid_message_args)}function Qb(a){return new T(a.omid_message_guid,a.omid_message_method,a.omid_message_version,a.omid_message_args)} -function Rb(a){var b={};b=(b.omid_message_guid=a.b,b.omid_message_method=a.method,b.omid_message_version=a.version,b);void 0!==a.a&&(b.omid_message_args=a.a);return b};function Sb(a){this.c=a};function U(a){this.c=a;this.handleExportedMessage=U.prototype.f.bind(this)}r(U,Sb);U.prototype.b=function(a,b){b=void 0===b?this.c:b;if(!b)throw Error('Message destination must be defined at construction time or when sending the message.');b.handleExportedMessage(Rb(a),this)};U.prototype.f=function(a,b){Pb(a)&&this.a&&this.a(Qb(a),b)};function Tb(a,b){this.c=b=void 0===b?I:b;var c=this;a.addEventListener('message',function(d){if('object'===typeof d.data){var e=d.data;Pb(e)&&d.source&&c.a&&c.a(Qb(e),d.source)}})}r(Tb,Sb);Tb.prototype.b=function(a,b){b=void 0===b?this.c:b;if(!b)throw Error('Message destination must be defined at construction time or when sending the message.');b.postMessage(Rb(a),'*')};function Ub(){return'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g,function(a){var b=16*Math.random()|0;return'y'===a?(b&3|8).toString(16):b.toString(16)})};function Vb(a){if(!a.a||!a.a.document)throw Error('OMID Service Script is not running within a window.');var b=a.b;a.b=[];b.forEach(function(c){try{var d=a.c.C?'limited':'full',e=O(c.accessMode,sa)?c.accessMode:null;var f=e?'full'==e&&'limited'==d?d:'domain'==e?'limited':e:d;c.accessMode=f;a:{var l=c.resourceUrl,g=a.a.location.origin;try{var h=new URL(l,g);break a}catch(V){}try{h=new URL(l);break a}catch(V){}h=null}if(d=h){var k=Ub(),m=a.a.document,u=m.createElement('iframe');u.id='omid-verification-script-frame-'+ -k;u.style.display='none';['full','limited'].includes(f)?u.srcdoc="\n