Skip to content

Commit

Permalink
release sora v3.4.0.0 103
Browse files Browse the repository at this point in the history
  • Loading branch information
arvifox committed Oct 11, 2023
1 parent 6362c02 commit ebccd57
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 20 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ play {
serviceAccountCredentials = file(System.env.CI_PLAY_KEY ?: "../key/fake.json")
track = "internal"
releaseStatus = ReleaseStatus.DRAFT
releaseName = "3.3.0.4 - SORA Card"
releaseName = "3.4.0.0 - SORA IBAN Balance"
}

dependencies {
Expand Down
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ buildscript {

ext {
// soralution 113 3.5.0.0 2023.10.10
// sora dae 102 3.3.0.4 2023.09.11
// sora dae 103 3.4.0.0 2023.10.10
// appVersionCode = Integer.valueOf(System.env.BUILD_NUMBER ?: 96)
appVersionCode = Integer.valueOf(System.env.CI_BUILD_ID ?: 102)
appVersionName = '3.3.0.4'
appVersionCode = Integer.valueOf(System.env.CI_BUILD_ID ?: 103)
appVersionName = '3.4.0.0'

compileVersion = 34
minVersion = 24
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,15 @@ class DarkThemeManager @Inject constructor(
*/
true
}

currentAppUiMode == AppCompatDelegate.MODE_NIGHT_NO && !isDarkModeEnabled -> {
/*
Saved state matches system configuration;
no need to change anything
*/
false
}

else -> {
/*
Something went wrong, saved state is different from system config;
Expand All @@ -136,22 +138,23 @@ class DarkThemeManager @Inject constructor(
}.flowOn(coroutineManager.main.immediate).stateIn(
scope = coroutineManager.applicationScope,
started = SharingStarted.Eagerly, // Eager mode is used to apply changes as soon as possible
initialValue = AppCompatDelegate.getDefaultNightMode()
.equals(AppCompatDelegate.MODE_NIGHT_YES)
initialValue = AppCompatDelegate.getDefaultNightMode() == AppCompatDelegate.MODE_NIGHT_NO
)

fun updateUiModeFromCache() {
coroutineManager.applicationScope.launch {
mutableDarkThemeSharedFlow.emit(
value = DarkModeSettings(
isSystemDrivenUiEnabled = soraPreferences.getBoolean(
field = KEY_SYSTEM_DRIVEN_UI_ENABLED,
defaultValue = false
),
isDarkModeEnabled = soraPreferences.getBoolean(
field = KEY_DARK_THEME_ENABLED,
defaultValue = false
)
// isSystemDrivenUiEnabled = soraPreferences.getBoolean(
// field = KEY_SYSTEM_DRIVEN_UI_ENABLED,
// defaultValue = false
// ),
isSystemDrivenUiEnabled = false,
// isDarkModeEnabled = soraPreferences.getBoolean(
// field = KEY_DARK_THEME_ENABLED,
// defaultValue = false
// )
isDarkModeEnabled = false,
)
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@ fun SoraAppTheme(
content: @Composable () -> Unit
) {
AppTheme(
darkTheme = darkTheme,
darkTheme = false,
lightColors = soraLightColors,
darkColors = soraDarkColors,
darkColors = soraLightColors,
typography = soraTypography,
borderRadius = soraBorderRadius,
content = content
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,16 +68,16 @@ internal fun AppSettingsScreen(
icon = null,
label = stringResource(id = R.string.system_appearance),
bottomDivider = false,
available = true,
checked = checkedSystem,
available = false,
checked = false,
onClick = onSystemToggle,
)
OptionSwitch(
icon = null,
label = stringResource(id = R.string.dark_mode),
bottomDivider = false,
available = true,
checked = checkedDark,
available = false,
checked = false,
onClick = onDarkToggle,
)
}
Expand Down

0 comments on commit ebccd57

Please sign in to comment.