Fix text autosizing oscillation for elements with contenteditable=true attribute.
The fix treats the contenteditable elements in the same way textareas are treated, i.e. as if they contain more that 4 lines of text and hence should be autosized.

BUG=237564

Review URL: https://chromiumcodereview.appspot.com/16098008

git-svn-id: svn://svn.chromium.org/blink/trunk@151979 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Avoid DEFINE_STATIC_LOCAL for Strings.

This pattern saved memory allocation at the expense of bloating
code size. Prefer small code size when these aren't bottlenecks.

Saves 72 bytes per string, for a total of 2448 bytes
for this change.

BUG=247082

Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=151955

Review URL: https://chromiumcodereview.appspot.com/16457004

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

In order to optimize string usage, I've been iterating locally on the
STRING_STATS code. This CL updates the checked in code to match the new hotness
I've been using locally.

R=eseidel

Review URL: https://chromiumcodereview.appspot.com/16578003

git-svn-id: svn://svn.chromium.org/blink/trunk@151981 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Remove deprecated methods from WebMediaPlayer

The implementations were removed from chromium in http://crrev.com/204601

R=abarth

Review URL: https://chromiumcodereview.appspot.com/16571009

git-svn-id: svn://svn.chromium.org/blink/trunk@151982 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Revert "Remove deprecated methods from WebMediaPlayer"

r151982 broke Chrome OS build that still references these methods.

TBR=abarth
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/blink/trunk@151983 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DocType strings should be 8 bit wide

Although this CL doesn't save much memory, it satifies my OCD. After this CL,
espn.com uses fully optimized strings. The only strings that were missing were
the DocType, which were unnecessarily wide.

R=eseidel

Review URL: https://chromiumcodereview.appspot.com/16103013

git-svn-id: svn://svn.chromium.org/blink/trunk@151984 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Factor common logic for prefixed and unprefixed MediaSource APIs into MediaSourceBase.

The unprefixed and prefixed MediaSource APIs will need to
coexist for a little while. This change factors out common
logic needed by both implementations into MediaSourceBase. 
HTMLMediaElement and related classes are updated to use
MediaSourceBase so that they can work with either API. This
is only a code structure change. There are no behavior
changes.

BUG=239506
TEST=None. No behavior changes. All existing tests still pass.

Review URL: https://chromiumcodereview.appspot.com/15849012

git-svn-id: svn://svn.chromium.org/blink/trunk@151985 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Mark http/tests/inspector/compiler-source-mapping-debug.html as crashy

TBR=

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

git-svn-id: svn://svn.chromium.org/blink/trunk@151986 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Make flakiness dashboard group names make sense.

-Rename them to better reflect what they actually refer to.
-Get rid of the Content Shell group. There's only one bot left
that specially runs Content Shell and that's on the chopping block.
For now, include it in the @ToT Blink group.
-Get rid of the last remnant of webkit.org support.

R=jparent@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@151987 bbb929c8-8fbe-4397-9dbb-9b2b20218538
balloon-juice.com should use 85 kB less memory

Browsing around the web with STRING_STATS, I noticed we commonly end up with
duplicated scripts String. Studying the issue more carefully, I determined that
these scripts were inline scripts that appeared multiple times (e.g., in
different iframes).

This CL teaches Blink to atomize inline scripts immediately before executing
them. If an inline script appears in multiple documents, they'll end up sharing
the same underlying string storage.

An alternative is to atomize the string as we're constructing the DOM, but that
can work poorly if there is a network packet boundary in the middle of (large)
inline script blocks. Instead, we want to wait until we're done parsing the
script element. Doing the atomization immediately before execution also lets us
piggyback on the logic that checks whether the script element has a single
child Text node, which is exactly the case in which atomization is likely to be
useful.

I used ballon-juice.com as a test bed for studying this issue because it is a
fairly typical blog-based web site. This CL dropped the memory wasted by
duplicate strings from 94,809 kB to 10,280 kB, a savings of 85 kB. Here is an
example string before and after this CL:

