Moving to getDimensionPixelSize

getDimensionPixelSize actually works correctly (compared to whatever I
was using before).  And the code is much more compact.