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

Side by Side Diff: content/browser/android/content_view_core_impl.cc

Issue 2309983002: Allow selection change update before beginBatchEdit (Closed)
Patch Set: fixed a test failure Created 4 years, 2 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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 #include "content/browser/android/content_view_core_impl.h" 5 #include "content/browser/android/content_view_core_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/jni_array.h" 10 #include "base/android/jni_array.h"
(...skipping 1282 matching lines...) Expand 10 before | Expand all | Expand 10 after
1293 1293
1294 void ContentViewCoreImpl::UpdateImeAdapter(long native_ime_adapter, 1294 void ContentViewCoreImpl::UpdateImeAdapter(long native_ime_adapter,
1295 int text_input_type, 1295 int text_input_type,
1296 int text_input_flags, 1296 int text_input_flags,
1297 const std::string& text, 1297 const std::string& text,
1298 int selection_start, 1298 int selection_start,
1299 int selection_end, 1299 int selection_end,
1300 int composition_start, 1300 int composition_start,
1301 int composition_end, 1301 int composition_end,
1302 bool show_ime_if_needed, 1302 bool show_ime_if_needed,
1303 bool is_non_ime_change) { 1303 bool is_non_ime_change,
1304 bool in_batch_edit_mode) {
1304 JNIEnv* env = AttachCurrentThread(); 1305 JNIEnv* env = AttachCurrentThread();
1305 ScopedJavaLocalRef<jobject> obj = java_ref_.get(env); 1306 ScopedJavaLocalRef<jobject> obj = java_ref_.get(env);
1306 if (obj.is_null()) 1307 if (obj.is_null())
1307 return; 1308 return;
1308 1309
1309 ScopedJavaLocalRef<jstring> jstring_text = ConvertUTF8ToJavaString(env, text); 1310 ScopedJavaLocalRef<jstring> jstring_text = ConvertUTF8ToJavaString(env, text);
1310 Java_ContentViewCore_updateImeAdapter( 1311 Java_ContentViewCore_updateImeAdapter(
1311 env, obj, native_ime_adapter, text_input_type, text_input_flags, 1312 env, obj, native_ime_adapter, text_input_type, text_input_flags,
1312 jstring_text, selection_start, selection_end, composition_start, 1313 jstring_text, selection_start, selection_end, composition_start,
1313 composition_end, show_ime_if_needed, is_non_ime_change); 1314 composition_end, show_ime_if_needed, is_non_ime_change,
1315 in_batch_edit_mode);
1314 } 1316 }
1315 1317
1316 void ContentViewCoreImpl::SetAccessibilityEnabled( 1318 void ContentViewCoreImpl::SetAccessibilityEnabled(
1317 JNIEnv* env, 1319 JNIEnv* env,
1318 const JavaParamRef<jobject>& obj, 1320 const JavaParamRef<jobject>& obj,
1319 bool enabled) { 1321 bool enabled) {
1320 SetAccessibilityEnabledInternal(enabled); 1322 SetAccessibilityEnabledInternal(enabled);
1321 } 1323 }
1322 1324
1323 void ContentViewCoreImpl::SetTextTrackSettings( 1325 void ContentViewCoreImpl::SetTextTrackSettings(
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after
1601 return ScopedJavaLocalRef<jobject>(); 1603 return ScopedJavaLocalRef<jobject>();
1602 1604
1603 return view->GetJavaObject(); 1605 return view->GetJavaObject();
1604 } 1606 }
1605 1607
1606 bool RegisterContentViewCore(JNIEnv* env) { 1608 bool RegisterContentViewCore(JNIEnv* env) {
1607 return RegisterNativesImpl(env); 1609 return RegisterNativesImpl(env);
1608 } 1610 }
1609 1611
1610 } // namespace content 1612 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/android/content_view_core_impl.h ('k') | content/browser/renderer_host/ime_adapter_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698