Don't try to extend non-directional selection if selection has been gone

This patch changes Shift+LeftButton+Down to extend non-directional selection not to crash by checking whether selectable DOM Node |Position| is null or not-null.

The root cause of crash in issue 324975 is getting |Range| object for null |Position|, which isn't allowed, in |textDistance(Position position, Position reference)|.

Note: At this time, non-directional selection is enabled only for MacOSX.

BUG=324975
TEST=LayoutTests/fast/events/shift-click-user-select-none.html

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168106 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Garden-o-matic: Display the full [TB]R=... list of reviewers

Dot-trimming of the R=... line originated from the
ChangeLog "Reviewed by John Doe." format where it was necessary
to remove the trailing period. As a result, a reviewers line like
"foo@chromium.org, bar" would turn into "foo@chromium".

R=eseidel
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168108 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Auto-rebaseline for r168010

http://src.chromium.org/viewvc/blink?view=revision&revision=168010

TBR=mkwst@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168109 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Auto-rebaseline for r167941

http://src.chromium.org/viewvc/blink?view=revision&revision=167941

TBR=hartmanng@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168110 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Revert of Fix use-after-free of m_currentSpeechUtterance. (https://codereview.chromium.org/180553004/)

Reason for revert:
Linux build broken:

../../third_party/WebKit/Source/modules/speech/SpeechSynthesis.cpp:228:12: error: cannot convert 'std::nullptr_t' to 'WebCore::SpeechSynthesisUtterance*' in return

Original issue's description:
> Fix use-after-free of m_currentSpeechUtterance.
> 
> SpeechSynthesis.cpp incorrectly assumed that calling
> m_platformSpeechSynthesizer->cancel() would immediately call
> didFinishSpeaking or speakingErrorOccurred, which would null out
> m_currentSpeechUtterance. This assumption was true in WebKit/Mac, but
> Chromium's platform implementation is asynchronous, so that call may
> come later.
> 
> Fix the issue and simplify the logic by getting rid of the raw pointer
> to the current utterance altogether. Now the RefPtr at the front of the
> utterance queue is the current utterance, and the platform implementation
> is allowed to fire events on utterances that are no longer in the queue.
> 
> BUG=344881
> R=abarth@chromium.org
> 
> Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=168092

TBR=abarth@chromium.org,dmazzoni@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=344881

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168111 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Don't precompile scripts.

This is a reincarnation of https://chromiumcodereview.appspot.com/16034008.

Removing precompilation would be a huge win from V8 point of view, and it's not
clear how big the performance impact would be if we just remove it. The previous
time removing it was attempted, morejs regressed 5% (see crbug.com/247728), but
this regression is not reproducible any more. The benefit of precompilation in
real world use cases is questionable.

BUG=
R=jochen@chromium.org

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

git-svn-id: svn://svn.chromium.org/blink/trunk@168112 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Fix crash when resizing a view destroys the render tree

This is a simple fix for not holding a renderer across FrameView
resizes. Calling view->resize() can destroy renderers so this patch
updates SVGImage::setContainerSize to query the renderer after the
resize is complete. A similar issue does not exist for the dom tree
which is not destroyed.

BUG=344492

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

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