fixed getContentSize method