add setTimeout for Close