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

Side by Side Diff: content/public/android/java/src/org/chromium/content/browser/SelectionPopupController.java

Issue 2703643004: [TTS] Add an ACK message to SelectWordAroundCaret. (Closed)
Patch Set: Changed to send the message on all platforms, not just Android. Created 3 years, 10 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.content.browser; 5 package org.chromium.content.browser;
6 6
7 import android.annotation.TargetApi; 7 import android.annotation.TargetApi;
8 import android.app.Activity; 8 import android.app.Activity;
9 import android.app.SearchManager; 9 import android.app.SearchManager;
10 import android.content.ClipboardManager; 10 import android.content.ClipboardManager;
(...skipping 851 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 void setContextualSearchClient(ContextualSearchClient contextualSearchClient ) { 862 void setContextualSearchClient(ContextualSearchClient contextualSearchClient ) {
863 mContextualSearchClient = contextualSearchClient; 863 mContextualSearchClient = contextualSearchClient;
864 } 864 }
865 865
866 void onShowUnhandledTapUIIfNeeded(int x, int y) { 866 void onShowUnhandledTapUIIfNeeded(int x, int y) {
867 if (mContextualSearchClient != null) { 867 if (mContextualSearchClient != null) {
868 mContextualSearchClient.showUnhandledTapUIIfNeeded(x, y); 868 mContextualSearchClient.showUnhandledTapUIIfNeeded(x, y);
869 } 869 }
870 } 870 }
871 871
872 void onSelectWordAroundCaretAck(boolean didSelect, int startAdjust, int endA djust) {
873 if (mContextualSearchClient != null) {
874 mContextualSearchClient.selectWordAroundCaretAck(didSelect, startAdj ust, endAdjust);
875 }
876 }
877
872 void destroyActionModeAndUnselect() { 878 void destroyActionModeAndUnselect() {
873 mUnselectAllOnDismiss = true; 879 mUnselectAllOnDismiss = true;
874 finishActionMode(); 880 finishActionMode();
875 } 881 }
876 882
877 void destroyActionModeAndKeepSelection() { 883 void destroyActionModeAndKeepSelection() {
878 mUnselectAllOnDismiss = false; 884 mUnselectAllOnDismiss = false;
879 finishActionMode(); 885 finishActionMode();
880 } 886 }
881 887
(...skipping 27 matching lines...) Expand all
909 mIsInsertion = insertion; 915 mIsInsertion = insertion;
910 } 916 }
911 917
912 private boolean isShareAvailable() { 918 private boolean isShareAvailable() {
913 Intent intent = new Intent(Intent.ACTION_SEND); 919 Intent intent = new Intent(Intent.ACTION_SEND);
914 intent.setType("text/plain"); 920 intent.setType("text/plain");
915 return mContext.getPackageManager().queryIntentActivities(intent, 921 return mContext.getPackageManager().queryIntentActivities(intent,
916 PackageManager.MATCH_DEFAULT_ONLY).size() > 0; 922 PackageManager.MATCH_DEFAULT_ONLY).size() > 0;
917 } 923 }
918 } 924 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698