diff --git a/app/build.gradle b/app/build.gradle
index 3296bf7..2f43d52 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -1,188 +1,193 @@
plugins {
id 'com.google.protobuf'
- id 'kotlin-kapt'
- id 'kotlin-android'
+ id 'org.jetbrains.kotlin.android'
id 'com.android.application'
+ id 'com.google.devtools.ksp'
}
android {
- compileSdk 35
+ compileSdk 36
namespace "it.reyboz.bustorino"
defaultConfig {
applicationId "it.reyboz.bustorino"
minSdkVersion 24
- targetSdkVersion 35
- buildToolsVersion = '35.0.1'
+ //noinspection EditedTargetSdkVersion
+ targetSdkVersion 36
+ buildToolsVersion = '36.0.0'
versionCode 66
versionName "2.4.3"
vectorDrawables.useSupportLibrary = true
multiDexEnabled true
javaCompileOptions {
annotationProcessorOptions {
arguments = ["room.schemaLocation": "$projectDir/assets/schemas/".toString()]
}
}
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
testOptions {
unitTests.returnDefaultValues = true
}
sourceSets {
androidTest.assets.srcDirs += files("$projectDir/assets/schemas/".toString())
}
buildTypes {
debug {
applicationIdSuffix ".debug"
versionNameSuffix "-dev"
}
gitpull{
applicationIdSuffix ".gitdev"
versionNameSuffix "-gitdev"
}
}
repositories {
mavenCentral()
mavenLocal()
}
dependencies {
//new libraries
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
kotlin {
jvmToolchain 17
}
lint {
abortOnError false
}
androidResources {
generateLocaleConfig true
}
buildFeatures{
buildConfig = true
}
splits{
abi{
enable true
reset()
// Specifies a list of ABIs for Gradle to create APKs for.
include "x86", "x86_64","armeabi-v7a", "arm64-v8a"
universalApk true
}
}
packagingOptions { resources.excludes.add("META-INF/*") }
}
protobuf {
protoc {
artifact = 'com.google.protobuf:protoc:3.22.3'
}
generateProtoTasks {
all().each { task ->
task.builtins {
java {
option 'lite'
}
}
}
}
}
+ksp {
+ arg("room.schemaLocation", "$projectDir/assets/schemas")
+}
+
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
api "org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines_version"
api "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines_version"
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
// Guava implementation for DBUpdateWorker
- implementation 'com.google.guava:guava:32.0.1-android'
+ implementation 'com.google.guava:guava:33.5.0-android'
implementation "androidx.fragment:fragment-ktx:$fragment_version"
- implementation "androidx.activity:activity:$activity_version"
+ implementation "androidx.activity:activity-ktx:$activity_version"
implementation "androidx.annotation:annotation:1.9.1"
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
implementation "androidx.appcompat:appcompat:$appcompat_version"
implementation "androidx.appcompat:appcompat-resources:$appcompat_version"
- implementation "androidx.preference:preference:$preference_version"
+ implementation "androidx.preference:preference-ktx:$preference_version"
implementation "androidx.work:work-runtime:$work_version"
implementation "androidx.work:work-runtime-ktx:$work_version"
- implementation "com.google.android.material:material:1.12.0"
+ implementation "com.google.android.material:material:1.13.0"
implementation 'androidx.constraintlayout:constraintlayout:2.2.1'
implementation "androidx.coordinatorlayout:coordinatorlayout:1.3.0"
- implementation 'org.jsoup:jsoup:1.15.3'
+ implementation 'org.jsoup:jsoup:1.21.2'
implementation 'com.readystatesoftware.sqliteasset:sqliteassethelper:2.0.1'
implementation 'com.android.volley:volley:1.2.1'
//maplibre
- implementation 'org.maplibre.gl:android-sdk:11.8.6'
+ implementation 'org.maplibre.gl:android-sdk:12.0.1'
implementation 'org.maplibre.gl:android-sdk-turf:6.0.1'
implementation 'org.maplibre.gl:android-plugin-annotation-v9:3.0.2'
// remember to enable maven repo jitpack.io when wanting to use osmbonuspack
//implementation 'com.github.MKergall:osmbonuspack:6.9.0'
// ACRA
implementation "ch.acra:acra-mail:$acra_version"
implementation "ch.acra:acra-dialog:$acra_version"
// google transit realtime
- implementation 'com.google.protobuf:protoc:3.22.3'
+ implementation 'com.google.protobuf:protoc:4.33.0'
- implementation 'com.google.protobuf:protobuf-javalite:3.22.3'
+ implementation 'com.google.protobuf:protobuf-javalite:4.33.0'
// mqtt library
//implementation 'org.eclipse.paho:org.eclipse.paho.client.mqttv3:1.2.5'
//implementation 'com.github.hannesa2:paho.mqtt.android:4.4'
implementation("com.hivemq:hivemq-mqtt-client:1.3.10")
implementation(platform("com.hivemq:hivemq-mqtt-client-websocket:1.3.10"))
// ViewModel
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
// LiveData
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version"
// Lifecycles only (without ViewModel or LiveData)
implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycle_version"
// Legacy
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
// Room components
implementation "androidx.room:room-runtime:$room_version"
implementation "androidx.room:room-ktx:$room_version"
- kapt "androidx.room:room-compiler:$room_version"
+ ksp "androidx.room:room-compiler:$room_version"
//multidex - we need this to build the app
implementation "androidx.multidex:multidex:$multidex_version"
implementation 'de.siegmar:fastcsv:2.2.2'
- testImplementation 'junit:junit:4.12'
- implementation 'junit:junit:4.12'
+ testImplementation 'junit:junit:4.13.2'
+ implementation 'junit:junit:4.13.2'
- implementation "androidx.test.ext:junit:1.1.5"
+ implementation "androidx.test.ext:junit:1.3.0"
implementation "androidx.test:core:$androidXTestVersion"
implementation "androidx.test:runner:$androidXTestVersion"
implementation "androidx.room:room-testing:$room_version"
- androidTestImplementation "androidx.test.ext:junit:1.1.5"
+ androidTestImplementation "androidx.test.ext:junit:1.3.0"
androidTestImplementation "androidx.test:core:$androidXTestVersion"
androidTestImplementation "androidx.test:runner:$androidXTestVersion"
androidTestImplementation "androidx.test:rules:$androidXTestVersion"
androidTestImplementation "androidx.room:room-testing:$room_version"
}
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 693c30f..34f967c 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -1,146 +1,148 @@
+ android:exported="false"
+ android:theme="@style/AppTheme.NoActionBar.Light"
+ />
\ No newline at end of file
diff --git a/app/src/main/java/it/reyboz/bustorino/ActivityAbout.kt b/app/src/main/java/it/reyboz/bustorino/ActivityAbout.kt
index 7c930c5..4fd327c 100644
--- a/app/src/main/java/it/reyboz/bustorino/ActivityAbout.kt
+++ b/app/src/main/java/it/reyboz/bustorino/ActivityAbout.kt
@@ -1,105 +1,137 @@
/*
BusTO - Arrival times for Turin public transports.
Copyright (C) 2014 Valerio Bozzolan
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see .
*/
package it.reyboz.bustorino
import android.content.Intent
import android.net.Uri
import android.os.Bundle
import android.text.method.LinkMovementMethod
import android.util.Log
import android.view.MenuItem
import android.view.View
+import android.view.ViewGroup.MarginLayoutParams
import android.widget.Button
import android.widget.TextView
import androidx.appcompat.app.AppCompatActivity
+import androidx.appcompat.widget.Toolbar
+import androidx.core.view.OnApplyWindowInsetsListener
+import androidx.core.view.ViewCompat
+import androidx.core.view.WindowInsetsCompat
+import androidx.core.view.updatePadding
import it.reyboz.bustorino.backend.utils
import it.reyboz.bustorino.middleware.BarcodeScanUtils
class ActivityAbout : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_about)
//TOP TEXT VIEW
val topTextView = checkNotNull(findViewById(R.id.topTextView))
val telegramTextView= checkNotNull(findViewById(R.id.telegramTextView))
val howTextView = checkNotNull(findViewById(R.id.howDoesItWorkTextView))
val bottomTextView= checkNotNull(findViewById(R.id.bottomAboutTextView))
val textviews = arrayOf(topTextView, telegramTextView,howTextView,bottomTextView)
val stringsForTextViews = arrayOf(R.string.about_history_top, R.string.about_channel, R.string.about_how, R.string.about_history_bottom)
for (i in 0 until 4) {
val htmlText = utils.convertHtml(
resources.getString(
stringsForTextViews[i]
)
)
//val aboutTextView = checkNotNull(findViewById(R.id.aboutTextView))
val textView = textviews[i]
textView.text = htmlText
textView.movementMethod = LinkMovementMethod.getInstance()
}
/*Toolbar mToolbar = findViewById(R.id.default_toolbar);
setSupportActionBar(mToolbar);
*/
+ val mToolbar = findViewById(R.id.default_toolbar)
+ setSupportActionBar(mToolbar)
+
if (supportActionBar != null) supportActionBar!!.setDisplayHomeAsUpEnabled(true)
- val versionText = findViewById(R.id.versionTextView)
- Log.d("BusTO About", "The version text view is: $versionText")
- versionText.text = resources.getText(R.string.app_version).toString() + ": " + BuildConfig.VERSION_NAME
+ val versionTextView = findViewById(R.id.versionTextView)
+ Log.d("BusTO About", "The version text view is: $versionTextView")
+ versionTextView.text = resources.getText(R.string.app_version).toString() + ": " + BuildConfig.VERSION_NAME
val openTelegramButton = findViewById