Combine duplicate code about ref/ptr comparison

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

git-svn-id: svn://svn.chromium.org/blink/trunk@177727 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Use [TreatNullAs=EmptyString] for DOMString attributes with [Reflect]

In cases where the HTML specification uses [TreatNullAs=EmptyString] on
an IDL attribute that reflects a content attribute, use the same in our
IDL files to get correct behavior when assigning null.

Previous incorrect behavior when assigning null was to remove the
reflected content attribute, if present, and otherwise do nothing.

The new behavior matches Firefox and Opera/Presto. IE11 behaves the same
when the content attribute is present, but doesn't create the content
attribute if it's missing and null is assigned to the IDL attribute.

This change impacts performance significantly (~4x slowdown) in the case
of assigning null to the IDL attribute when the reflected content
attribute is not present, i.e. the previous "do nothing" case. This ought
to be considered an irrelevant micro-benchmark, and the reason it slows
down is that the incorrect (web-facing) behavior is a no-op while the
correct behavior is not.

Performance in other cases, in particular the case of assigning null to
the IDL attribute when the reflected content attribute is present, show
no significant change.

BUG=391194

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

git-svn-id: svn://svn.chromium.org/blink/trunk@177728 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DevTools: merge search module into sources.

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

git-svn-id: svn://svn.chromium.org/blink/trunk@177729 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Revert of HTMLParser should use current value of scriptEnabled flag (https://codereview.chromium.org/313173012/)

Reason for revert:
This patch *appears* to break AwSettingsTest and
AwContentsClientShouldOverrideUrlLoadingTest:
http://build.chromium.org/p/chromium.webkit/builders/Android%20Tests%20(dbg)

This is my wild guess but it might be possible
that this patch is the cause, since the tests in
question call setJavaScriptEnabled(true).

Apologies if my guess is wrong. I'll revert the
revert if it turned out that I'm wrong.

Original issue's description:
> HTMLParser should use current value of scriptEnabled flag
> 
> This CL adds caching  of scriptEnabled setting to Document.
> 
> When page is reloaded we create new parser throught DocumentLoader::ensureWriter
> and set scriptEnabled flag. ContentSettingsObserver::allowScript method is
> responsible for checking settings but it uses cache. Cache is cleared on
> DidCommitProvisionalLoad but parser is already created before that. However we
> can't clear cache earlier because unload events for old page might be fired and
> it depends on old page settings (cached).
> 
> BUG=232410
> 
> Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=177664

NOTREECHECKS=true
NOTRY=true
BUG=232410

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

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