Warning for running task doesn't come up when closing the entire window
Steps to reproduce:
- Open terminal
- Run
htop
- Close window
Observe the window closes without the popup showing up. We need to stop the window from closing and have the popup come up.