Skip to content

Commit

Permalink
Merge pull request #416 from adjust/v4200
Browse files Browse the repository at this point in the history
Version 4.20.0
  • Loading branch information
nonelse authored Jan 15, 2020
2 parents 1b9a96e + d5c9338 commit 8e3e327
Show file tree
Hide file tree
Showing 67 changed files with 218 additions and 347 deletions.
8 changes: 4 additions & 4 deletions Adjust/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,17 @@ subprojects {
ext {
// Android config.
coreMinSdkVersion = 9
coreCompileSdkVersion = 28
coreTargetSdkVersion = 28
coreVersionName = '4.19.1' //append -SNAPSHOT for snapshot version
coreCompileSdkVersion = 29
coreTargetSdkVersion = 29
coreVersionName = '4.20.0' //append -SNAPSHOT for snapshot version
defaultVersionCode = 1

// POM.
adjustGroupId = 'com.adjust.sdk'
}

buildscript {
ext.kotlin_version = '1.3.10'
ext.kotlin_version = '1.3.50'

repositories {
jcenter()
Expand Down
15 changes: 7 additions & 8 deletions Adjust/example-app-fbpixel/build.gradle
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 28
compileSdkVersion 29

defaultConfig {
applicationId "com.adjust.examples"
minSdkVersion 14
targetSdkVersion 28
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}

buildTypes {
Expand All @@ -22,11 +21,11 @@ android {

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation "androidx.constraintlayout:constraintlayout:1.1.3"
implementation 'com.google.android.gms:play-services-analytics:17.0.0'
implementation 'com.android.installreferrer:installreferrer:1.1'

implementation project(':sdk-core')
implementation project(':sdk-plugin-webbridge')
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
package com.adjust.examples;

import android.content.Intent;
import android.net.Uri;
import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.util.Log;
import android.webkit.ConsoleMessage;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
Expand All @@ -10,4 +9,4 @@
android:id="@+id/webView1"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
</android.support.constraint.ConstraintLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

This file was deleted.

23 changes: 7 additions & 16 deletions Adjust/example-app-java/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ repositories {
}

android {
compileSdkVersion 28
compileSdkVersion 29

defaultConfig {
applicationId "com.adjust.examples"
minSdkVersion 14
targetSdkVersion 28
targetSdkVersion 29
versionCode 1
versionName "1.0"
}
Expand All @@ -25,20 +25,11 @@ android {
}

dependencies {
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.google.android.gms:play-services-analytics:16.0.4'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation "androidx.constraintlayout:constraintlayout:1.1.3"
implementation 'com.google.android.gms:play-services-analytics:17.0.0'
implementation 'com.android.installreferrer:installreferrer:1.1'

// Add SDK via module.
implementation project(':sdk-core')
// implementation project(':plugin-imei')
// implementation project(":plugin-play")
// Add SDK via Maven.
// implementation 'com.adjust.sdk:adjust-android:4.19.1'

debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.6.2'
releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.6.2'

// Add new referrer API support.
implementation 'com.android.installreferrer:installreferrer:1.0'
implementation project(path: ':sdk-plugin-oaid')
}

This file was deleted.

2 changes: 1 addition & 1 deletion Adjust/example-app-java/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
<data android:scheme="adjust-example" />
</intent-filter>
</activity>
<activity android:name=".ServiceActivity"></activity>
<activity android:name=".ServiceActivity"/>

<service
android:name=".ServiceExample"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import android.app.Application;
import android.net.Uri;
import android.os.Bundle;
import android.os.StrictMode;
import android.util.Log;

import com.adjust.sdk.Adjust;
Expand All @@ -21,7 +20,6 @@
import com.adjust.sdk.OnSessionTrackingSucceededListener;
import com.adjust.sdk.AdjustSessionFailure;
import com.adjust.sdk.AdjustSessionSuccess;
import com.squareup.leakcanary.LeakCanary;

/**
* Created by pfms on 17/12/14.
Expand All @@ -30,22 +28,7 @@ public class GlobalApplication extends Application {
@Override
public void onCreate() {
super.onCreate();
if (LeakCanary.isInAnalyzerProcess(this)) {
// This process is dedicated to LeakCanary for heap analysis.
// You should not init your app in this process.
return;
}
LeakCanary.install(this);
/*
StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder()
.detectAll()
.penaltyLog()
.build());
StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder()
.detectAll()
.penaltyLog()
.build());
*/

// Configure adjust SDK.
String appToken = "2fm9gkqubvpc";
String environment = AdjustConfig.ENVIRONMENT_SANDBOX;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;

import androidx.appcompat.app.AppCompatActivity;

import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
Expand All @@ -14,10 +16,10 @@
import com.adjust.sdk.AdjustEvent;

public class MainActivity extends AppCompatActivity {
private static final String EVENT_TOKEN_SIMPLE = "g3mfiw";
private static final String EVENT_TOKEN_REVENUE = "a4fd35";
private static final String EVENT_TOKEN_CALLBACK = "34vgg9";
private static final String EVENT_TOKEN_PARTNER = "w788qs";
private static final String EVENT_TOKEN_SIMPLE = "g3mfiw";
private static final String EVENT_TOKEN_REVENUE = "a4fd35";
private static final String EVENT_TOKEN_CALLBACK = "34vgg9";
private static final String EVENT_TOKEN_PARTNER = "w788qs";

private Button btnEnableDisableSDK;

Expand All @@ -31,7 +33,7 @@ protected void onCreate(Bundle savedInstanceState) {
Adjust.appWillOpenUrl(data, getApplicationContext());

// Adjust UI according to SDK state.
btnEnableDisableSDK = (Button)findViewById(R.id.btnEnableDisableSDK);
btnEnableDisableSDK = (Button) findViewById(R.id.btnEnableDisableSDK);
}

@Override
Expand Down Expand Up @@ -103,23 +105,23 @@ public void onTrackPartnerEventClick(View v) {
}

public void onEnableDisableOfflineModeClick(View v) {
if (((Button)v).getText().equals(
if (((Button) v).getText().equals(
getApplicationContext().getResources().getString(R.string.txt_enable_offline_mode))) {
Adjust.setOfflineMode(true);
((Button)v).setText(R.string.txt_disable_offline_mode);
((Button) v).setText(R.string.txt_disable_offline_mode);
} else {
Adjust.setOfflineMode(false);
((Button)v).setText(R.string.txt_enable_offline_mode);
((Button) v).setText(R.string.txt_enable_offline_mode);
}
}

public void onEnableDisableSDKClick(View v) {
if (Adjust.isEnabled()) {
Adjust.setEnabled(false);
((Button)v).setText(R.string.txt_enable_sdk);
((Button) v).setText(R.string.txt_enable_sdk);
} else {
Adjust.setEnabled(true);
((Button)v).setText(R.string.txt_disable_sdk);
((Button) v).setText(R.string.txt_disable_sdk);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

import android.content.Intent;
import android.net.Uri;
import android.support.v7.app.AppCompatActivity;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.view.View;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* Created by pfms on 16/03/16.
*/
public class ServiceExample extends Service {
private static final String EVENT_TOKEN_BACKGROUND = "pkd28h";
private static final String EVENT_TOKEN_BACKGROUND = "pkd28h";

private static boolean flip = true;

Expand Down Expand Up @@ -49,7 +49,7 @@ public int onStartCommand(Intent intent, int flags, int startId) {
flip = true;
}

new AsyncTask<Void,Void,Void>() {
new AsyncTask<Void, Void, Void>() {
@Override
protected Void doInBackground(Void... params) {
Log.d("example", "ServiceExample background sleeping");
Expand Down
23 changes: 9 additions & 14 deletions Adjust/example-app-kotlin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,17 @@ apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
android {
compileSdkVersion 28
compileSdkVersion 29



defaultConfig {
applicationId "com.adjust.examples"
minSdkVersion 15
targetSdkVersion 28
minSdkVersion 14
targetSdkVersion 29
versionCode 1
versionName "1.0"

testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

}

buildTypes {
Expand All @@ -27,14 +25,11 @@ android {
}

dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation "androidx.constraintlayout:constraintlayout:1.1.3"
implementation 'com.google.android.gms:play-services-analytics:17.0.0'
implementation 'com.android.installreferrer:installreferrer:1.1'

implementation project(':sdk-core')
implementation 'com.google.android.gms:play-services-analytics:16.0.7'
implementation 'com.android.installreferrer:installreferrer:1.0'
}

This file was deleted.

Loading

0 comments on commit 8e3e327

Please sign in to comment.