Refactor maven structure. Add onClose event handler