Add getWindowSize and test.