Refactor centerSpaceObj centering.