Added window snapping.