mirror of
https://github.com/end-4/dots-hyprland.git
synced 2026-06-05 14:59:27 -05:00
fix colors not applied properly on first run
This commit is contained in:
@@ -32,6 +32,21 @@ Singleton {
|
||||
Appearance.m3colors.darkmode = (Appearance.m3colors.m3background.hslLightness < 0.5)
|
||||
}
|
||||
|
||||
function resetFilePathNextTime() {
|
||||
resetFilePathNextWallpaperChange.enabled = true
|
||||
}
|
||||
|
||||
Connections {
|
||||
id: resetFilePathNextWallpaperChange
|
||||
enabled: false
|
||||
target: Config.options.background
|
||||
onWallpaperPathChanged: {
|
||||
root.filePath = ""
|
||||
root.filePath = Directories.generatedMaterialThemePath
|
||||
resetFilePathNextWallpaperChange.enabled = false
|
||||
}
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: delayedFileRead
|
||||
interval: Config.options?.hacks?.arbitraryRaceConditionDelay ?? 100
|
||||
@@ -54,5 +69,6 @@ Singleton {
|
||||
const fileContent = themeFileView.text()
|
||||
root.applyColors(fileContent)
|
||||
}
|
||||
onLoadFailed: root.resetFilePathNextTime();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user