Bugfix: prevent calendar popup from being destoyed.

The window should intercept the delete event and hide itself,
otherwise it's gone forever.