Move DOM logic from Pasteboard::writeImage into Editor.

This knowledge does not belong in core/platform/.

BUG=276565

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

git-svn-id: svn://svn.chromium.org/blink/trunk@163793 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Debug crash on ASSERT while DevTools is open and paused.

Fixing the ASSERT.
Repro steps:
- open DevTools
- reload the inspected page
- stop the JS debugger early enough while the page is being loaded
- reload the inspected page

R=yurys@chromium.org, japhet@chromium.org, yurys

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

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