diff options
| author | Ja.KooLit <85185940+JaKooLit@users.noreply.github.com> | 2025-01-16 10:54:47 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-01-16 10:54:47 +0900 |
| commit | c30b1c5599daa78169486d76c9d3dd2fba3803a8 (patch) | |
| tree | a50caee93fc0c2f0d8c02f6d0120af71cc24f1ac /config/hypr/scripts/ScreenShot.sh | |
| parent | a4956da883d5fe2d66d528d2e9a890a2c6d064a8 (diff) | |
| parent | 47a6c42c77244b4b18f6e074542c15bc43bc4273 (diff) | |
Merge pull request #526 from JaKooLit/development
Development to main
Diffstat (limited to 'config/hypr/scripts/ScreenShot.sh')
| -rwxr-xr-x | config/hypr/scripts/ScreenShot.sh | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/config/hypr/scripts/ScreenShot.sh b/config/hypr/scripts/ScreenShot.sh index 0c6e8612..3fdd15b8 100755 --- a/config/hypr/scripts/ScreenShot.sh +++ b/config/hypr/scripts/ScreenShot.sh @@ -15,15 +15,15 @@ active_window_path="${dir}/${active_window_file}" notify_cmd_base="notify-send -t 10000 -A action1=Open -A action2=Delete -h string:x-canonical-private-synchronous:shot-notify" #notify_swappy="notify-send -h string:x-canonical-private-synchronous:shot-notify -u low -i ${iDIR}/picture.png" -notify_cmd_shot="${notify_cmd_base} -i ${iDIR}/picture.png" -notify_cmd_shot_win="${notify_cmd_base} -i ${iDIR}/picture.png" +notify_cmd_shot="${notify_cmd_base} -i ${iDIR}/picture.png " +notify_cmd_shot_win="${notify_cmd_base} -i ${iDIR}/picture.png " # notify and view screenshot notify_view() { if [[ "$1" == "active" ]]; then if [[ -e "${active_window_path}" ]]; then "${sDIR}/Sounds.sh" --screenshot - resp=$(timeout 5 ${notify_cmd_shot_win} "$(printf "\n Screenshot of ${active_window_class}\n Saved.")") + resp=$(timeout 5 ${notify_cmd_shot_win} " Screenshot of:" " ${active_window_class} Saved.") case "$resp" in action1) xdg-open "${active_window_path}" & @@ -33,13 +33,13 @@ notify_view() { ;; esac else - ${notify_cmd_shot} "$(printf "\n Screenshot of ${active_window_class}\n NOT Saved.")" + ${notify_cmd_shot} " Screenshot of:" " ${active_window_class} NOT Saved." "${sDIR}/Sounds.sh" --error fi elif [[ "$1" == "swappy" ]]; then "${sDIR}/Sounds.sh" --screenshot - resp=$(${notify_cmd_shot} "$(printf "\n Screenshot Captured\n by Swappy")") + resp=$(${notify_cmd_shot} " Screenshot:" " Captured by Swappy") case "$resp" in action1) swappy -f - <"$tmpfile" @@ -53,7 +53,7 @@ notify_view() { local check_file="${dir}/${file}" if [[ -e "$check_file" ]]; then "${sDIR}/Sounds.sh" --screenshot - resp=$(timeout 5 ${notify_cmd_shot} "$(printf "\n Screenshot Saved")") + resp=$(timeout 5 ${notify_cmd_shot} " Screenshot Saved") case "$resp" in action1) xdg-open "${check_file}" & @@ -63,7 +63,7 @@ notify_view() { ;; esac else - ${notify_cmd_shot} "$(printf "\n Screenshot NOT Saved")" + ${notify_cmd_shot} " Screenshot NOT Saved" "${sDIR}/Sounds.sh" --error fi fi @@ -74,7 +74,7 @@ notify_view() { # countdown countdown() { for sec in $(seq $1 -1 1); do - notify-send -h string:x-canonical-private-synchronous:shot-notify -t 1000 -i "$iDIR"/timer.png "$(printf "\n Taking shot in: $sec") secs" + notify-send -h string:x-canonical-private-synchronous:shot-notify -t 1000 -i "$iDIR"/timer.png " Taking shot" " in: $sec secs" sleep 1 done } |
