fontSelector should be reset when removing stylesheets which has @font-face rule.

r159957 changed to avoid destroying StyleResolver when removing stylesheets.
However if the removed stylesheets has any @font-face rule, we need to reset not only rulesets,
but fontselector.

BUG=305885
TEST=fast/css/font-face-remove.html,fast/css/remove-style-after-insert-font-face.html,fast/css/remove-style-after-remove-font-face.html

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162094 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Non-activated default buttons prevent implicit form submission.

Follow the spec and two other implementations (Gecko + Presto), and do
not allow implicit form submission if the default (submit) button is
not in an activated state (read: disabled.)

Notice that this switches to behavior different from what Trident / IE
provides.

R=eseidel,tkent
BUG=37402

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162095 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Remove default values for Web Animations runtime flags

These are no longer required, as Chromium always sets an explict value.

BUG=258896
R=dstockwell

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162096 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Don't use adjustedFocusedElement in order to blur the focused element when removing a node.

This makes http://jsperf.com/parse-html-type (micro benchmarks for innerHTML) 35% faster.
87k ops/s vs. 64k ops/s on the "tags" test on my machine. Other tests get similar performance gain too.

We don't have to use adjustedFocusedElement() in Document::removeFocusedElementInSubtree(). TreeScope::adjustedFocusedElement() is a costly operation

The reason of calling adjustedFocusedElement() until now is:
- When a distributed node is focused and its final destination insertion point, for example, is removed, we want to guarantee that the focused distributed node is blurred correctly.

But this case is similar to setting 'display: none;' to the focused element in a sense that the focused element stays in document, but it doesn't get rendered anymore.

We don't guarantee this behavior. We leave the focused element as document.activeElement in this case. Other browsers (old Opera, Firefox, WebKit) does so.

See also the discussion starting https://code.google.com/p/chromium/issues/detail?id=318448#c23.


BUG=318448

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162099 bbb929c8-8fbe-4397-9dbb-9b2b20218538
[Android WebView] Add more tests for ClobberUserAgentInitialScaleQuirk

Added tests for cases when initial scale override _must_not_
be clobbered.

BUG=313754

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162105 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Implement [ExposeJSGetterAndSetter] IDL extended attribute

- This is a key IDL extended attribute to move DOM attributes to prototype chains. DOM attributes with [ExposeJSGetterAndSetter] will be installed on prototype chains and expose JS getter and setter.

- This CL just changes the code generator and doesn't use [ExposeJSGetterAndSetter] in real IDL files. I'll use it in real IDL files after a couple of V8 side changes are landed.

- [ExposeJSGetterAndSetter] is a temporary IDL extended attribute which will be gone once we move all DOM attributes to prototype chains.

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162106 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Rename es => exceptionState in core/dom

Relanding large patch incrementally, via CQ:
Rename es => exceptionState in other than bindings/
https://codereview.chromium.org/72363002/

cd "$BLINK_DIR/Source/core/dom" && \
    sed -ri '/"es"/ ! s/\<es\>/exceptionState/g' \
    $(git ls-files '*.cpp' '*.h')

TBR=haraken

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162108 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Correct error reporting in run-bindings-tests

Currently run-bindings-tests:
* has dead code (diff results in exception, so checking output never hit)
* has redundant code (always want to print output of commands)
* ...and lacks clear distinction of script errors vs. diffs

This arose b/c I noticed that I never saw the 'FAIL' line, as that was
dead code.

This fixes these problems.

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162109 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Rename es => exceptionState in core/html

Relanding large patch incrementally, via CQ:
Rename es => exceptionState in other than bindings/
https://codereview.chromium.org/72363002/

cd "$BLINK_DIR/Source/core/html" && \
    sed -ri '/"es"/ ! s/\<es\>/exceptionState/g' \
    $(git ls-files '*.cpp' '*.h')

TBR=haraken

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162110 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DevTools: Do not disconnect client in InspectorFrontendHost::closeWindow

This patch removes client disconnection from
InspectorFrontendHost::closeWindow as devtools window might not be
actually closed because of beforeunload handlers.

BUG=
R=pfeldman@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162111 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DevTools: remove popover from timeline bars.

R=loislo@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162112 bbb929c8-8fbe-4397-9dbb-9b2b20218538
V8Bindings: toVectorOfArguments => toNativeArguments

Eliminate an unnecessary method by just adding a case to NativeArguments<>.

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162113 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Introduce SpellCheckerClient and SpellCheckerClientImpl classes

This patch introduces SpellCheckerClient and its implementation SpellCheckerClientImpl to decouple editing and spell checking for ease for maintenance.

This patch also removes redundant forward class declaration and include files from EditorClient.h to reduce compilation time.

BUG=n/a
TEST=n/a; no beahvior changes

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

git-svn-id: svn://svn.chromium.org/blink/trunk@162114 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Implement File constructor.

The feature is behind the FileConstructor RuntimeEnabledFeature with
status=experimental.

BUG=164933

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

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