[Android] Stop temporarily hiding selection handles
commit1ba4ec56cb8f8e76f5d0cd37db09ebe41129c9c8
authorjdduke <jdduke@chromium.org>
Tue, 11 Nov 2014 21:59:33 +0000 (11 13:59 -0800)
committerCommit bot <commit-bot@chromium.org>
Tue, 11 Nov 2014 22:00:03 +0000 (11 22:00 +0000)
treed32f517d8fe983798f3f0486ca5bff82862795a0
parenta460202e0ad883cf70bd787349df0a12170f3eab
[Android] Stop temporarily hiding selection handles

Previously, selection handles would be hidden when the content view
became unfocused. This approach worked fine in Chrome, where the focus
model is predictable, but led to undesirable consequences in WebView,
e.g., the handles never being shown. For now, avoid making any kind of
visibility changes to the handles when the focus changes, ensuring
handle visibility is consistent with the selection.

Also ensure timely cleanup of the PopupTouchHandleDrawable Java object
after its native counterpart has been destroyed.

BUG=430859
(internal b/18066784)

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

Cr-Commit-Position: refs/heads/master@{#303728}
content/browser/android/popup_touch_handle_drawable.cc
content/browser/renderer_host/input/touch_selection_controller.cc
content/browser/renderer_host/input/touch_selection_controller.h
content/browser/renderer_host/input/touch_selection_controller_unittest.cc
content/browser/renderer_host/render_widget_host_view_android.cc
content/public/android/java/src/org/chromium/content/browser/input/PopupTouchHandleDrawable.java