== Before ==

2 copies (ok) of length 52790 /* <![CDATA[ */?if(!((window._atc||{}).ver)){var _atd="www.addth...

== After ==

1 copies (ok) of length 52790 /* <![CDATA[ */?if(!((window._atc||{}).ver)){var _atd="www.addth...

We should consider the same optimization for inline style elements as well if
we see them wasting memory in the same way.

R=eseidel
NOTRY=true

Review URL: https://chromiumcodereview.appspot.com/16398009

git-svn-id: svn://svn.chromium.org/blink/trunk@151988 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Fix sorting when generating builders.jsonp

The for loop that did the sorting was outdented too far, so it
was only sorting the last master's builders.

NOTRY=true

Review URL: https://chromiumcodereview.appspot.com/16026018

git-svn-id: svn://svn.chromium.org/blink/trunk@151989 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Support parsing of inset-rectangle shapes

Add parsing for inset-rectangle. It's very similar to parsing for
rectangle.

This is a port of https://bugs.webkit.org/show_bug.cgi?id=116638

BUG=243081

Review URL: https://chromiumcodereview.appspot.com/15735026

git-svn-id: svn://svn.chromium.org/blink/trunk@151990 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Enforce MSE duration consistency

Simplify WebMediaPlayer implementation conformance to
MediaSource API duration consistency requirement by
reflecting the WebKitMediaSource's duration instead
of the WebMediaPlayer's.  video.duration should
now exactly match mediasource.duration without relying
on underlying WebMediaPlayer.  Thanks to acolwell@, who
provided this patch suggestion.

R=acolwell@chromium.org

Review URL: https://chromiumcodereview.appspot.com/15735030

git-svn-id: svn://svn.chromium.org/blink/trunk@151991 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Test that embed and object can load image

Add new rebaselines for embed and object image tests.

NOTRY=true
BUG=246940
R=noel@chromium.org

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

Patch from Eric Willigers <ericwilligers@chromium.org>.

git-svn-id: svn://svn.chromium.org/blink/trunk@151992 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Mobile Gmail should use 1.3 MB less memory

The vast majority of the remaining 16 bit strings in Mobile Gmail are coming
from our v8::String to WTF::String conversion. Before this CL, we were relying
upon V8 to detect 8 bit strings. This CL makes it so we check whether the
resulting WTF::String fits in 8 bits when we create it from the v8::String.
(Note that we also externalize the v8::String when we convert it to a
WTF::String, so we shrink the V8 representation of the string at the same
time.)

The STRING_STATS for this change are below. My test environment isn't 100%
reproducable, so the data isn't completely consistent. For example, there are
283,552 more toal characters in the "before" measurement than in the "after"
measurement, which biases the results slightly.  However, even if those missing
strings were all 16 bits wide, this CL would still be a >1 MB memory win.

= Mobile Gmail =

== Before ==

String stats for process id 23182:
    5311 (98.99%) 8 bit             1877856 chars       1877856 bytes  avg length  353.6
      54 ( 1.01%) 16 bit            1839813 chars       3679626 bytes  avg length 34070.6
       8 ( 0.15%) upconverted          1138 chars          2276 bytes  avg length  142.2
    5365 Total                      3717669 chars       5559758 bytes  avg length  692.9
         Total savings      1876718 bytes (25.24%)

== After ==

String stats for process id 23382:
    5307 (99.31%) 8 bit             2687571 chars       2687571 bytes  avg length  506.4
      38 ( 0.71%) 16 bit             746572 chars       1493144 bytes  avg length 19646.6
       6 ( 0.11%) upconverted          1112 chars          2224 bytes  avg length  185.3
    5344 Total                      3434143 chars       4182939 bytes  avg length  642.6
         Total savings      2686459 bytes (39.11%)

NOTRY=true

Review URL: https://chromiumcodereview.appspot.com/16158008

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