File tree Expand file tree Collapse file tree
app/src/main/java/com/example/reply/ui/theme Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1616
1717package com.example.reply.ui.theme
1818
19+ import android.app.Activity
1920import android.os.Build
2021import androidx.compose.foundation.isSystemInDarkTheme
2122import androidx.compose.material3.MaterialTheme
@@ -24,7 +25,10 @@ import androidx.compose.material3.dynamicDarkColorScheme
2425import androidx.compose.material3.dynamicLightColorScheme
2526import androidx.compose.material3.lightColorScheme
2627import androidx.compose.runtime.Composable
28+ import androidx.compose.runtime.SideEffect
2729import androidx.compose.ui.platform.LocalContext
30+ import androidx.compose.ui.platform.LocalView
31+ import androidx.core.view.WindowCompat
2832
2933private val LightColorScheme = lightColorScheme(
3034 primary = md_theme_light_primary,
@@ -110,6 +114,14 @@ fun ReplyTheme(
110114 else -> LightColorScheme
111115 }
112116
117+ val view = LocalView .current
118+ if (! view.isInEditMode) {
119+ SideEffect {
120+ val window = (view.context as Activity ).window
121+ WindowCompat .getInsetsController(window, view).isAppearanceLightStatusBars = ! darkTheme
122+ }
123+ }
124+
113125 MaterialTheme (
114126 colorScheme = colorScheme,
115127 typography = Typography ,
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ buildscript {
2222}
2323
2424plugins {
25- id(" com.android.application" ) version " 8.1.4 " apply false
26- id(" com.android.library" ) version " 8.1.4 " apply false
25+ id(" com.android.application" ) version " 8.3.1 " apply false
26+ id(" com.android.library" ) version " 8.3.1 " apply false
2727 id(" org.jetbrains.kotlin.android" ) version " 1.9.20" apply false
2828}
Original file line number Diff line number Diff line change 11# Mon Mar 13 13:23:28 PDT 2023
22distributionBase =GRADLE_USER_HOME
33distributionPath =wrapper/dists
4- distributionUrl =https\://services.gradle.org/distributions/gradle-8.2 -bin.zip
4+ distributionUrl =https\://services.gradle.org/distributions/gradle-8.4 -bin.zip
55zipStoreBase =GRADLE_USER_HOME
66zipStorePath =wrapper/dists
You can’t perform that action at this time.
0 commit comments