issue #5161, replace deprecated methods
issue #5161, replace _size with _contentSize