diff --git a/.idea/misc.xml b/.idea/misc.xml
index 33782299c..7c7f635d6 100644
--- a/.idea/misc.xml
+++ b/.idea/misc.xml
@@ -5,7 +5,7 @@
-
+
diff --git a/app/src/main/java/com/todoroo/astrid/api/IdListFilter.java b/app/src/main/java/com/todoroo/astrid/api/IdListFilter.java
deleted file mode 100644
index 92c38609f..000000000
--- a/app/src/main/java/com/todoroo/astrid/api/IdListFilter.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package com.todoroo.astrid.api;
-
-import android.os.Parcel;
-import com.google.common.primitives.Longs;
-import com.todoroo.andlib.sql.Join;
-import com.todoroo.andlib.sql.QueryTemplate;
-import com.todoroo.astrid.data.Task;
-import java.util.List;
-import org.tasks.data.Tag;
-
-public class IdListFilter extends Filter {
-
- public static final Creator CREATOR =
- new Creator() {
-
- @Override
- public IdListFilter createFromParcel(Parcel source) {
- return new IdListFilter(source);
- }
-
- @Override
- public IdListFilter[] newArray(int size) {
- return new IdListFilter[size];
- }
- };
-
- private List ids;
-
- public IdListFilter(List ids) {
- super("", getQueryTemplate(ids));
- this.ids = ids;
- }
-
- private IdListFilter(Parcel source) {
- readFromParcel(source);
- }
-
- private static QueryTemplate getQueryTemplate(List ids) {
- return new QueryTemplate()
- .join(Join.left(Tag.TABLE, Tag.TASK.eq(Task.ID)))
- .where(Task.ID.in(ids));
- }
-
- @Override
- public void writeToParcel(Parcel dest, int flags) {
- super.writeToParcel(dest, flags);
- dest.writeLongArray(Longs.toArray(ids));
- }
-
- @Override
- protected void readFromParcel(Parcel source) {
- super.readFromParcel(source);
- long[] ids = new long[source.readInt()];
- source.setDataPosition(source.dataPosition() - 1);
- source.readLongArray(ids);
- this.ids = Longs.asList(ids);
- }
-}
diff --git a/app/src/main/java/com/todoroo/astrid/api/IdListFilter.kt b/app/src/main/java/com/todoroo/astrid/api/IdListFilter.kt
new file mode 100644
index 000000000..38fb9a333
--- /dev/null
+++ b/app/src/main/java/com/todoroo/astrid/api/IdListFilter.kt
@@ -0,0 +1,48 @@
+package com.todoroo.astrid.api
+
+import android.os.Parcel
+import android.os.Parcelable
+import com.google.common.primitives.Longs
+import com.todoroo.andlib.sql.Join.Companion.left
+import com.todoroo.andlib.sql.QueryTemplate
+import com.todoroo.astrid.data.Task
+import org.tasks.data.Tag
+
+class IdListFilter : Filter {
+ private var ids: List? = null
+
+ constructor(ids: List) : super("", getQueryTemplate(ids)) {
+ this.ids = ids
+ }
+
+ private constructor(source: Parcel) {
+ readFromParcel(source)
+ }
+
+ override fun writeToParcel(dest: Parcel, flags: Int) {
+ super.writeToParcel(dest, flags)
+ dest.writeLongArray(Longs.toArray(ids!!))
+ }
+
+ override fun readFromParcel(source: Parcel) {
+ super.readFromParcel(source)
+ val ids = LongArray(source.readInt())
+ source.setDataPosition(source.dataPosition() - 1)
+ source.readLongArray(ids)
+ this.ids = Longs.asList(*ids)
+ }
+
+ companion object {
+ @JvmField val CREATOR: Parcelable.Creator = object : Parcelable.Creator {
+ override fun createFromParcel(source: Parcel) = IdListFilter(source)
+
+ override fun newArray(size: Int): Array = arrayOfNulls(size)
+ }
+
+ private fun getQueryTemplate(ids: List): QueryTemplate {
+ return QueryTemplate()
+ .join(left(Tag.TABLE, Tag.TASK.eq(Task.ID)))
+ .where(Task.ID.`in`(ids))
+ }
+ }
+}
\ No newline at end of file
diff --git a/build.gradle.kts b/build.gradle.kts
index 369ff3ce0..14b6a9e56 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -6,15 +6,15 @@ buildscript {
}
dependencies {
- classpath("com.android.tools.build:gradle:4.1.2")
+ classpath("com.android.tools.build:gradle:4.2.0-beta05")
classpath("com.google.gms:google-services:4.3.5")
- classpath("com.google.firebase:firebase-crashlytics-gradle:2.4.1")
+ classpath("com.google.firebase:firebase-crashlytics-gradle:2.5.0")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${Versions.kotlin}")
classpath("com.google.dagger:hilt-android-gradle-plugin:${Versions.hilt}")
}
}
tasks.getByName("wrapper") {
- gradleVersion = "6.1.1"
+ gradleVersion = "6.7.1"
distributionType = Wrapper.DistributionType.ALL
}
diff --git a/deps_fdroid.txt b/deps_fdroid.txt
index e9ee72c88..468b2dcc0 100644
--- a/deps_fdroid.txt
+++ b/deps_fdroid.txt
@@ -1,8 +1,8 @@
-++--- androidx.databinding:viewbinding:4.1.2
+++--- androidx.databinding:viewbinding:4.2.0-beta05
+| \--- androidx.annotation:annotation:1.0.0 -> 1.1.0
-++--- androidx.databinding:databinding-common:4.1.2
-++--- androidx.databinding:databinding-runtime:4.1.2
-+| +--- androidx.databinding:viewbinding:4.1.2 (*)
+++--- androidx.databinding:databinding-common:4.2.0-beta05
+++--- androidx.databinding:databinding-runtime:4.2.0-beta05
++| +--- androidx.databinding:viewbinding:4.2.0-beta05 (*)
+| +--- androidx.lifecycle:lifecycle-runtime:2.0.0 -> 2.3.0
+| | +--- androidx.arch.core:core-runtime:2.1.0
+| | | +--- androidx.annotation:annotation:1.1.0
@@ -14,10 +14,10 @@
+| | \--- androidx.annotation:annotation:1.1.0
+| +--- androidx.collection:collection:1.0.0 -> 1.1.0
+| | \--- androidx.annotation:annotation:1.1.0
-+| \--- androidx.databinding:databinding-common:4.1.2
-++--- androidx.databinding:databinding-adapters:4.1.2
-+| +--- androidx.databinding:databinding-common:4.1.2
-+| \--- androidx.databinding:databinding-runtime:4.1.2 (*)
++| \--- androidx.databinding:databinding-common:4.2.0-beta05
+++--- androidx.databinding:databinding-adapters:4.2.0-beta05
++| +--- androidx.databinding:databinding-common:4.2.0-beta05
++| \--- androidx.databinding:databinding-runtime:4.2.0-beta05 (*)
++--- com.gitlab.abaker:dav4jvm:deb2c9aef8
+| +--- org.jetbrains.kotlin:kotlin-stdlib:1.4.10 -> 1.4.30
+| | +--- org.jetbrains.kotlin:kotlin-stdlib-common:1.4.30
@@ -47,9 +47,9 @@
+| | \--- androidx.collection:collection:1.0.0 -> 1.1.0 (*)
+| \--- androidx.collection:collection:1.0.0 -> 1.1.0 (*)
++--- com.gitlab.bitfireAT:cert4android:26a91a729f
-+| +--- androidx.databinding:databinding-common:4.1.1 -> 4.1.2
-+| +--- androidx.databinding:databinding-runtime:4.1.1 -> 4.1.2 (*)
-+| +--- androidx.databinding:databinding-adapters:4.1.1 -> 4.1.2 (*)
++| +--- androidx.databinding:databinding-common:4.1.1 -> 4.2.0-beta05
++| +--- androidx.databinding:databinding-runtime:4.1.1 -> 4.2.0-beta05 (*)
++| +--- androidx.databinding:databinding-adapters:4.1.1 -> 4.2.0-beta05 (*)
+| +--- org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.4.21 (*)
+| +--- androidx.appcompat:appcompat:1.2.0
+| | +--- androidx.annotation:annotation:1.1.0
diff --git a/deps_googleplay.txt b/deps_googleplay.txt
index d2a528d79..a1cd19dee 100644
--- a/deps_googleplay.txt
+++ b/deps_googleplay.txt
@@ -1,8 +1,8 @@
-++--- androidx.databinding:viewbinding:4.1.2
+++--- androidx.databinding:viewbinding:4.2.0-beta05
+| \--- androidx.annotation:annotation:1.0.0 -> 1.1.0
-++--- androidx.databinding:databinding-common:4.1.2
-++--- androidx.databinding:databinding-runtime:4.1.2
-+| +--- androidx.databinding:viewbinding:4.1.2 (*)
+++--- androidx.databinding:databinding-common:4.2.0-beta05
+++--- androidx.databinding:databinding-runtime:4.2.0-beta05
++| +--- androidx.databinding:viewbinding:4.2.0-beta05 (*)
+| +--- androidx.lifecycle:lifecycle-runtime:2.0.0 -> 2.3.0
+| | +--- androidx.arch.core:core-runtime:2.1.0
+| | | +--- androidx.annotation:annotation:1.1.0
@@ -14,10 +14,10 @@
+| | \--- androidx.annotation:annotation:1.1.0
+| +--- androidx.collection:collection:1.0.0 -> 1.1.0
+| | \--- androidx.annotation:annotation:1.1.0
-+| \--- androidx.databinding:databinding-common:4.1.2
-++--- androidx.databinding:databinding-adapters:4.1.2
-+| +--- androidx.databinding:databinding-common:4.1.2
-+| \--- androidx.databinding:databinding-runtime:4.1.2 (*)
++| \--- androidx.databinding:databinding-common:4.2.0-beta05
+++--- androidx.databinding:databinding-adapters:4.2.0-beta05
++| +--- androidx.databinding:databinding-common:4.2.0-beta05
++| \--- androidx.databinding:databinding-runtime:4.2.0-beta05 (*)
++--- com.google.firebase:firebase-crashlytics:17.3.1
+| +--- com.google.android.datatransport:transport-api:2.2.1
+| | \--- androidx.annotation:annotation:1.1.0
@@ -213,9 +213,9 @@
+| +--- androidx.annotation:annotation:1.1.0
+| \--- androidx.core:core:1.3.2 (*)
++--- com.gitlab.bitfireAT:cert4android:26a91a729f
-+| +--- androidx.databinding:databinding-common:4.1.1 -> 4.1.2
-+| +--- androidx.databinding:databinding-runtime:4.1.1 -> 4.1.2 (*)
-+| +--- androidx.databinding:databinding-adapters:4.1.1 -> 4.1.2 (*)
++| +--- androidx.databinding:databinding-common:4.1.1 -> 4.2.0-beta05
++| +--- androidx.databinding:databinding-runtime:4.1.1 -> 4.2.0-beta05 (*)
++| +--- androidx.databinding:databinding-adapters:4.1.1 -> 4.2.0-beta05 (*)
+| +--- org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.4.21 (*)
+| +--- androidx.appcompat:appcompat:1.2.0
+| | +--- androidx.annotation:annotation:1.1.0
diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar
index f3d88b1c2..e708b1c02 100644
Binary files a/gradle/wrapper/gradle-wrapper.jar and b/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 6593c46b6..1f3fdbc52 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,5 @@
-#Mon Oct 12 14:08:41 CDT 2020
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-bin.zip
diff --git a/gradlew b/gradlew
index 2fe81a7d9..4f906e0c8 100755
--- a/gradlew
+++ b/gradlew
@@ -82,6 +82,7 @@ esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
@@ -129,6 +130,7 @@ fi
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
+
JAVACMD=`cygpath --unix "$JAVACMD"`
# We build the pattern for arguments to be converted via cygpath
diff --git a/gradlew.bat b/gradlew.bat
index 24467a141..ac1b06f93 100644
--- a/gradlew.bat
+++ b/gradlew.bat
@@ -29,6 +29,9 @@ if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
+
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
@@ -37,7 +40,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
-if "%ERRORLEVEL%" == "0" goto init
+if "%ERRORLEVEL%" == "0" goto execute
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
@@ -51,7 +54,7 @@ goto fail
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
-if exist "%JAVA_EXE%" goto init
+if exist "%JAVA_EXE%" goto execute
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
@@ -61,28 +64,14 @@ echo location of your Java installation.
goto fail
-:init
-@rem Get command-line arguments, handling Windows variants
-
-if not "%OS%" == "Windows_NT" goto win9xME_args
-
-:win9xME_args
-@rem Slurp the command line arguments.
-set CMD_LINE_ARGS=
-set _SKIP=2
-
-:win9xME_args_slurp
-if "x%~1" == "x" goto execute
-
-set CMD_LINE_ARGS=%*
-
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
@rem Execute Gradle
-"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
:end
@rem End local scope for the variables with windows NT shell