fixed calendar bugs with refrshing and resizing