added unload dialog call to mediator