Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(154)

Issue 516523003: [Android] Preserve selection on hide/detach (Closed)

Created:
6 years, 3 months ago by jdduke (slow)
Modified:
6 years, 3 months ago
CC:
aurimas (slooooooooow), chromium-reviews, darin-cc_chromium.org, jam, nona+watch_chromium.org, penghuang+watch_chromium.org, James Su, yukishiino+watch_chromium.org, yusukes+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

[Android] Preserve selection on hide/detach Previously, the selection was cleared and the handles dismissed if Chrome was backgrounded (via home or task switcher buttons) or the screen was locked. This breaks any kind of multitasking with an active selection. Instead, in such cases preserve the selection, hiding the action bar and restoring as necessary when the view is reattached or is reshown. Also expose a programmatic way for preserving the selection when the view loses focus, which is typically undesirable (tapping omnibox or switching tabs), but not always. BUG=406925 Committed: https://crrev.com/6a4d1490ab6b5146a3dedd469d49a52045ce9194 Cr-Commit-Position: refs/heads/master@{#294082}

Patch Set 1 #

Patch Set 2 : Fix detach/hide/blur #

Patch Set 3 : Tests #

Patch Set 4 : Experiments #

Patch Set 5 : Cleanup #

Patch Set 6 : Fix tests #

Patch Set 7 : Final fix #

Patch Set 8 : Add an explicit bit #

Total comments: 8

Patch Set 9 : Code review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+217 lines, -14 lines) Patch
M content/browser/renderer_host/render_widget_host_view_android.cc View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -1 line 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java View 1 2 3 4 5 6 7 8 12 chunks +49 lines, -13 lines 0 comments Download
A content/public/android/javatests/src/org/chromium/content/browser/ContentViewCoreSelectionTest.java View 1 2 3 4 5 6 7 8 1 chunk +168 lines, -0 lines 0 comments Download

Messages

Total messages: 25 (2 generated)
jdduke (slow)
jdduke@chromium.org changed reviewers: + ajith.v@samsung.com, pedrosimonetti@chromium.org
6 years, 3 months ago (2014-08-27 22:44:45 UTC) #1
jdduke (slow)
Pedro could you see if the latest version works for you? ajith.v@samsung.com: Will this work ...
6 years, 3 months ago (2014-08-27 22:44:45 UTC) #2
AKVT
On 2014/08/27 22:44:45, jdduke wrote: > Pedro could you see if the latest version works ...
6 years, 3 months ago (2014-08-28 14:16:57 UTC) #3
jdduke (slow)
Patchset #3 (id:40001) has been deleted
6 years, 3 months ago (2014-08-28 20:15:40 UTC) #4
jdduke (slow)
Patchset #3 (id:60001) has been deleted
6 years, 3 months ago (2014-08-28 20:15:45 UTC) #5
jdduke (slow)
jdduke@chromium.org changed reviewers: + aelias@chromium.org, tedchoc@chromium.org - ajith.v@samsung.com
6 years, 3 months ago (2014-08-28 20:16:43 UTC) #6
jdduke (slow)
tedcho@, aelias@: Do either of you have any thoughts on this behavior change? Do we ...
6 years, 3 months ago (2014-08-28 20:16:43 UTC) #7
Ted C
On 2014/08/28 20:16:43, jdduke wrote: > tedcho@, aelias@: Do either of you have any thoughts ...
6 years, 3 months ago (2014-08-28 20:23:35 UTC) #8
pedro (no code reviews)
On 2014/08/28 20:23:35, Ted C wrote: > On 2014/08/28 20:16:43, jdduke wrote: > > tedcho@, ...
6 years, 3 months ago (2014-08-28 22:52:55 UTC) #9
jdduke (slow)
aurimas@ brought up the fact that we should probably clear the selection if another selection ...
6 years, 3 months ago (2014-08-28 23:11:32 UTC) #10
Ted C
On 2014/08/28 23:11:32, jdduke wrote: > aurimas@ brought up the fact that we should probably ...
6 years, 3 months ago (2014-08-28 23:22:47 UTC) #11
jdduke (slow)
On 2014/08/28 23:22:47, Ted C wrote: > !windowFocus && focus == keep selection > windowFocus ...
6 years, 3 months ago (2014-08-29 16:20:05 UTC) #12
jdduke (slow)
Pedro: Could you verify that this will work for your purposes? Unfortunately, there's currently no ...
6 years, 3 months ago (2014-09-03 16:44:47 UTC) #13
pedro (no code reviews)
On 2014/09/03 16:44:47, jdduke wrote: > Pedro: Could you verify that this will work for ...
6 years, 3 months ago (2014-09-03 18:43:03 UTC) #14
jdduke (slow)
On 2014/09/03 18:43:03, pedrosimonetti wrote: > On 2014/09/03 16:44:47, jdduke wrote: > > Pedro: Could ...
6 years, 3 months ago (2014-09-03 18:46:00 UTC) #15
jdduke (slow)
tedchoc@: Could you take a look? This isn't exactly pretty, but it works well for ...
6 years, 3 months ago (2014-09-03 18:51:59 UTC) #16
jdduke (slow)
aelias@: Owner review for render_widget_host_view_android.cc? tedchoc@: Thoughts?
6 years, 3 months ago (2014-09-08 21:00:29 UTC) #17
aelias_OOO_until_Jul13
lgtm for RWHVA
6 years, 3 months ago (2014-09-08 22:56:17 UTC) #18
Ted C
lgtm (assuming the popups don't cause issue) and a few nits https://codereview.chromium.org/516523003/diff/200001/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java File content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java (right): ...
6 years, 3 months ago (2014-09-09 20:00:59 UTC) #19
jdduke (slow)
https://codereview.chromium.org/516523003/diff/200001/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java File content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java (right): https://codereview.chromium.org/516523003/diff/200001/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java#newcode1468 content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java:1468: if (mUnselectAllOnActionModeDismiss) hideTextHandles(); On 2014/09/09 20:00:59, Ted C wrote: ...
6 years, 3 months ago (2014-09-10 00:21:31 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/516523003/240001
6 years, 3 months ago (2014-09-10 00:30:10 UTC) #23
commit-bot: I haz the power
Committed patchset #9 (id:240001) as c889cefdf7886664b122f87bcd7b5f4e864795a3
6 years, 3 months ago (2014-09-10 02:44:24 UTC) #24
commit-bot: I haz the power
6 years, 3 months ago (2014-09-10 03:58:29 UTC) #25
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/6a4d1490ab6b5146a3dedd469d49a52045ce9194
Cr-Commit-Position: refs/heads/master@{#294082}

Powered by Google App Engine
This is Rietveld 408576698