Reland "Prepare blink to unify definitions of load completion"

This reverts commit 963b3f017df5e3098f0ffe18fd6ea818a5589b6f.

Currently, FrameLoader.cpp contains a function called isDocumentDoneLoading,
which has a complicated set of rules to determine when to tell chromium that
loading is complete. These rules only really exist for the sake of layout
tests, which can't always just define load event completion as the end of
the test. A set of rules have been added to the layout tests harness behind
a build flag, so add a flagged version of load completion in blink that is
strongly mapped to load event completion.

Lots of tests need subtle changes. Most of these are forced layouts, waiting for RAF to complete, simple waitUntilDone/notifyDone pairs, and adding missing document.close() calls.

BUG=426520

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

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