Hacky first-pass implementation of garden-o-matic.appspot

The unittests don't all pass yet.

R=abarth@chromium.org, ojan@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@158548 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Move platform/mock files closer to their implementations

These are really layering violations in themselves.  These mocks
don't belong in the shipping Blink binary at all, but rather
should be implemented as part of testing/runner.

However changing that is out of scope for my refactoring.  This
at least makes platform/mock not depend on modules.

BUG=301947
R=abarth@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@158549 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Add null-check for likely cause of a top crasher in HistoryController

It appears that if we load a javascript into a newly created iframe, we can
create the new frame without creating a new history item (neither real nor
dummy). In that case, HistoryController::restoreDocumentState may crash,
because it assumes m_currentItem is non-null.

BUG=301840
TEST=Haven't reduced one yet, will land one in a followup patch ASAP
R=abarth@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@158550 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Attempt to clean up requiresLayoutToDetermineWidth to be more clear

This code is brittle, and definitely wrong in some cases
but hopefully this is more clear now.

We need to find a path to making this more maintainable.  Clearly
this win is worth this complexity, we just need to figure out
how to not have more bad regressions from this.

BUG=247470
R=jchaffraix@chromium.org

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

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