Merge branch 'main' into sdfs
This commit is contained in:
commit
552c2e1480
3 changed files with 35 additions and 2 deletions
|
|
@ -63,5 +63,11 @@ if("shell" IN_LIST ENABLE_MODULES)
|
|||
foreach(dir assets components config modules services utils)
|
||||
install(DIRECTORY ${dir} DESTINATION "${INSTALL_QSCONFDIR}")
|
||||
endforeach()
|
||||
install(FILES shell.qml LICENSE DESTINATION "${INSTALL_QSCONFDIR}")
|
||||
|
||||
file(READ shell.qml SHELL_QML)
|
||||
string(REPLACE "settings.watchFiles: true" "settings.watchFiles: false" SHELL_QML "${SHELL_QML}")
|
||||
file(WRITE "${CMAKE_BINARY_DIR}/qml/shell.qml" "${SHELL_QML}")
|
||||
install(FILES "${CMAKE_BINARY_DIR}/qml/shell.qml" DESTINATION "${INSTALL_QSCONFDIR}")
|
||||
|
||||
install(FILES LICENSE DESTINATION "${INSTALL_QSCONFDIR}")
|
||||
endif()
|
||||
|
|
|
|||
|
|
@ -79,6 +79,21 @@ Singleton {
|
|||
Quickshell.execDetached(["caelestia", "scheme", "set", "--notify", "-m", mode]);
|
||||
}
|
||||
|
||||
function reloadHyprRules(): void {
|
||||
const str = "keyword layerrule %1 %2, match:namespace caelestia-drawers";
|
||||
Hypr.extras.batchMessage([str.arg("blur").arg(transparency.enabled ? 1 : 0), str.arg("ignore_alpha").arg(transparency.base - 0.03)]);
|
||||
}
|
||||
|
||||
Component.onCompleted: debounceTimer.triggered()
|
||||
|
||||
Connections {
|
||||
function onConfigReloaded(): void {
|
||||
root.reloadHyprRules();
|
||||
}
|
||||
|
||||
target: Hypr
|
||||
}
|
||||
|
||||
FileView {
|
||||
path: `${Paths.state}/scheme.json`
|
||||
watchChanges: true
|
||||
|
|
@ -92,10 +107,20 @@ Singleton {
|
|||
source: Wallpapers.current
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: debounceTimer
|
||||
|
||||
interval: 300
|
||||
onTriggered: root.reloadHyprRules()
|
||||
}
|
||||
|
||||
component Transparency: QtObject {
|
||||
readonly property bool enabled: Appearance.transparency.enabled
|
||||
readonly property real base: Appearance.transparency.base - (root.light ? 0.1 : 0)
|
||||
readonly property real base: Math.max(0, Math.min(1, Appearance.transparency.base - (root.light ? 0.1 : 0)))
|
||||
readonly property real layers: Appearance.transparency.layers
|
||||
|
||||
onEnabledChanged: debounceTimer.restart()
|
||||
onBaseChanged: debounceTimer.restart()
|
||||
}
|
||||
|
||||
component M3TPalette: QtObject {
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ import "modules/lock"
|
|||
import Quickshell
|
||||
|
||||
ShellRoot {
|
||||
settings.watchFiles: true
|
||||
|
||||
Background {}
|
||||
Drawers {}
|
||||
AreaPicker {}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue