Open kohane27 opened 5 months ago
it's right here.
Hello it's the creator of Hyprland!
Apologies of my unclear question. I know that I can get the WINDOWADDRESS
. I meant how do I get the WINDOWCLASS
or WINDOWTITLE
from the WINDOWADDRESS
.
The WINDOWADDRESS
changes on reboot so the following doesn't work:
event_closewindow() {
# WINDOWADDRESS
case "$WINDOWADDRESS" in "5a6b54d80ba0")
bash "$HOME"/.config/zsh/scripts/disable-audio.sh
;;
esac
}
Basically I want the following:
case "$WINDOWCLASS" in "firefox")
bash "$HOME"/.config/zsh/scripts/disable-audio.sh
;;
esac
but in event_closewindow
instead of event_openwindow
. Thanks again!
you can't from the IPC as the window is already gone. You'll need to cache those states (probably launch hyprctl clients once and then just cache window open events)
Program
shellevents
Maintainers of the program
trippwill
Bug or Regression?
Bug
Description
Hello! Hope you're doing well.
It's not exactly a bug. I'm trying to use
event_closewindow
but run into issues: how do I get the target window'sWINDOWADDRESS
?event_openwindow
providesWINDOWCLASS
so it's easy to do so:But I can't do the same for
event_closewindow
because it only providesWINDOWADDRESS
:I tried the following:
But the window is already closed so
target_address
is alwaysnull
.Any input is much appreciated. Thank you.