fix: won't terminate when all window is minimized