public void ShowBanner() { if (!this.bannerEnabled) { return; } FMLogger.vAds("show banner inv"); MoPubAndroid.ShowBanner(this.bannerAdUnit, true); this.bannerVisable = true; if (this.userBannerImpression) { this.userBannerImpression = false; AnalyticsManager.BannerImpression(this.bannerAdUnit, this.currentBannerGUID, AdsManager.Instance.IsTabletAdUnit, this.bannerPosition == MoPubBase.AdPosition.BottomCenter); } }
private void onAdLoadedEvent(string adUnit, float height) { this.currentBannerGUID = AnalyticsUtils.GenerateGUID(); this.userBannerImpression = true; FMLogger.vAds("onAdLoadedEvent. height: " + height); if (this.bannerVisable) { this.userBannerImpression = false; AnalyticsManager.BannerImpression(this.bannerAdUnit, this.currentBannerGUID, AdsManager.Instance.IsTabletAdUnit, this.bannerPosition == MoPubBase.AdPosition.BottomCenter); } else { FMLogger.vAds("hide banner loaded event. workaround"); MoPubAndroid.ShowBanner(this.bannerAdUnit, false); } }