diff --git a/.travis.yml b/.travis.yml index a89e18111a..84f5a352ca 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ android: components: - tools - platform-tools - - build-tools-28.0.3 + - build-tools-29.0.2 - android-28 - android-22 # required for emulator below - extra-android-m2repository diff --git a/app/build.gradle b/app/build.gradle index 769f728c07..2e9a5f3ad2 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -125,9 +125,11 @@ dependencies { implementation deps.kotlin.stdlib implementation "androidx.appcompat:appcompat:${androidxAppcompatVersion}" implementation "androidx.media:media:${androidxMediaVersion}" + implementation "androidx.localbroadcastmanager:localbroadcastmanager:${androidxLocalBroadcastVersion}" implementation "androidx.preference:preference:${androidxPreferencesVersion}" implementation "androidx.recyclerview:recyclerview:${androidxRecyclerViewVersion}" implementation "com.google.android.material:material:${materialComponentsVersion}" + implementation "androidx.swiperefreshlayout:swiperefreshlayout:${androidxSwipeRefreshVersion}" implementation "androidx.multidex:multidex:2.0.1" // rx diff --git a/build.gradle b/build.gradle index 02fb891155..8c840d4658 100644 --- a/build.gradle +++ b/build.gradle @@ -1,17 +1,19 @@ buildscript { ext { - kotlinVersion = '1.3.61' - daggerVersion = '2.26' + kotlinVersion = '1.3.70' + daggerVersion = '2.27' androidxMediaVersion = '1.1.0' androidxAnnotationVersion = '1.1.0' androidxPreferencesVersion = '1.1.0' androidxAppcompatVersion = '1.1.0' + androidxLocalBroadcastVersion = '1.0.0' + androidxSwipeRefreshVersion = '1.0.0' androidxRecyclerViewVersion = '1.1.0' - materialComponentsVersion = '1.0.0' + materialComponentsVersion = '1.1.0' espressoVersion = '3.2.0' // note - 3.13.x and above require minSdk 21 okhttpVersion = '3.12.9' - workManagerVersion = '2.3.2' + workManagerVersion = '2.3.3' deps = [ android: [ @@ -39,7 +41,7 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:3.6.0' + classpath 'com.android.tools.build:gradle:4.0.0-beta02' classpath "io.fabric.tools:gradle:1.31.2" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion" classpath "net.ltgt.gradle:gradle-errorprone-plugin:1.1.1" diff --git a/gradle.properties b/gradle.properties index 388e19f8a7..dbb7bf70d1 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1,2 @@ android.enableJetifier=true android.useAndroidX=true -android.enableSeparateAnnotationProcessing=true diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 4a6ebceacd..84a906615c 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.2.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.2.2-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradlew.bat b/gradlew.bat index 24467a141f..9109989e3c 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" diff --git a/utils/material.sh b/utils/material.sh deleted file mode 100644 index 841fe85f94..0000000000 --- a/utils/material.sh +++ /dev/null @@ -1,55 +0,0 @@ -#! /bin/bash - -# a shell script to make it easier to download images from google's -# material design icons project. -# -# usage: -# sh ~/material.sh -f ic_pause.png https://github.com/google/material-design-icons/blob/master/av/drawable-xxhdpi/ic_pause_white_24dp.png -# by default, it outputs to app/src/main/res/drawable-* in the current -# directory, but you can override with -o. -# -# note that the url can be the raw url or can be the web url, and that -# the density bucket doesn't matter (as long as it's drawable-something, -# the script should do the right thing). - -outdir=app/src/main/res/ - -while getopts ":f:o:h:" opt; do - case $opt in - f) - filename=$OPTARG - ;; - o) - outdir=$OPTARG - ;; - h) - help=true - ;; - esac -done -shift $((OPTIND-1)) - -if [ "$help" = true ] || [ $# -lt 1 ]; -then - echo "usage: $0 [options] url" - echo " -f foo.png rename file to foo.png instead of remote name" - echo " -o /path use custom path instead of app/src/main/res/" - exit -fi - - -url=${@/github.com/raw.githubusercontent.com} -url=${url/blob\/} -baseurl="${url%%/drawable*}" -srcname="${url##*/}" - -if [ -z "${filename}" ]; then - filename=$srcname -fi - -echo $url -for arg in mdpi hdpi xhdpi xxhdpi xxxhdpi -do - desturl=$baseurl/drawable-$arg/$srcname - curl $desturl -o $outdir/drawable-$arg/$filename -done diff --git a/utils/tanzilToSqlite.php b/utils/tanzilToSqlite.php deleted file mode 100644 index 514112df27..0000000000 --- a/utils/tanzilToSqlite.php +++ /dev/null @@ -1,56 +0,0 @@ -exec($q); -$q = 'insert into properties(property, value) values' . - "('schema_version', '$schema_version')"; -$sqlite->exec($q); -$q = 'insert into properties(property, value) values' . - "('text_version', '$version')"; -$sqlite->exec($q); - -// verses table -$q = 'create virtual table verses using fts3( sura integer, ayah integer, ' . - 'text text, primary key(sura, ayah ) );'; -$sqlite->exec($q); - -// get the verses -$q = "select sura, aya, text from $tbl"; -$res = mysql_query($q) or die('could not query: ' . mysql_error()); -while ($row = mysql_fetch_assoc($res)){ - $sura = $row['sura']; - $ayah = $row['aya']; - $text = $sqlite->escapeString($row['text']); - $q = "insert into verses(sura, ayah, text) values($sura, $ayah, '$text')"; - $sqlite->exec($q); -} - -// close stuff -$sqlite->close(); -mysql_close(); diff --git a/utils/writeTimingDatabase.php b/utils/writeTimingDatabase.php deleted file mode 100644 index 67566e35c5..0000000000 --- a/utils/writeTimingDatabase.php +++ /dev/null @@ -1,40 +0,0 @@ -exec($q); - -for ($i=1; $i<=114; $i++){ - $file = ''; - if ($i < 10){ $file = "00$i.txt"; } - else if ($i < 100){ $file = "0$i.txt"; } - else { $file = "$i.txt"; } - - $ayah = 1; - $lines = file($file); - $total = count($lines); - foreach ($lines as $l){ - if ($ayah > $ayahs[$i-1]){ $ayah = 999; } - $l = rtrim($l); - $q = "insert into timings values($i, $ayah, $l);"; - - $sqlite->exec($q); - $ayah++; - } -}