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

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 2826303003: Let selection events bypass ContentViewCore (Closed)
Patch Set: call Initialize() 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
Index: content/browser/android/content_view_core_impl.cc
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index b53f88c6e6b77162cbbf8c0b31e3a5760de7f35d..e2857755820f629e49edaba47a19644820b6805e 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -596,29 +596,6 @@ void ContentViewCoreImpl::RequestDisallowInterceptTouchEvent() {
Java_ContentViewCore_requestDisallowInterceptTouchEvent(env, obj);
}
-void ContentViewCoreImpl::OnSelectionChanged(const std::string& text) {
- JNIEnv* env = AttachCurrentThread();
- ScopedJavaLocalRef<jobject> obj = java_ref_.get(env);
- if (obj.is_null())
- return;
- ScopedJavaLocalRef<jstring> jtext = ConvertUTF8ToJavaString(env, text);
- Java_ContentViewCore_onSelectionChanged(env, obj, jtext);
-}
-
-void ContentViewCoreImpl::OnSelectionEvent(ui::SelectionEventType event,
- const gfx::PointF& selection_anchor,
- const gfx::RectF& selection_rect) {
- JNIEnv* env = AttachCurrentThread();
- ScopedJavaLocalRef<jobject> j_obj = java_ref_.get(env);
- if (j_obj.is_null())
- return;
-
- Java_ContentViewCore_onSelectionEvent(
- env, j_obj, event, selection_anchor.x(), selection_anchor.y(),
- selection_rect.x(), selection_rect.y(), selection_rect.right(),
- selection_rect.bottom());
-}
-
bool ContentViewCoreImpl::ShowPastePopup(const ContextMenuParams& params) {
// Display paste pop-up only when selection is empty and editable.
if (!(params.is_editable && params.selection_text.empty()))
« no previous file with comments | « content/browser/android/content_view_core_impl.h ('k') | content/browser/android/selection_popup_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698