This patch does other things to: 1. Refactor out getBounds() 2. Fix a mistake in PivotContext._isDefunct()