Stopped it being able to be dragged beyond the view size