1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2025-12-13 00:42:49 -05:00

color: hide picker instantly when spawning hyprpicker

fixes #575
This commit is contained in:
bbedward
2025-10-28 10:19:56 -04:00
parent d7efd1b285
commit ee0e3aece9
3 changed files with 36 additions and 2 deletions

View File

@@ -45,6 +45,12 @@ DankModal {
close()
}
function hideInstant() {
onColorSelectedCallback = null
shouldBeVisible = false
visible = false
}
onColorSelected: (color) => {
if (onColorSelectedCallback) {
onColorSelectedCallback(color)
@@ -78,7 +84,7 @@ DankModal {
}
function pickColorFromScreen() {
hide()
hideInstant()
Proc.runCommand("hyprpicker", ["hyprpicker", "--format=hex"], (output, errorCode) => {
if (errorCode !== 0) {
console.warn("hyprpicker exited with code:", errorCode)