mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-28 15:32:50 -05:00
Allow solid colored wallpaper, fix fzf search
This commit is contained in:
@@ -33,20 +33,42 @@ LazyLoader {
|
||||
anchors.fill: parent
|
||||
|
||||
property string source: SessionData.wallpaperPath || ""
|
||||
property bool isColorSource: source.startsWith("#")
|
||||
property Image current: one
|
||||
|
||||
onSourceChanged: {
|
||||
if (!source)
|
||||
if (!source) {
|
||||
current = null
|
||||
else if (current === one)
|
||||
two.update()
|
||||
else
|
||||
one.update()
|
||||
one.source = ""
|
||||
two.source = ""
|
||||
} else if (isColorSource) {
|
||||
current = null
|
||||
one.source = ""
|
||||
two.source = ""
|
||||
} else {
|
||||
if (current === one)
|
||||
two.update()
|
||||
else
|
||||
one.update()
|
||||
}
|
||||
}
|
||||
|
||||
onIsColorSourceChanged: {
|
||||
if (isColorSource) {
|
||||
current = null
|
||||
one.source = ""
|
||||
two.source = ""
|
||||
} else if (source) {
|
||||
if (current === one)
|
||||
two.update()
|
||||
else
|
||||
one.update()
|
||||
}
|
||||
}
|
||||
|
||||
Loader {
|
||||
anchors.fill: parent
|
||||
active: !root.source
|
||||
active: !root.source || root.isColorSource
|
||||
asynchronous: true
|
||||
|
||||
sourceComponent: DankBackdrop {}
|
||||
|
||||
Reference in New Issue
Block a user