feat: add support for lazy loading in modules

This commit is contained in:
Hannes
2026-08-23 22:14:36 +02:00
parent 426b96a27e
commit 4b4159371d
4 changed files with 13 additions and 8 deletions
+6 -1
View File
@@ -35,4 +35,9 @@ Add the Lines to your ```~/.config/hypr/hyprland.conf``` keep in mind that you m
- Volume Contol - Volume Contol
- Notes - Notes
- wofi - wofi
### Inspirations
- [quickshell-examples](https://github.com/quickshell-mirror/quickshell-examples)
- [caelestia-shell](https://github.com/caelestia-dots/shell)
- [TheLinuxGuy](https://www.youtube.com/@TheLinuxGuy-btw)
+2 -2
View File
@@ -7,10 +7,10 @@ import Quickshell.Io
Item { // container, invisible Item { // container, invisible
id: jLoader id: jLoader
Loader { LazyLoader {
id: jLearnerLoader id: jLearnerLoader
active: false active: false
sourceComponent: JLearner { id: jLearner } JLearner { id: jLearner }
} }
GlobalShortcut { GlobalShortcut {
+2 -2
View File
@@ -8,10 +8,10 @@ import "../../config"
Item { // container, invisible Item { // container, invisible
id: wlLoader id: wlLoader
Loader { LazyLoader {
id: wlogoutLoader id: wlogoutLoader
active: false active: false
sourceComponent: Wlogout { Wlogout {
id: wLogout id: wLogout
} }
} }
+3 -3
View File
@@ -16,10 +16,10 @@ Item {
} }
} }
Loader { LazyLoader {
id: wallpaperLoader id: wallpaperLoader
active: false active: false
sourceComponent: WallpaperPicker { id: wPicker } WallpaperPicker { id: wPicker }
} }
GlobalShortcut { GlobalShortcut {
@@ -30,7 +30,7 @@ Item {
// generateThumbs.startDetached() // generateThumbs.startDetached()
generateThumbs.running = true generateThumbs.running = true
console.log("Pressed Meta+Shift+W (Hyprland global shortcut)") console.log("Pressed Meta+Shift+W (Hyprland global shortcut)")
wallpaperLoader.active = !wallpaperLoader.active wallpaperLoader.activeAsync = !wallpaperLoader.active
} }
} }