Skip to content

Commit

Permalink
Merge pull request #23 from MateusRodCosta/dev
Browse files Browse the repository at this point in the history
Version 1.2.2
  • Loading branch information
MateusRodCosta authored May 9, 2024
2 parents 8d89b68 + 6c1ab7f commit ad938f4
Show file tree
Hide file tree
Showing 15 changed files with 50 additions and 34 deletions.
2 changes: 1 addition & 1 deletion .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ Or download the latest APK from the [Releases Section](https://github.com/Mateus

## Screenshots

<img src="https://raw.githubusercontent.com/MateusRodCosta/Share2Storage/main/fastlane/metadata/android/en-US/images/phoneScreenshots/1.png" width="270">
<img src="https://raw.githubusercontent.com/MateusRodCosta/Share2Storage/main/fastlane/metadata/android/en-US/images/phoneScreenshots/3.png" width="270">
<img src="https://raw.githubusercontent.com/MateusRodCosta/Share2Storage/main/fastlane/metadata/android/en-US/images/phoneScreenshots/1.png" width="270" alt="Main Screen">
<img src="https://raw.githubusercontent.com/MateusRodCosta/Share2Storage/main/fastlane/metadata/android/en-US/images/phoneScreenshots/3.png" width="270" alt="Details Screen">

## License

Expand Down
5 changes: 3 additions & 2 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ android {
applicationId = "com.mateusrodcosta.apps.share2storage"
minSdk = 26
targetSdk = 34
versionCode = 18
versionName = "1.2.1"
versionCode = 19
versionName = "1.2.2"

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}
Expand Down Expand Up @@ -83,6 +83,7 @@ android {

dependencies {
implementation(libs.bundles.androidx.ktx)
implementation(libs.androidx.core.splashscreen)

val composeBom = platform(libs.compose.bom)
implementation(composeBom)
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:theme="@android:style/Theme.Material.NoActionBar"
android:theme="@style/Theme.App"
android:enableOnBackInvokedCallback="true">

<activity
android:name=".MainActivity"
android:theme="@style/Theme.App.Starting"
android:exported="true">

<intent-filter>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ import android.util.Log
import android.widget.Toast
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.activity.enableEdgeToEdge
import androidx.activity.result.ActivityResultLauncher
import androidx.compose.material3.windowsizeclass.ExperimentalMaterial3WindowSizeClassApi
import androidx.compose.material3.windowsizeclass.calculateWindowSizeClass
import androidx.core.view.WindowCompat
import androidx.preference.PreferenceManager
import com.mateusrodcosta.apps.share2storage.model.UriData
import com.mateusrodcosta.apps.share2storage.screens.DetailsScreen
Expand All @@ -47,8 +47,10 @@ class DetailsActivity : ComponentActivity() {

@OptIn(ExperimentalMaterial3WindowSizeClassApi::class)
override fun onCreate(savedInstanceState: Bundle?) {
enableEdgeToEdge()
super.onCreate(savedInstanceState)
WindowCompat.setDecorFitsSystemWindows(window, false)
val windowInsetsController = WindowCompat.getInsetsController(window, window.decorView)
windowInsetsController.isAppearanceLightNavigationBars = true

getPreferences()
handleIntent(intent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ import android.os.Bundle
import android.util.Log
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.activity.enableEdgeToEdge
import androidx.activity.result.contract.ActivityResultContracts
import androidx.compose.material3.windowsizeclass.ExperimentalMaterial3WindowSizeClassApi
import androidx.compose.material3.windowsizeclass.calculateWindowSizeClass
import androidx.core.splashscreen.SplashScreen.Companion.installSplashScreen
import androidx.core.view.WindowCompat
import com.mateusrodcosta.apps.share2storage.screens.AppNavigation
import com.mateusrodcosta.apps.share2storage.screens.SettingsViewModel

Expand All @@ -44,8 +45,11 @@ class MainActivity : ComponentActivity() {

@OptIn(ExperimentalMaterial3WindowSizeClassApi::class)
override fun onCreate(savedInstanceState: Bundle?) {
enableEdgeToEdge()
installSplashScreen()
super.onCreate(savedInstanceState)
WindowCompat.setDecorFitsSystemWindows(window, false)
val windowInsetsController = WindowCompat.getInsetsController(window, window.decorView)
windowInsetsController.isAppearanceLightNavigationBars = true

settingsViewModel.initializeWithContext(applicationContext)
settingsViewModel.assignSaveLocationDirIntent(getSaveLocationDirIntent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ fun AboutRowWithURL(
}

@Composable
fun GenericRow(onClick: () -> Unit = {}, content: @Composable() (RowScope.() -> Unit)) {
fun GenericRow(onClick: () -> Unit = {}, content: @Composable (RowScope.() -> Unit)) {
Box(modifier = Modifier
.fillMaxWidth()
.clickable { onClick() }) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ import androidx.compose.foundation.layout.PaddingValues
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.heightIn
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.width
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,7 @@ private val DarkColors = darkColorScheme(

@Composable
fun AppTheme(
useDarkTheme: Boolean = isSystemInDarkTheme(),
content: @Composable() () -> Unit
useDarkTheme: Boolean = isSystemInDarkTheme(), content: @Composable () -> Unit
) {
val colors = if (!useDarkTheme) {
LightColors
Expand All @@ -101,7 +100,6 @@ fun AppTheme(
}

MaterialTheme(
colorScheme = colors,
content = content
colorScheme = colors, content = content
)
}
12 changes: 0 additions & 12 deletions app/src/main/res/drawable/launch_background.xml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#FFFFFF</color>
<color name="splash_screen_background">#000000</color>
</resources>
14 changes: 14 additions & 0 deletions app/src/main/res/values/themes.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Theme.App" parent="@android:style/Theme.Material.Light.NoActionBar">
<item name="android:navigationBarColor">@android:color/transparent</item>
<item name="android:statusBarColor">@android:color/transparent</item>
<item name="android:windowLightStatusBar">false</item>
</style>
<style name="Theme.App.Starting" parent="Theme.SplashScreen.IconBackground">
<item name="windowSplashScreenBackground">@color/splash_screen_background</item>
<item name="windowSplashScreenAnimatedIcon">@drawable/ic_launcher_foreground</item>
<item name="windowSplashScreenIconBackgroundColor">@color/ic_launcher_background</item>
<item name="postSplashScreenTheme">@style/Theme.App</item>
</style>
</resources>
3 changes: 3 additions & 0 deletions fastlane/metadata/android/en-US/changelogs/19.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
• Updated dependencies
• Support splash screen for pre-Android 12
• Status bar icons should now be white
3 changes: 3 additions & 0 deletions fastlane/metadata/android/pt-BR/changelogs/19.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
• Dependências atualizadas
• Adicionado suporte a tela de abertura para versões do Android pre-12
• Os ícones da barra de status agora são brancos
14 changes: 8 additions & 6 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
[versions]
agp = "8.3.1"
kotlin = "1.9.22"
androidxComposeCompiler = "1.5.10"
ktx = "1.12.0"
agp = "8.4.0"
kotlin = "1.9.23"
androidxComposeCompiler = "1.5.13"
ktx = "1.13.1"
preference-ktx = "1.2.1"
composeBom = "2024.03.00"
activityCompose = "1.8.2"
splashscreen = "1.0.1"
composeBom = "2024.05.00"
activityCompose = "1.9.0"
navigationCompose = "2.7.7"
junit = "4.13.2"
androidxTestRunner = "1.5.2"
Expand All @@ -14,6 +15,7 @@ androidxTestRules = "1.5.0"
[libraries]
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "ktx" }
androidx-preference-ktx = { group = "androidx.preference", name = "preference-ktx", version.ref = "preference-ktx" }
androidx-core-splashscreen = { group = "androidx.core", name = "core-splashscreen", version.ref = "splashscreen" }
compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" }
compose-material3 = { group = "androidx.compose.material3", name = "material3" }
compose-material3-window-size-classes = { group = "androidx.compose.material3", name = "material3-window-size-class" }
Expand Down

0 comments on commit ad938f4

Please sign in to comment.