mirror of
https://github.com/jrpie/Launcher.git
synced 2025-02-23 14:31:30 +01:00
Fix: White display
When newly installing the app, it would have an all white screen because the vibrant and dominant color would only be set when changing themes. This problem emerged within the `fix/code` branch and was not published anywhere yet.
This commit is contained in:
parent
56fb5a063d
commit
b01ddf2ae6
1 changed files with 12 additions and 3 deletions
|
@ -253,13 +253,22 @@ fun loadSettings(){
|
||||||
|
|
||||||
fun resetSettings(context: Context) : MutableList<String>{
|
fun resetSettings(context: Context) : MutableList<String>{
|
||||||
|
|
||||||
// set default theme
|
|
||||||
saveTheme("finn")
|
|
||||||
|
|
||||||
val defaultList :MutableList<String> = mutableListOf<String>()
|
val defaultList :MutableList<String> = mutableListOf<String>()
|
||||||
|
|
||||||
val editor = launcherPreferences.edit()
|
val editor = launcherPreferences.edit()
|
||||||
|
|
||||||
|
// set default theme
|
||||||
|
dominantColor = context.resources.getColor(R.color.finnmglasTheme_background_color)
|
||||||
|
vibrantColor = context.resources.getColor(R.color.finnmglasTheme_accent_color)
|
||||||
|
|
||||||
|
launcherPreferences.edit()
|
||||||
|
.putString("background_uri", "")
|
||||||
|
.putInt("custom_dominant", dominantColor)
|
||||||
|
.putInt("custom_vibrant", vibrantColor)
|
||||||
|
.apply()
|
||||||
|
|
||||||
|
saveTheme("finn")
|
||||||
|
|
||||||
val (chosenUpName, chosenUpPackage) = pickDefaultApp(
|
val (chosenUpName, chosenUpPackage) = pickDefaultApp(
|
||||||
"action_upApp",
|
"action_upApp",
|
||||||
context
|
context
|
||||||
|
|
Loading…
Add table
Reference in a new issue