adjustments to deal better with locks of visibleAnnotations array