Thank you very much. That is such a simple solution. I just added it as an action to the Chats .desktop file, and it works perfectly.
For anyone who finds this post searching for the solution and doesn’t know how to add actions to .desktop files, do this:
-
Copy sm.puri.Chatty.desktop to ~/.local/share/applications/
cp /usr/share/applications/sm.puri.Chatty.desktop ~/.local/share/applications/
-
Open sm.puri.Chatty.desktop in gedit:
gedit ~/.local/share/applications/sm.puri.Chatty.desktop
-
Add this to the bottom of the file:
Actions=kill; [Desktop Action kill] Name=kill Exec=killall chatty
-
Save and close gedit.
-
To run the command to kill the Chats app, tap and hold on the Chats app icon (or right-click it if you have a mouse connected) and tap (or click) “kill” on the menu.