Chromium Code Reviews| Index: content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java |
| diff --git a/content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java b/content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java |
| index 6493e4abb98f9cef067f2f883888a7c320db3d72..3067b1131e5ca7f979d0a186050f300ecbb2e7fa 100644 |
| --- a/content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java |
| +++ b/content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java |
| @@ -927,7 +927,8 @@ public class SelectionPopupController extends ActionModeCallbackHelper { |
| mSelectionRect.set(left, top, right, bottom); |
| mHasSelection = true; |
| mUnselectAllOnDismiss = true; |
| - if (mSelectionClient == null || !mSelectionClient.sendsSelectionPopupUpdates()) { |
| + if (mSelectionClient == null |
|
Tima Vaisburd
2017/05/05 01:57:06
Nice, I think another option to think of would be
boliu
2017/05/05 02:11:50
true /* suggest */ is good enough for me. I mean d
Tima Vaisburd
2017/05/05 16:54:41
It is absolutely unrelated to this particular CL b
amaralp
2017/05/05 21:18:31
Do you know if Android has already implemented the
|
| + || !mSelectionClient.requestSelectionPopupUpdates(true)) { |
| showActionModeOrClearOnFailure(); |
| } else { |
| // Rely on |mSelectionClient| sending a classification request and the request |
| @@ -949,6 +950,7 @@ public class SelectionPopupController extends ActionModeCallbackHelper { |
| mHasSelection = false; |
| mUnselectAllOnDismiss = false; |
| mSelectionRect.setEmpty(); |
| + if (mSelectionClient != null) mSelectionClient.cancelAllRequests(); |
| finishActionMode(); |
| break; |
| @@ -957,7 +959,8 @@ public class SelectionPopupController extends ActionModeCallbackHelper { |
| break; |
| case SelectionEventType.SELECTION_HANDLE_DRAG_STOPPED: |
| - if (mSelectionClient == null || !mSelectionClient.sendsSelectionPopupUpdates()) { |
| + if (mSelectionClient == null |
| + || !mSelectionClient.requestSelectionPopupUpdates(false)) { |
| hideActionMode(false); |
| } |
| // Otherwise rely on |mSelectionClient| sending a classification request and the |