[CSS Grid Layout] Avoid mark grid as dirty always when removing a child

Current code always mark the grid as dirty in RenderGrid::removeChild().

If the grid auto flow property is different to none, the grid has to be
marked as dirty when a child removed. Just in case, the grid contains
auto-placed items, that might need to be re-positioned.

Otherwise, we can simple remove the child from the grid cells where it
is present and update the coordinates cache accordingly.

BUG=248151
TEST=fast/css-grid-layout/grid-item-removal-auto-placement-update.html

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170484 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Refactor StyleInvalidator to encapsulate all style invalidation state.

This is a nice cleanup, and sets us up for separating StyleInvalidator from 
RuleFeatureSet, which will allow us to more easily  TargetedStyleRecalc for style 
sheet loads.

BUG=318468

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170485 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Issue trace events to gather repaint information.

This CL adds a few trace events in to gather information about the cause
and size of repaints.

BUG=320139, 351498

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170486 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Remove unnecessary include at RenderTableSection after bug fixed

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170487 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Add an unimplemented history API to WebView

This API will function as a temporary shim to enable
history functionality to move to content/renderer, without
any broken intermediate steps.

This is step 1 of 5 from http://crbug.com/357327

BUG=357327

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170488 bbb929c8-8fbe-4397-9dbb-9b2b20218538
[repaint-after-layout] Skip invalidations if our RenderView did a full invalidation.

This CL updates FrameView::repaintTree to skip issuing invalidations for any
RenderObject if they don't have a layer and their RenderView did a full
invalidation. This seems to be closer to the behaviour that the system exhibits
with repaint-after-layout disabled.

BUG=320139

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170489 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Optimize named property access on CSSStyleDeclaration objects

When reading property on a CSSStyleDeclaration object, the property name
is transformed into a possible CSS property name and looked up as such.
This transformation involves copying the property name to a StringBuilder
while converting from camelCase to dash-separated.

Positive matches are cached in a local static hash map, but negative
matches were not.  A script reading properties like "getPropertyValue"
would trigger the conversion to "get-property-value" and CSS property
lookup every time.

Optimize by caching negative matches as well as positive ones.

BUG=

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170490 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Handle direction control in compositor Animations

This patch is the blink side.
The chromium side is handled on issue #180153010

It doesn't revert functions anymore in blink. Instead, it sets the
direction parameter to WebAnimation, which will in turn pass it to the
compositor

BUG=348071

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170491 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Move dispatchUnloadEvent to WebFrame, part 1/3.

BUG=357782
TEST=no change

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170492 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Consolidate tests marked as slow in TestExpectations to SlowTests

R=ojan
BUG=

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170493 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Disable the thread-safe MQ parser for main thread

This reverts commit d1eea2e66e64c3c019885ad7e94933aa0fc05576.
On top of that, this CL makes sure that only the preloader uses the thread safe MQ parser. That's in order to reduce the risk of breaking content when introducing the new MQ parser.

BUG=358078

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170494 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Validate finiteness of HTMLMediaElement properties.

BUG=357707

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170495 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Rename LayoutBox to CSSBoxType. Also rename the functions and methods that mention "LayoutBox" to something that makes sense for each specific situation.

This is a merge of http://trac.webkit.org/changeset/165843 by Bem Jones-Bey <bjonesbe@adobe.com>.

BUG=358377

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170496 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Documents with many lines overallocated pagination info.

There is an object LineFragmentationData that is used for pagination
that is created on demand. That object was created for normal documents
and cost roughly 32 bytes per line, adding up to 3-5 MB on a big text
document (5% of all memory usage).

Testcase: http://norvig.com/big.txt - 3-10 MB RAM savings.

I don't know what I'm doing but this patch prevents the allocation and
saves the memory.

BUG=353993

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

git-svn-id: svn://svn.chromium.org/blink/trunk@170497 bbb929c8-8fbe-4397-9dbb-9b2b20218538
CSS Animations: Adjust z-index when animating perspective

Styles generated by animations and transitions are currently applied
following adjustment (to avoid triggering transitions on adjustment).

Special handling existed for mirroring the adjustment behavior of
auto z-index when animating transform, however this failed to account
for animations of perspective. This has been broken as far back as
I am able to bisect and remains broken in WebKit for the same reason.

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

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