Hack to allow enabling child window 'close' events.