Fix for recording canvas crash with cache

Essentially, the cache should only be enabled if the canvas/context is *not* a recording canvas/context.

BUG=372110

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

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