bool closed

Indicates whether this window has been closed.

print(window.closed); // 'false'
window.close();
print(window.closed); // 'true'