diff --git a/app/build.gradle b/app/build.gradle index df26abb..88e2bbe 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -5,12 +5,12 @@ plugins { android { namespace 'acidburn.stims' - compileSdk 34 + compileSdk 35 defaultConfig { applicationId "acidburn.stims" minSdk 24 - targetSdk 34 + targetSdk 35 versionCode 2 versionName "1.1" @@ -28,18 +28,18 @@ android { } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_11 + targetCompatibility JavaVersion.VERSION_11 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '11' } buildFeatures { compose true buildConfig true } composeOptions { - kotlinCompilerExtensionVersion '1.5.8' + kotlinCompilerExtensionVersion '1.5.15' } packagingOptions { resources { @@ -49,24 +49,29 @@ android { } dependencies { - implementation 'androidx.core:core-ktx:1.12.0' - implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.7.0' - implementation 'androidx.activity:activity-compose:1.8.2' - implementation platform('androidx.compose:compose-bom:2023.10.01') + implementation 'androidx.core:core-ktx:1.15.0' + implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.8.7' + implementation 'androidx.activity:activity-compose:1.10.1' + implementation platform('androidx.compose:compose-bom:2025.02.00') implementation 'androidx.compose.ui:ui' implementation 'androidx.compose.ui:ui-graphics' implementation 'androidx.compose.ui:ui-tooling-preview' implementation 'androidx.compose.material3:material3' implementation 'androidx.compose.material:material-icons-extended' - // Added for XML theme support - implementation 'com.google.android.material:material:1.11.0' + implementation 'com.google.android.material:material:1.12.0' testImplementation 'junit:junit:4.13.2' - androidTestImplementation 'androidx.test.ext:junit:1.1.5' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1' - androidTestImplementation platform('androidx.compose:compose-bom:2023.10.01') + androidTestImplementation 'androidx.test.ext:junit:1.2.1' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1' + androidTestImplementation platform('androidx.compose:compose-bom:2025.02.00') androidTestImplementation 'androidx.compose.ui:ui-test-junit4' debugImplementation 'androidx.compose.ui:ui-tooling' debugImplementation 'androidx.compose.ui:ui-test-manifest' } + +// Alias for CI/CD systems or scripts that expect the standard Java 'testClasses' task +tasks.register("testClasses") { + // This maps to compiling the debug unit tests + dependsOn "compileDebugUnitTestSources" +} diff --git a/app/src/main/java/acidburn/stims/MainActivity.kt b/app/src/main/java/acidburn/stims/MainActivity.kt index 9794464..040c84d 100644 --- a/app/src/main/java/acidburn/stims/MainActivity.kt +++ b/app/src/main/java/acidburn/stims/MainActivity.kt @@ -24,6 +24,9 @@ import androidx.compose.runtime.getValue import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.setValue import androidx.compose.material.icons.Icons +import androidx.compose.material.icons.automirrored.filled.ArrowBack +import androidx.compose.material.icons.automirrored.filled.ArrowForward +import androidx.compose.material.icons.automirrored.filled.OpenInNew import androidx.compose.material.icons.filled.ArrowBack import androidx.compose.material.icons.filled.ArrowForward import androidx.compose.material.icons.filled.Delete @@ -291,7 +294,7 @@ fun SettingsScreen( title = { Text("Settings") }, navigationIcon = { IconButton(onClick = onBack) { - Icon(Icons.Default.ArrowBack, contentDescription = "Back") + Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = "Back") } } ) @@ -336,15 +339,15 @@ fun SettingsScreen( ) } - Divider() + HorizontalDivider() SettingsSectionHeader("ABOUT") SettingsInfoRow(label = "Version", value = BuildConfig.VERSION_NAME) - Divider(modifier = Modifier.padding(horizontal = 16.dp)) + HorizontalDivider(modifier = Modifier.padding(horizontal = 16.dp)) SettingsInfoRow(label = "Author", value = "acidburnmonkey") - Divider(modifier = Modifier.padding(horizontal = 16.dp)) + HorizontalDivider(modifier = Modifier.padding(horizontal = 16.dp)) Row( modifier = Modifier @@ -363,7 +366,7 @@ fun SettingsScreen( modifier = Modifier.weight(1f) ) Icon( - imageVector = Icons.Default.OpenInNew, + imageVector = Icons.AutoMirrored.Filled.OpenInNew, contentDescription = "Open GitHub", tint = MaterialTheme.colorScheme.onSurfaceVariant, modifier = Modifier.size(18.dp) @@ -510,7 +513,7 @@ fun OverlayWarningBanner(onClick: () -> Unit) { } Spacer(modifier = Modifier.width(6.dp)) Icon( - imageVector = Icons.Default.ArrowForward, + imageVector = Icons.AutoMirrored.Filled.ArrowForward, contentDescription = null, tint = warningColor, modifier = Modifier.size(16.dp) diff --git a/app/src/main/java/acidburn/stims/StimsService.kt b/app/src/main/java/acidburn/stims/StimsService.kt index 7501646..2393e5b 100644 --- a/app/src/main/java/acidburn/stims/StimsService.kt +++ b/app/src/main/java/acidburn/stims/StimsService.kt @@ -103,7 +103,7 @@ class StimsService : Service() { while (events.hasNextEvent()) { events.getNextEvent(event) - if (event.eventType == UsageEvents.Event.MOVE_TO_FOREGROUND) { + if (event.eventType == UsageEvents.Event.ACTIVITY_RESUMED) { lastForegroundPackage = event.packageName } } diff --git a/assets/banner.png b/assets/banner.png new file mode 100644 index 0000000..f726ab2 Binary files /dev/null and b/assets/banner.png differ diff --git a/assets/circular_icon_512.png b/assets/circular_icon_512.png new file mode 100644 index 0000000..f64e779 Binary files /dev/null and b/assets/circular_icon_512.png differ diff --git a/build.gradle b/build.gradle index 48bc87e..a6e22c4 100644 --- a/build.gradle +++ b/build.gradle @@ -5,8 +5,8 @@ buildscript { mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:8.2.2' - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.22" + classpath 'com.android.tools.build:gradle:8.7.3' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.25" } } diff --git a/fdroid/acidburn.stims.yml b/fdroid/acidburn.stims.yml index 7393279..1dafd26 100644 --- a/fdroid/acidburn.stims.yml +++ b/fdroid/acidburn.stims.yml @@ -1,6 +1,9 @@ Categories: - System License: GPL-3.0-only +AuthorName: acidburnmonkey +AuthorEmail: developercontact.gnarly348@slmail.me +WebSite: https://www.gitshop.cc/ SourceCode: https://github.com/acidburnmonkey/stims IssueTracker: https://github.com/acidburnmonkey/stims/issues @@ -12,16 +15,22 @@ Repo: https://github.com/acidburnmonkey/stims Builds: - versionName: '1.0' versionCode: 1 - commit: v1.0 + commit: 1bb04b401623c2217eda0e8e2a1f8a251b607c72 gradle: - yes output: app/build/outputs/apk/release/app-release-unsigned.apk + - versionName: '1.1' versionCode: 2 - commit: v1.1 + commit: 908fc99342ffaa46f84ce1a67868f453e8a61372 + subdir: app + sudo: + - echo "deb https://deb.debian.org/debian trixie main" > /etc/apt/sources.list.d/trixie.list + - apt-get update + - apt-get install -y -t trixie openjdk-26-jdk-headless + - update-alternatives --auto java gradle: - yes - output: app/build/outputs/apk/release/app-release-unsigned.apk AutoUpdateMode: Version UpdateCheckMode: Tags diff --git a/gradle.properties b/gradle.properties index 45eb3e7..3901825 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,5 @@ android.useAndroidX=true android.enableJetifier=true org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8 +org.gradle.java.home=/usr/lib/jvm/java-25-openjdk org.gradle.configuration-cache=true diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 3499ded..ca92fb0 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,8 @@ +#Sat Mar 28 00:18:44 EDT 2026 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip +distributionSha256Sum=31c55713e40233a8303827ceb42ca48a47267a0ad4bab9177123121e71524c26 +distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists