Ensure that 'fetchMainResource' requests have a frame type.

This patch adds an ASSERT to 'ResourceFetcher::fetchMainResource' which
ensures that the request's FrameType is not FrameTypeNone, and uses that
information to ensure that the correct TargetType is synthesized when
heading back up into Chromium.

In order to make the ASSERT true, FrameLoader does a bit of work on the
NavigationAction it creates, and NavigationAction grows a
'mutableResourceRequest' method in order to allow that work to happen.

-----------------------------------------------------------------------
This is a re-land of r171181[1], reviewed in [2]. That CL was reverted,
as it hit an assert in a number of Chromium-side browser tests. This
iteration on the patch ensures that the FrameType is correctly set when
setting a WebURLRequest's TargetType.

[1]: https://src.chromium.org/viewvc/blink?view=rev&revision=178181
[2]: https://codereview.chromium.org/388253002/
-----------------------------------------------------------------------

BUG=390497
R=jochen@chromium.org

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

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