Releases: cleveradssolutions/CAS-Flutter
Releases · cleveradssolutions/CAS-Flutter
Version 4.4.2
Version 4.4.1
- Updated CAS Android and iOS dependencies to 4.4.1
- Renamed
AdError.rejectedtoAdError.codeRejectedfor consistency with other error codes. - Migration to the new Developer Docs
Version 4.3.0
Major changes
- Version bumped to 4.3 to align with native SDK versions.
- Completely rewritten Android and iOS platform code for improved performance, stability, and better integration with native SDKs.
- Introduced new
CASMobileAdsclass. DeprecatedCASandMediationManagerclasses are still available for use but they may be removed in a future release. - The CAS SDK initialization is now done via a single function CASMobileAds.initialize(...) that uses a
Futureto return the new InitializationStatus structure. - The Ad format management has been modernized and streamlined. All ad classes now extend the base AdInstance class and share similar callbacks.
- Introduced
createAndLoad(...)method for each ad format, accepting all possible configuration options and automatically initiating ad loading. This improvement simplifies and optimizes the creation of ad instances. - Introduced support for Native Ads using built-in templates or native platform view factories.
- The Banner ad management is now handled via the CASBanner class, which can be
createAndLoad(...)independently of the widget state and displayed using the newCASWidget. Platform view rendering has been optimized by simplifying the widget class. - The CAS ID only needs to be passed once during initialization if you are using a single ID.
- The AdContentInfo structure now provides ad information synchronously, without requiring
awaitofFuture. - Added the debugGeography to override PrivacyGeography for
ConsentFlowto test different consent dialogs. - The ConsentFlow.show() functions now complete
Future<int>only after the consent form is dismissed and return the resulting consent flow status. - For detailed information on all new functions, please refer to the updated wiki.
- Removed several functions that were previously deprecated.
Migration table
Deprecated functions are still supported but no longer recommended.
| Deprecated | Replacement |
|---|---|
CAS.buildManager()... |
CASMobileAds.initialize(...) |
CAS.targetingOptions... |
CASMobileAds.targetingOptions... |
CAS.settings.setMutedAdSounds() |
CASMobileAds.setAdSoundsMuted() |
CAS.settings.setDebugMode() |
CASMobileAds.setDebugLoggingEnabled() |
CAS.settings.setTrialAdFreeInterval() |
CASMobileAds.setTrialAdFreeInterval() |
CAS.settings.setTaggedAudience() |
CASMobileAds.initialize(targetAudience:) |
CAS.settings.setTestDeviceId() |
CASMobileAds.initialize(testDeviceIds:) |
CASInterstitial.create() |
CASInterstitial.createAndLoad(...) |
CASInterstitial.impressionListener |
CASInterstitial.onAdImpression |
CASInterstitial.contentCallback |
CASInterstitial.onAdLoaded and others |
CASAppOpen.create() |
CASAppOpen.createAndLoad(...) |
CASAppOpen.impressionListener |
CASAppOpen.onAdImpression |
CASAppOpen.contentCallback |
CASAppOpen.onAdLoaded and others |
CASRewarded.create() |
CASRewarded.createAndLoad(...) |
CASRewarded.impressionListener |
CASRewarded.onAdImpression |
CASRewarded.contentCallback |
CASRewarded.onAdLoaded and others |
OnRewardEarnedListener |
CASRewarded.onUserEarnedReward |
BannerWidgetState()... |
CASBanner.createAndLoad(...) |
BannerWidget(...) |
CASWidget(ad:) |
AdSize.getAdaptiveBannerInScreen() |
maxWidth = MediaQuery.of(context).size.widthand AdSize.getAdaptiveBanner(maxWidth) |
Version 0.9.0
- Updated CAS Android and iOS dependencies to 4.3.0
- Updated
AdErrorcodes for compatibility with CAS 4.
Bug Fixes
- Fixed a type mismatch issue in
AdErrorFactory. #46 - Fixed an
IndexOutOfRangeExceptioninonConsentFlowDismissed(). - Fixed a
MissingPluginExceptioninCASInterstitial.setMinInterval(). - [iOS] Fixed
OnImpressionListenernot being triggered forBannerWidget.
Deprecations
The following functions are deprecated. They are still supported for now but are not recommended for use in new implementations.
- Deprecated
ConsentFlow.withDismissListener(OnDismissListener)as it always returnsConsentStatus.undefined. UseConsentFlow.setOnDismissCallback(OnConsentFlowDismissedCallback)instead, which provides a validintstatus. Refer to constants inConsentFlowfor status values. - Deprecated
MediationManager.enableAppReturn(). Migrate to the newCASAppOpenorCASInterstitialAPIs and enable this feature via theisAutoshowEnabledproperty. - Deprecated
MediationManager.setAdLoadCallback()as it's no longer the recommended way to listen for ad loading events. Use the new implementation in individual ad classes instead. - Deprecated
AdContentInfo.getSourceId()as it's no longer recommended and will be removed in future versions. UsegetSourceName()instead. - Deprecated
AdsSettings.setLoadingMode()in favor of the new ad class implementation, which provides full control over the ad lifecycle.
Version 0.8.9
- Fixed
BannerWidgetStateImpl.disposefailed to callsuper.disposeissue #45.
Version 0.8.8
- [Android] Fixed build failure related to missing style attribute
windowOptOutEdgeToEdgeEnforcementby increasingcompileSdkVersionto 35 in the plugin.
Version 0.8.7
Version 0.8.5
Version 0.8.4
- Hotfix the native 4.1.0.1 iOS.