commit 71bd186c0d0f8674506e587a7deefb6915c8882c parent 249ebd6c8d02a0abfef8c5656dcac98926b3c856 Author: Pablo Cárdenas <pablo.cardenas@imca.edu.pe> Date: Mon, 29 Apr 2024 18:13:30 -0500 Fixed ScratchPad when dialog appear Diffstat:
| M | .local/bin/scratchpad.sh | | | 6 | +++--- |
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/.local/bin/scratchpad.sh b/.local/bin/scratchpad.sh @@ -1,6 +1,6 @@ #!/bin/bash -winid=$(xdotool search --class Emacs | head -n 1) +winid=$(xdotool search --class Emacs) visible_winid=$(xdotool search --onlyvisible --class Emacs) echo $winid @@ -9,8 +9,8 @@ if [ -z "$winid" ]; then nohup emacs >/dev/null 2>/dev/null </dev/null & else if [ -z "$visible_winid" ]; then - xdo show "$winid" + echo "$winid" | xargs -I{} xdo show {} else - xdo hide "$visible_winid" + echo "$winid" | xargs -I{} xdo hide {} fi fi