lock for the current view