modified: bin/gui.pl

Clicking X on main will close it
Clicking X on main while having other tabs open will not close it