Esempio n. 1
0
        void OnGUIAdmobInterstitialSettings()
        {
            AdGUIHelper.BeginSessionGroup();
            AdGUIHelper.Session("Interstitials");
            if (AdGUIHelper.HeaderButton(AddIcon))
            {
                Settings.localConfig.admobInterstitials.Add(new AdmobInterstitialAdUnit(""));
            }
            AdGUIHelper.EndSessionGroup();

            AdGUIHelper.BeginGroupedControls();
            if (Settings.localConfig.admobInterstitials.Count > 0)
            {
                for (int i = 0; i < Settings.localConfig.admobInterstitials.Count; i++)
                {
                    var ad = Settings.localConfig.admobInterstitials[i];
                    OnAdmobInterstitialAdUnit(ad, Settings.localConfig.admobInterstitials);
                }
            }
            else
            {
                AdGUIHelper.Help(AdString.empty_list_hint);
            }
            AdGUIHelper.EndGroupedControls();
        }
Esempio n. 2
0
        void OnFbNativeSettings()
        {
            AdGUIHelper.BeginSessionGroup();
            AdGUIHelper.Session("Native Ads");
            if (AdGUIHelper.HeaderButton(AddIcon))
            {
                Settings.localConfig.fbNativeAds.Add(new FBNativeAdUnit(""));
            }
            AdGUIHelper.EndSessionGroup();

            AdGUIHelper.BeginGroupedControls();
            if (Settings.localConfig.fbNativeAds.Count > 0)
            {
                for (int i = Settings.localConfig.fbNativeAds.Count - 1; i >= 0; i--)
                {
                    var ad = Settings.localConfig.fbNativeAds[i];
                    OnFbNativeAdUnit(ad, Settings.localConfig.fbNativeAds);
                }
            }
            else
            {
                AdGUIHelper.Help(AdString.empty_list_hint);
            }
            AdGUIHelper.EndGroupedControls();
        }
Esempio n. 3
0
        void OnGUIAdmobBanner()
        {
            AdGUIHelper.BeginSessionGroup();
            AdGUIHelper.Session("Banners");
            if (AdGUIHelper.HeaderButton(AddIcon))
            {
                Settings.localConfig.AdmobBannerUnits.Add(new AdmobBannerUnit(""));
            }
            AdGUIHelper.EndSessionGroup();

            AdGUIHelper.BeginGroupedControls();
            if (Settings.localConfig.AdmobBannerUnits.Count > 0)
            {
                EditorGUILayout.BeginVertical();
                for (int i = 0; i < Settings.localConfig.AdmobBannerUnits.Count; i++)
                {
                    var banner = Settings.localConfig.AdmobBannerUnits[i];
                    OnGUIAdmobBannerAdUnit(banner, Settings.localConfig.AdmobBannerUnits);
                }
                EditorGUILayout.EndVertical();
            }
            else
            {
                AdGUIHelper.Help(AdString.empty_list_hint);
            }
            AdGUIHelper.EndGroupedControls();
        }