modifided view close method

Signed-off-by: alkaest2002 <p.calanna@gmail.com>
deleted beforeClose function form view

Signed-off-by: alkaest2002 <p.calanna@gmail.com>