Esempio n. 1
0
 private void removeInterstitialAd() {
   if (interstitialAd != null) {
     interstitialAd.setAdListener(null);
     interstitialAd.destroy();
     interstitialAd = null;
   }
 }
Esempio n. 2
0
 private void showInterstitialAd(final String adId) {
   removeInterstitialAd();
   interstitialAd = new InterstitialAd(context);
   interstitialAd.setPublisherId(appId);
   interstitialAd.setAdListener(this);
   interstitialAd.loadAd(new AdRequest());
 }