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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java

Issue 2853393003: [TTS] Fix flaky second-tap on tap-selection. (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java
index c598fa1ac28b2593a9f65883b24daa13003f9bd6..c913693d0898f6f56beaa2554e582805ab10e28f 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateController.java
@@ -293,7 +293,12 @@ class ContextualSearchInternalStateController {
reset(StateChangeReason.BASE_PAGE_TAP);
break;
case TAP_RECOGNIZED:
- transitionTo(InternalState.GATHERING_SURROUNDINGS);
+ if (mPreviousState == InternalState.SHOWING_TAP_SEARCH) {
+ // This is a second-tap on a Tap-selection.
+ // We'll soon recognize a Long-press and show the edit pins, so nothing needed.
+ } else {
+ transitionTo(InternalState.GATHERING_SURROUNDINGS);
+ }
break;
case GATHERING_SURROUNDINGS:
// We gather surroundings for both Tap and Long-press in order to notify icing.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698