Move the frame tree/opener code into WebFrame.

This logic should be shared between local and remote frames, since they
will co-exist in the same frame tree in the renderer.

BUG=346764

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

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