From 960c77d46c8223bf7d731a68e5262cfcd6d8b4d2 Mon Sep 17 00:00:00 2001 From: sdk Date: Wed, 3 Oct 2018 13:20:14 +0300 Subject: [PATCH] Auto build v1.4.17 --- avocarrot-admob-banner/README.md | 4 +-- avocarrot-admob-interstitial/README.md | 4 +-- avocarrot-admob-nativead/README.md | 4 +-- avocarrot-app-sample/build.gradle | 32 +++++++++---------- .../sample/mopub/MopubConfigActivity.java | 25 +++++++++++++-- avocarrot-mopub-banner/README.md | 4 +-- avocarrot-mopub-interstitial/README.md | 4 +-- avocarrot-mopub-nativead/README.md | 4 +-- build.gradle | 2 +- gradle/wrapper/gradle-wrapper.properties | 4 +-- settings.gradle | 2 +- 11 files changed, 55 insertions(+), 34 deletions(-) diff --git a/avocarrot-admob-banner/README.md b/avocarrot-admob-banner/README.md index e633b93..9eae0cc 100644 --- a/avocarrot-admob-banner/README.md +++ b/avocarrot-admob-banner/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the AdMob or DFP Android SDK. ## Requirements -* Google Mobile Ads SDK version 11.8.0. -* Avocarrot Android SDK v4.10.1. +* Google Mobile Ads SDK version 15.0.1. +* Avocarrot Android SDK v4.10.3. ## Instructions diff --git a/avocarrot-admob-interstitial/README.md b/avocarrot-admob-interstitial/README.md index 1ca00f6..154804e 100644 --- a/avocarrot-admob-interstitial/README.md +++ b/avocarrot-admob-interstitial/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the AdMob or DFP Android SDK. ## Requirements -* Google Mobile Ads SDK version 11.8.0. -* Avocarrot Android SDK v4.10.1. +* Google Mobile Ads SDK version 15.0.1. +* Avocarrot Android SDK v4.10.3. ## Instructions diff --git a/avocarrot-admob-nativead/README.md b/avocarrot-admob-nativead/README.md index ed44951..e0f3419 100644 --- a/avocarrot-admob-nativead/README.md +++ b/avocarrot-admob-nativead/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the AdMob Android SDK. ## Requirements -* Google Mobile Ads SDK version 11.8.0. -* Avocarrot Android SDK v4.10.1. +* Google Mobile Ads SDK version 15.0.1. +* Avocarrot Android SDK v4.10.3. ## Instructions diff --git a/avocarrot-app-sample/build.gradle b/avocarrot-app-sample/build.gradle index bc13412..4fa3b77 100644 --- a/avocarrot-app-sample/build.gradle +++ b/avocarrot-app-sample/build.gradle @@ -1,13 +1,13 @@ apply plugin: 'com.android.application' android { - compileSdkVersion 27 - buildToolsVersion "27.0.3" + compileSdkVersion 28 + buildToolsVersion "28.0.3" defaultConfig { minSdkVersion 16 //noinspection OldTargetApi - targetSdkVersion 27 + targetSdkVersion 28 versionCode 1 versionName VERSION_NAME @@ -27,18 +27,18 @@ android { } dependencies { - compile 'com.android.support:multidex:1.0.3' - compile 'com.android.support:appcompat-v7:27.1.0' - compile 'com.android.support:design:27.1.0' - compile 'com.facebook.stetho:stetho:1.5.0' - compile 'com.jakewharton:process-phoenix:2.0.0' - compile 'com.squareup.leakcanary:leakcanary-android:1.5.1' - compile 'org.jooq:joor:0.9.6' + implementation 'com.android.support:multidex:1.0.3' + implementation 'com.android.support:appcompat-v7:28.0.0' + implementation 'com.android.support:design:28.0.0' + implementation 'com.facebook.stetho:stetho:1.5.0' + implementation 'com.jakewharton:process-phoenix:2.0.0' + implementation 'com.squareup.leakcanary:leakcanary-android:1.5.1' + implementation 'org.jooq:joor:0.9.6' // - compile project(':adapter-mopub-nativead') - compile project(':adapter-mopub-banner') - compile project(':adapter-mopub-interstitial') - compile project(':adapter-admob-banner') - compile project(':adapter-admob-interstitial') - compile project(':adapter-admob-nativead') + implementation project(':adapter-mopub-nativead') + implementation project(':adapter-mopub-banner') + implementation project(':adapter-mopub-interstitial') + implementation project(':adapter-admob-banner') + implementation project(':adapter-admob-interstitial') + implementation project(':adapter-admob-nativead') } diff --git a/avocarrot-app-sample/src/main/java/com/avocarrot/adapters/sample/mopub/MopubConfigActivity.java b/avocarrot-app-sample/src/main/java/com/avocarrot/adapters/sample/mopub/MopubConfigActivity.java index 99bb9d4..45b78b4 100644 --- a/avocarrot-app-sample/src/main/java/com/avocarrot/adapters/sample/mopub/MopubConfigActivity.java +++ b/avocarrot-app-sample/src/main/java/com/avocarrot/adapters/sample/mopub/MopubConfigActivity.java @@ -1,5 +1,6 @@ package com.avocarrot.adapters.sample.mopub; +import android.app.Activity; import android.content.Context; import android.content.Intent; import android.os.Bundle; @@ -19,6 +20,10 @@ import com.avocarrot.adapters.sample.IntentStarter; import com.avocarrot.adapters.sample.R; import com.avocarrot.adapters.sample.ScreenAdType; +import com.avocarrot.sdk.Avocarrot; +import com.mopub.common.MoPub; +import com.mopub.common.SdkConfiguration; +import com.mopub.common.SdkInitializationListener; public class MopubConfigActivity extends AppCompatActivity { @NonNull @@ -86,8 +91,24 @@ private void attempt(final int adTypeScreen) { adUnitIdView.setError(getString(R.string.error_field_required)); adUnitIdView.requestFocus(); } else { - IntentStarter.startMopubAdTypeActivity(this, adTypeScreen, adUnitId); - finish(); + Avocarrot.setDebugMode(true); + if (MoPub.isSdkInitialized()) { + IntentStarter.startMopubAdTypeActivity(this, adTypeScreen, adUnitId); + finish(); + } else { + SdkConfiguration sdkConfiguration = new SdkConfiguration.Builder(adUnitId).build(); + MoPub.initializeSdk(this, sdkConfiguration, initSdkListener(this, adTypeScreen, adUnitId)); + } } } + + private SdkInitializationListener initSdkListener(final Activity activity, final int adTypeScreen, final String adUnitId) { + return new SdkInitializationListener() { + @Override + public void onInitializationFinished() { + IntentStarter.startMopubAdTypeActivity(activity, adTypeScreen, adUnitId); + finish(); + } + }; + } } diff --git a/avocarrot-mopub-banner/README.md b/avocarrot-mopub-banner/README.md index f219252..eda30a7 100644 --- a/avocarrot-mopub-banner/README.md +++ b/avocarrot-mopub-banner/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the MoPub Android SDK. ## Requirements -* MoPub Android SDK v4.18.0 or later. -* Avocarrot Android SDK v4.10.1 or later. +* MoPub Android SDK v5.3.0 or later. +* Avocarrot Android SDK v4.10.3 or later. ## Instructions diff --git a/avocarrot-mopub-interstitial/README.md b/avocarrot-mopub-interstitial/README.md index 07ac94d..6de32ed 100644 --- a/avocarrot-mopub-interstitial/README.md +++ b/avocarrot-mopub-interstitial/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the MoPub Android SDK. ## Requirements -* MoPub Android SDK v4.18.0 or later. -* Avocarrot Android SDK v4.10.1 or later. +* MoPub Android SDK v5.3.0 or later. +* Avocarrot Android SDK v4.10.3 or later. ## Instructions diff --git a/avocarrot-mopub-nativead/README.md b/avocarrot-mopub-nativead/README.md index e28c630..1487b0e 100644 --- a/avocarrot-mopub-nativead/README.md +++ b/avocarrot-mopub-nativead/README.md @@ -4,8 +4,8 @@ This is an adapter to be used in conjunction with the MoPub Android SDK. ## Requirements -* MoPub Android SDK v4.18.0 or later. -* Avocarrot Android SDK v4.10.1 or later. +* MoPub Android SDK v5.3.0 or later. +* Avocarrot Android SDK v4.10.3 or later. ## Instructions diff --git a/build.gradle b/build.gradle index 631ac23..d914147 100644 --- a/build.gradle +++ b/build.gradle @@ -4,7 +4,7 @@ buildscript { google() } dependencies { - classpath 'com.android.tools.build:gradle:3.0.1' + classpath 'com.android.tools.build:gradle:3.2.0' classpath 'de.felixschulze.gradle:gradle-hockeyapp-plugin:3.6' } } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 1b78a9a..ea91888 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Thu Mar 29 13:38:12 EEST 2018 +#Mon Oct 01 15:49:27 EEST 2018 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip diff --git a/settings.gradle b/settings.gradle index 846a2cf..fd922ed 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1 +1 @@ -VERSION_NAME=1.4.16 +VERSION_NAME=1.4.17