Renommage du projet MiniApp → MaPosition
- applicationId et namespace : com.example.miniapp → com.example.maposition - Nom affiché, thème, rootProject.name et SharedPreferences alignés - Packages Kotlin déplacés (main, test, androidTest) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
7cc782ae1a
commit
29bbae5823
10 changed files with 15 additions and 15 deletions
|
|
@ -4,13 +4,13 @@ plugins {
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
namespace = "com.example.miniapp"
|
namespace = "com.example.maposition"
|
||||||
compileSdk {
|
compileSdk {
|
||||||
version = release(36)
|
version = release(36)
|
||||||
}
|
}
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId = "com.example.miniapp"
|
applicationId = "com.example.maposition"
|
||||||
minSdk = 21
|
minSdk = 21
|
||||||
targetSdk = 36
|
targetSdk = 36
|
||||||
versionCode = 1
|
versionCode = 1
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
package com.example.miniapp
|
package com.example.maposition
|
||||||
|
|
||||||
import androidx.test.platform.app.InstrumentationRegistry
|
import androidx.test.platform.app.InstrumentationRegistry
|
||||||
import androidx.test.ext.junit.runners.AndroidJUnit4
|
import androidx.test.ext.junit.runners.AndroidJUnit4
|
||||||
|
|
@ -19,6 +19,6 @@ class ExampleInstrumentedTest {
|
||||||
fun useAppContext() {
|
fun useAppContext() {
|
||||||
// Context of the app under test.
|
// Context of the app under test.
|
||||||
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
|
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
|
||||||
assertEquals("com.example.miniapp", appContext.packageName)
|
assertEquals("com.example.maposition", appContext.packageName)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
package="com.example.miniapp">
|
package="com.example.maposition">
|
||||||
|
|
||||||
<uses-permission android:name="android.permission.SEND_SMS"/>
|
<uses-permission android:name="android.permission.SEND_SMS"/>
|
||||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
|
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
package com.example.miniapp
|
package com.example.maposition
|
||||||
|
|
||||||
import android.Manifest
|
import android.Manifest
|
||||||
import android.content.pm.PackageManager
|
import android.content.pm.PackageManager
|
||||||
|
|
@ -47,7 +47,7 @@ class MainActivity : AppCompatActivity() {
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun getSavedSettings(): Pair<String, List<String>> {
|
private fun getSavedSettings(): Pair<String, List<String>> {
|
||||||
val prefs = getSharedPreferences("MiniAppPrefs", MODE_PRIVATE)
|
val prefs = getSharedPreferences("MaPositionPrefs", MODE_PRIVATE)
|
||||||
val name = prefs.getString("name", "") ?: ""
|
val name = prefs.getString("name", "") ?: ""
|
||||||
val phones = prefs.getString("phones", "") ?: ""
|
val phones = prefs.getString("phones", "") ?: ""
|
||||||
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
package com.example.miniapp
|
package com.example.maposition
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
|
@ -13,7 +13,7 @@ class SettingsActivity : AppCompatActivity() {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
setContentView(R.layout.activity_settings)
|
setContentView(R.layout.activity_settings)
|
||||||
|
|
||||||
val prefs = getSharedPreferences("MiniAppPrefs", Context.MODE_PRIVATE)
|
val prefs = getSharedPreferences("MaPositionPrefs", Context.MODE_PRIVATE)
|
||||||
|
|
||||||
val nameInput = findViewById<EditText>(R.id.nameInput)
|
val nameInput = findViewById<EditText>(R.id.nameInput)
|
||||||
val phonesInput = findViewById<EditText>(R.id.phonesInput)
|
val phonesInput = findViewById<EditText>(R.id.phonesInput)
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||||
<!-- Base application theme. -->
|
<!-- Base application theme. -->
|
||||||
<style name="Base.Theme.MiniApp" parent="Theme.Material3.DayNight.NoActionBar">
|
<style name="Base.Theme.MaPosition" parent="Theme.Material3.DayNight.NoActionBar">
|
||||||
<!-- Customize your dark theme here. -->
|
<!-- Customize your dark theme here. -->
|
||||||
<!-- <item name="colorPrimary">@color/my_dark_primary</item> -->
|
<!-- <item name="colorPrimary">@color/my_dark_primary</item> -->
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,3 @@
|
||||||
<resources>
|
<resources>
|
||||||
<string name="app_name">MiniApp</string>
|
<string name="app_name">MaPosition</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||||
<!-- Base application theme. -->
|
<!-- Base application theme. -->
|
||||||
<style name="Base.Theme.MiniApp" parent="Theme.Material3.DayNight.NoActionBar">
|
<style name="Base.Theme.MaPosition" parent="Theme.Material3.DayNight.NoActionBar">
|
||||||
<!-- Customize your light theme here. -->
|
<!-- Customize your light theme here. -->
|
||||||
<!-- <item name="colorPrimary">@color/my_light_primary</item> -->
|
<!-- <item name="colorPrimary">@color/my_light_primary</item> -->
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="Theme.MiniApp" parent="Base.Theme.MiniApp" />
|
<style name="Theme.MaPosition" parent="Base.Theme.MaPosition" />
|
||||||
</resources>
|
</resources>
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
package com.example.miniapp
|
package com.example.maposition
|
||||||
|
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
|
|
||||||
|
|
@ -19,5 +19,5 @@ dependencyResolutionManagement {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
rootProject.name = "MiniApp"
|
rootProject.name = "MaPosition"
|
||||||
include(":app")
|
include(":app")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue