Skip to content

Commit d852f8f

Browse files
committed
Athena: Rewrite
Change-Id: Ifdffd0690a1895ce6ce40c2139643b854ab36e41
1 parent e8be24f commit d852f8f

File tree

470 files changed

+13768
-34562
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

470 files changed

+13768
-34562
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ If you find a bug, [open an issue](https://github.com/SebaUbuntu/Athena/issues)
3131

3232
```
3333
#
34-
# SPDX-FileCopyrightText: 2023 Sebastiano Barezzi
34+
# SPDX-FileCopyrightText: Sebastiano Barezzi
3535
# SPDX-License-Identifier: Apache-2.0
3636
#
3737
```

app/build.gradle.kts

Lines changed: 43 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2025 Sebastiano Barezzi
2+
* SPDX-FileCopyrightText: Sebastiano Barezzi
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

@@ -8,6 +8,7 @@ import org.jetbrains.kotlin.gradle.dsl.JvmTarget
88
plugins {
99
alias(libs.plugins.android.application)
1010
alias(libs.plugins.kotlin.android)
11+
alias(libs.plugins.kotlin.compose)
1112
alias(libs.plugins.kotlin.serialization)
1213
}
1314

@@ -64,6 +65,10 @@ android {
6465
}
6566
}
6667

68+
buildFeatures {
69+
compose = true
70+
}
71+
6772
externalNativeBuild {
6873
cmake {
6974
path = file("src/main/cpp/CMakeLists.txt")
@@ -73,14 +78,47 @@ android {
7378
}
7479

7580
dependencies {
76-
implementation(libs.androidx.appcompat)
81+
implementation(project(":core"))
82+
implementation(project(":module-audio"))
83+
implementation(project(":module-biometrics"))
84+
implementation(project(":module-bluetooth"))
85+
implementation(project(":module-build"))
86+
implementation(project(":module-camera"))
87+
implementation(project(":module-cpu"))
88+
implementation(project(":module-device"))
89+
implementation(project(":module-display"))
90+
implementation(project(":module-drm"))
91+
implementation(project(":module-gnss"))
92+
implementation(project(":module-gpu"))
93+
implementation(project(":module-health"))
94+
implementation(project(":module-input"))
95+
implementation(project(":module-media"))
96+
implementation(project(":module-nfc"))
97+
implementation(project(":module-ril"))
98+
implementation(project(":module-security"))
99+
implementation(project(":module-sensors"))
100+
implementation(project(":module-services"))
101+
implementation(project(":module-storage"))
102+
implementation(project(":module-systemproperties"))
103+
implementation(project(":module-thermal"))
104+
implementation(project(":module-treble"))
105+
implementation(project(":module-user"))
106+
implementation(project(":module-uwb"))
107+
implementation(project(":module-wifi"))
108+
109+
implementation(libs.androidx.activity.compose)
77110
implementation(libs.androidx.biometric)
78-
implementation(libs.androidx.constraintlayout)
111+
implementation(libs.androidx.compose.material3)
112+
//implementation(libs.androidx.compose.material3.adaptive.navigation3)
113+
debugImplementation(libs.androidx.compose.ui.tooling)
114+
implementation(libs.androidx.compose.ui.tooling.preview)
79115
implementation(libs.androidx.core.ktx)
80116
implementation(libs.androidx.core.uwb)
81117
implementation(libs.androidx.lifecycle.livedata.ktx)
82-
implementation(libs.androidx.navigation.fragment.ktx)
83-
implementation(libs.androidx.navigation.ui.ktx)
118+
implementation(libs.androidx.lifecycle.viewmodel.compose)
119+
implementation(libs.androidx.lifecycle.viewmodel.navigation3)
120+
implementation(libs.androidx.navigation3.runtime)
121+
implementation(libs.androidx.navigation3.ui)
84122
implementation(libs.androidx.security.state)
85123
implementation(libs.kotlinx.serialization.json)
86124
implementation(libs.material)

app/proguard-rules.pro

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
1-
# SPDX-FileCopyrightText: 2025 Sebastiano Barezzi
1+
#
2+
# SPDX-FileCopyrightText: Sebastiano Barezzi
23
# SPDX-License-Identifier: Apache-2.0
4+
#
35

46
# Add project specific ProGuard rules here.
57
# You can control the set of applied configuration files using the

app/src/main/AndroidManifest.xml

Lines changed: 5 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,11 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!--
3-
SPDX-FileCopyrightText: 2023-2024 Sebastiano Barezzi
3+
SPDX-FileCopyrightText: Sebastiano Barezzi
44
SPDX-License-Identifier: Apache-2.0
55
-->
66
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
77
xmlns:tools="http://schemas.android.com/tools">
88

9-
<uses-feature
10-
android:name="android.hardware.camera"
11-
android:required="false" />
12-
<uses-feature
13-
android:name="android.hardware.nfc"
14-
android:required="false" />
15-
16-
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
17-
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
18-
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
19-
<uses-permission
20-
android:name="android.permission.BLUETOOTH"
21-
android:maxSdkVersion="30" />
22-
<uses-permission
23-
android:name="android.permission.BLUETOOTH_ADMIN"
24-
android:maxSdkVersion="30" />
25-
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
26-
<uses-permission android:name="android.permission.BODY_SENSORS" />
27-
<uses-permission android:name="android.permission.CAMERA" />
28-
<uses-permission android:name="android.permission.HIGH_SAMPLING_RATE_SENSORS"
29-
tools:ignore="HighSamplingRate" />
30-
<uses-permission android:name="android.permission.INTERNET" />
31-
<uses-permission android:name="android.permission.NFC" />
32-
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
33-
<uses-permission android:name="android.permission.USE_BIOMETRIC" />
34-
<uses-permission
35-
android:name="android.permission.USE_FINGERPRINT"
36-
android:maxSdkVersion="28" />
37-
<uses-permission android:name="android.permission.UWB_RANGING" />
38-
399
<application
4010
android:name=".AthenaApplication"
4111
android:enableOnBackInvokedCallback="true"
@@ -44,14 +14,18 @@
4414
android:supportsRtl="true"
4515
android:theme="@style/Theme.Athena"
4616
tools:targetApi="tiramisu">
17+
4718
<activity
4819
android:name=".MainActivity"
20+
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden|mnc|colorMode|density|fontScale|fontWeightAdjustment|keyboard|layoutDirection|locale|mcc|navigation|smallestScreenSize|touchscreen|uiMode"
4921
android:exported="true">
5022
<intent-filter>
5123
<action android:name="android.intent.action.MAIN" />
5224

5325
<category android:name="android.intent.category.LAUNCHER" />
5426
</intent-filter>
5527
</activity>
28+
5629
</application>
30+
5731
</manifest>
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,26 @@
11
/*
2-
* SPDX-FileCopyrightText: 2023 Sebastiano Barezzi
2+
* SPDX-FileCopyrightText: Sebastiano Barezzi
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

66
package dev.sebaubuntu.athena
77

88
import android.app.Application
99
import com.google.android.material.color.DynamicColors
10+
import dev.sebaubuntu.athena.utils.ModulesManager
1011

1112
class AthenaApplication : Application() {
13+
val modulesManager by lazy { ModulesManager(this) }
14+
1215
override fun onCreate() {
1316
super.onCreate()
1417

1518
DynamicColors.applyToActivitiesIfAvailable(this)
19+
20+
// Load native library
21+
System.loadLibrary("athena")
22+
23+
// Start components manager
24+
modulesManager
1625
}
1726
}

0 commit comments

Comments
 (0)