[Android] Ensure popups hidden when ContentViewCore destroyed
commit97e4b8c47fb7c21054b9471ab24a2be65639ab5e
authorjdduke <jdduke@chromium.org>
Thu, 13 Aug 2015 16:08:40 +0000 (13 09:08 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 13 Aug 2015 16:09:44 +0000 (13 16:09 +0000)
tree2bcfab0be8923b5fbe80582c4fb218265070d456
parente8f88c43760c9542c83e86f2b6815ba189b49ed4
[Android] Ensure popups hidden when ContentViewCore destroyed

Selection-related popups rely on objects (PopupWindows) that may outlive
the ContentViewCore. Prevent actions on such popups after the
ContentViewCore is destroyed by always explicitly hiding and dismissing
them upon ContentViewCore destruction.

BUG=520286

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

Cr-Commit-Position: refs/heads/master@{#343208}
content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
content/public/android/javatests/src/org/chromium/content/browser/ContentViewCoreSelectionTest.java