DevTools: Make TextEditor.tokenAtTextPosition() return exclusive end column

All call sites compensate for the inclusive end column by adding 1
to token.endColumn to get the actual token text.

R=lushnikov

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180260 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Make variable names about |className| in PrivateScriptRunner more consistent

After this CL:

- |className| means a class name of a dependency interface (e.g., "Document").

- |scriptClassName| means a class name of the script (e.g., "DocumentXSLT").

BUG=341031

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180261 bbb929c8-8fbe-4397-9dbb-9b2b20218538
ServiceWorker: Fix ServiceWorkerRegistration object handling

When there is an existing ServiceWorkerRegistration, getOrCreate() shouldn't
release the given WebServiceWorkerRegistration object because it has already
been taken by the existing registration.


BUG=396400
TEST=https://codereview.chromium.org/466723002/

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180262 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Oilpan: Prepare to move RenderSelectionInfoBase to Oilpan heap.

Because RenderSelectionInfoBase subclasses don't add Member<> fields,
RenderSelectionInfoBase::trace is not virtual.

BUG=398342

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180263 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DevTools: Take sourceURL into consideration in debugger agent when matching script url.

R=aandrey

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180264 bbb929c8-8fbe-4397-9dbb-9b2b20218538
ServiceWorker: Prevent premature garbage collection on ServiceWorkerRegistration

Before this patch, the ServiceWorkerRegistration object could be garbage
collected prematurely and it caused renderer crash.

This change keeps the registration object alive until stop() is called, and
notifies WebServiceWorkerRegistration of the stop event.


BUG=396400
TEST=https://codereview.chromium.org/466723002/

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180265 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Remove unused flag MediaQueryExp::isInteger

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180266 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Cleanup namespace usage in platform/graphics/[G-S]*

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180267 bbb929c8-8fbe-4397-9dbb-9b2b20218538
DevTools: CSS cleanup.

Source/devtools/front_end/inspectorStyle.css:1891 hide-disclosure-buttons
Never used.

Source/devtools/front_end/timelinePanel.css:358 timeline-loading
There is no aggregates stats in popover anymore.

Source/devtools/front_end/elementsPanel.css:648 css-font-value
https://codereview.chromium.org/59993003

Source/devtools/front_end/inspectorStyle.css:1821 console-filter-top
https://bugs.webkit.org/show_bug.cgi?id=68155

BUG=

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180268 bbb929c8-8fbe-4397-9dbb-9b2b20218538
FrameSelection::updateApperance for caret should not cause layout.

We do not need update caret rectangle synchronously because we just need 
updated caret in painting.
Thus this CL delays computing new caret rectangle.

Source/core/editing/FrameSelection.cpp:
- Add ResetCaretBlinkOption to updateAppearance(). The option is set 
to ResetCaretBlink when it is called from setSelection.
If ResetCaretBlink, we reset caret blinking.
If we need to repaint caret, set |m_caretRectDirty| flag.
If |m_caretRectDirty| is set, we call PageAnimator::scheduleVisualUpdate to 
trigger repaint.
For range, create VisibleSelection without validation like 
HTMLTextFormControlElement::setSelectionRange.
- Add the setCaretRectNeedsUpdate function to just set |m_caretRectDirty| flag
 and call new scheduleVisualUpdate function, which calls
PageAnimator::scheduleVisualUpdate.
- FrameSelection::invalidateCaretRect does
 1. Checks the dirty flag.
 2. Gets new caret rectangle and node which has the caret renderer.
 3. if caret is changed, invalidate the new caret rect and the old caret rect.
 4. Caches the new caret rect and node. Sets dirty flag off.
This function is similar to old recomputeCaretRect(deleted).
- Delete unused updateRenderTreeIfneeded() from notifyRenderOfSelectionChange().
In old days, notifyRenderOfSelectionChange() used renderer.
- Refactor FrameSelection::absoluteCaretBounds() to call updateCaretRect
 directly. Since we update layout, ASSERT that document's lifecycle is not in
InPaintInvalidation.


Source/core/editing/Caret.cpp:
- Remove document->updateRenderTreeIfNeeded() from CaretBase::updateCaretRect
 and call it from caller.
- In FrameSelection::paintCaret, call without updateRenderTreeIfNeeded because
the tree must be updated on the painting phase.
Source/core/frame/FrameView.cpp:
- FrameView::invalidateTreeIfNeeded calls FrameSelection::InvalidateCaretRect
to invalidate caret rect for each frame.

Source/core/html/HTMLTextFormControlElementTest.cpp:
- Add new test to confirm setSelectionRange with another start/end not cause 
layout.
- Delete FrameSelectionLocalCaretRectDoesNotCauseLayout because localCaretRect 
is removed.

Layouttests:
- This cl reduces redundant RenderObject::invalidatePaintRectangle calls so we 
need to delete lines from expected.txt but result images are still same.
 
BUG=382809, 397303, 403317
TEST=Layouttests/fast/forms/textarea-scrollbar.html, textarea-scrolled-type.html

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180269 bbb929c8-8fbe-4397-9dbb-9b2b20218538
[DevTools] Make Timeline tests use only model records

All places where raw TimelineAgent.Record was used are fixed.

BUG=403684,398785

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180270 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Unindent namespace content of WebElement.h, WebFormElement.h, and WebInputElement.h

These are the last instances of namespace indentation in public/.

BUG=none
TEST=none; no behavior changes.

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

git-svn-id: svn://svn.chromium.org/blink/trunk@180271 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Cleanup blink:: prefix usage in Source/core/modules/[battery/*.cpp to indexeddb/*.cpp]

Cleanup blink:: prefix usage in Source/core/modules/[battery/*.cpp to indexeddb/*.cpp]

- Merge multiple |namespace blink {}| blocks
- Remove unnecessary blink:: prefixes
- Make blank lines consistent

BUG=None

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

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