Fully invalidate canvas when it's resized

http://src.chromium.org/viewvc/blink?revision=176700 removed forced
full paint invalidation on size style change, assuming that the
renderers would properly invalidate themselves if needed during layout.
However canvas missed the required full paint invalidation when resized.

Move the replaceContentRect change detection logic from RenderImage up
to RenderReplaced so that all RenderReplaced subclasses share the same
logic.

BUG=425572
TEST=fast/repaint/canvas-resize.html
TEST=fast/repaint/canvas-resize-no-full-invalidation.html

Review URL: https://codereview.chromium.org/641743004

git-svn-id: svn://svn.chromium.org/blink/trunk@184126 bbb929c8-8fbe-4397-9dbb-9b2b20218538