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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchInternalStateHandler.java

Issue 2703473002: [TTS] Extract tapped text before showing UI. (Closed)
Patch Set: Moved handleHideContextualSearch into hideContextualSearchUI, and updated comments in response to T… Created 3 years, 7 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 package org.chromium.chrome.browser.contextualsearch;
6
7 import org.chromium.chrome.browser.compositor.bottombar.OverlayPanel.StateChange Reason;
8
9 /**
10 * An interface for driving operations in the Contextual Search Manager's intern al state by the
11 * {@link ContextualSearchInternalStateController} class.
12 */
13 public interface ContextualSearchInternalStateHandler {
14 /**
15 * Hides the Contextual Search user interface.
16 * {@See ContextualSearchInternalStateController#InternalState#IDLE}.
17 */
18 void hideContextualSearchUi(StateChangeReason reason);
19
20 /**
21 * Shows the Contextual Search user interface for a Tap.
22 * {@See ContextualSearchInternalStateController#InternalState#SHOW_FULL_TAP _UI}.
23 */
24 void showContextualSearchTapUi();
25
26 /**
27 * Shows the Contextual Search user interface for a Long-press.
28 * {@See ContextualSearchInternalStateController#InternalState#SHOWING_LONGP RESS_SEARCH}.
29 */
30 void showContextualSearchLongpressUi();
31
32 /**
33 * Gathers text surrounding the current selection, which may have been creat ed by either a Tap
34 * or a Long-press gesture.
35 * {@See ContextualSearchInternalStateController#InternalState#GATHERING_SUR ROUNDINGS}.
36 */
37 void gatherSurroundingText();
38
39 /**
40 * Starts the process of deciding if we'll suppress the current gesture or n ot.
41 * {@See ContextualSearchInternalStateController#InternalState#DECIDING_SUPP RESSION}.
42 */
43 void decideSuppression();
44
45 /**
46 * Starts the process of selecting a word around the current caret.
47 * {@See ContextualSearchInternalStateController#InternalState#START_SHOWING _TAP_UI}.
48 */
49 void startShowingTapUi();
50
51 /**
52 * Waits to see if a Tap gesture will be made when a previous Tap was recogn ized.
53 * {@See
54 * ContextualSearchInternalStateController#InternalState#WAITING_FOR_POSSIBL E_TAP_NEAR_PREVIOUS}
55 */
56 void waitForPossibleTapNearPrevious();
57
58 /**
59 * Starts a Resolve request to our server for the best Search Term.
60 * {@See ContextualSearchInternalStateController#InternalState#RESOLVING}.
61 */
62 void resolveSearchTerm();
63 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698