Upgrade compileSdkVersion
This commit is contained in:
parent
62467a3fe1
commit
18c19ace49
|
@ -1,12 +1,12 @@
|
||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 29
|
compileSdkVersion 30
|
||||||
buildToolsVersion "29.0.3"
|
buildToolsVersion "30.0.2"
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "org.eu.exodus_privacy.exodusprivacy"
|
applicationId "org.eu.exodus_privacy.exodusprivacy"
|
||||||
minSdkVersion 17
|
minSdkVersion 17
|
||||||
targetSdkVersion 29
|
targetSdkVersion 30
|
||||||
versionCode 10
|
versionCode 10
|
||||||
versionName "2.1.1"
|
versionName "2.1.1"
|
||||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||||
|
@ -34,10 +34,10 @@ dependencies {
|
||||||
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2.2', {
|
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2.2', {
|
||||||
exclude group: 'com.android.support', module: 'support-annotations'
|
exclude group: 'com.android.support', module: 'support-annotations'
|
||||||
})
|
})
|
||||||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
implementation 'androidx.appcompat:appcompat:1.2.0'
|
||||||
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
|
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
|
||||||
implementation 'androidx.recyclerview:recyclerview:1.1.0'
|
implementation 'androidx.recyclerview:recyclerview:1.1.0'
|
||||||
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
|
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
|
||||||
implementation 'com.google.android.material:material:1.1.0'
|
implementation 'com.google.android.material:material:1.2.1'
|
||||||
testImplementation 'junit:junit:4.13'
|
testImplementation 'junit:junit:4.13.1'
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,7 @@ import java.text.SimpleDateFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.Date;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -93,7 +94,7 @@ public class NetworkManager {
|
||||||
UNKNOWN
|
UNKNOWN
|
||||||
}
|
}
|
||||||
|
|
||||||
private class NetworkProcessingThread extends Thread {
|
private static class NetworkProcessingThread extends Thread {
|
||||||
private final String apiUrl = "https://reports.exodus-privacy.eu.org/api/";
|
private final String apiUrl = "https://reports.exodus-privacy.eu.org/api/";
|
||||||
private final List<Message> messageQueue;
|
private final List<Message> messageQueue;
|
||||||
private final Semaphore sem;
|
private final Semaphore sem;
|
||||||
|
@ -116,6 +117,7 @@ public class NetworkManager {
|
||||||
try {
|
try {
|
||||||
sem.acquire();
|
sem.acquire();
|
||||||
Message mes = messageQueue.remove(0);
|
Message mes = messageQueue.remove(0);
|
||||||
|
//noinspection SwitchStatementWithTooFewBranches
|
||||||
switch (mes.type) {
|
switch (mes.type) {
|
||||||
case GET_REPORTS:
|
case GET_REPORTS:
|
||||||
getTrackers(mes);
|
getTrackers(mes);
|
||||||
|
@ -338,12 +340,18 @@ public class NetworkManager {
|
||||||
try {
|
try {
|
||||||
report.updateDate = Calendar.getInstance();
|
report.updateDate = Calendar.getInstance();
|
||||||
report.updateDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
report.updateDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||||
report.updateDate.setTime(dateFormat.parse(object.getString("updated_at")));
|
Date date = dateFormat.parse(object.getString("updated_at"));
|
||||||
|
if (date != null) {
|
||||||
|
report.updateDate.setTime(date);
|
||||||
|
}
|
||||||
report.updateDate.set(Calendar.MILLISECOND, 0);
|
report.updateDate.set(Calendar.MILLISECOND, 0);
|
||||||
|
|
||||||
report.creationDate = Calendar.getInstance();
|
report.creationDate = Calendar.getInstance();
|
||||||
report.creationDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
report.creationDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||||
report.creationDate.setTime(dateFormat.parse(object.getString("creation_date")));
|
date = dateFormat.parse(object.getString("creation_date"));
|
||||||
|
if (date != null) {
|
||||||
|
report.creationDate.setTime(date);
|
||||||
|
}
|
||||||
report.creationDate.set(Calendar.MILLISECOND, 0);
|
report.creationDate.set(Calendar.MILLISECOND, 0);
|
||||||
} catch (ParseException e) {
|
} catch (ParseException e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
|
@ -367,7 +375,10 @@ public class NetworkManager {
|
||||||
try {
|
try {
|
||||||
tracker.creationDate = Calendar.getInstance();
|
tracker.creationDate = Calendar.getInstance();
|
||||||
tracker.creationDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
tracker.creationDate.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||||
tracker.creationDate.setTime(dateFormat.parse(object.getString("creation_date")));
|
Date date = dateFormat.parse(object.getString("creation_date"));
|
||||||
|
if (date != null) {
|
||||||
|
tracker.creationDate.setTime(date);
|
||||||
|
}
|
||||||
} catch (ParseException e) {
|
} catch (ParseException e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
@ -410,7 +421,7 @@ public class NetworkManager {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private class Message {
|
private static class Message {
|
||||||
Message_Type type = Message_Type.UNKNOWN;
|
Message_Type type = Message_Type.UNKNOWN;
|
||||||
Bundle args = new Bundle();
|
Bundle args = new Bundle();
|
||||||
NetworkListener listener;
|
NetworkListener listener;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#Mon Dec 07 08:49:24 CET 2020
|
#Mon Dec 07 09:33:34 CET 2020
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-all.zip
|
||||||
|
|
Loading…
Reference in New Issue