Make empty selection behavior behave like Android EditText.

1) When long-pressing a whitespace region in text field, the Android
convention is to select zero characters and show an insertion handle (as
opposed to the current behavior of selecting some whitespace and showing
two selection handles).  One important consequence of this is that
insertion handles only show a "Paste" menu item, instead of the full
suite of Cut/Copy/etc.  I just needed to remove the unnecessary
exclusion of editable nodes on the preexisting logic.

2) When single-tapping elsewhere, Paste popups should be cleared along
with the insertion handle.  Otherwise the paste menu keeps following the cursor
around and is difficult to get rid of.  This is a preexisting bug made
much more common by change 1.

3) When the insertion handle is dragged, I noticed EditText brings back
the Paste menu, so also add a few lines of code to do that.  (Some state
was already kept to support the "tap the handle to hide Paste/tap it again
to show Paste" behavior, so I just reused that.)

BUG=582628

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

Cr-Commit-Position: refs/heads/master@{#373606}
4 files changed