OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #ifndef CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ |
7 | 7 |
8 #include <jni.h> | 8 #include <jni.h> |
9 | 9 |
10 #include "base/android/jni_helper.h" | 10 #include "base/android/jni_helper.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 void CommitText(JNIEnv*, jobject, jstring text); | 44 void CommitText(JNIEnv*, jobject, jstring text); |
45 void AttachImeAdapter(JNIEnv*, jobject java_object); | 45 void AttachImeAdapter(JNIEnv*, jobject java_object); |
46 void SetEditableSelectionOffsets(JNIEnv*, jobject, int start, int end); | 46 void SetEditableSelectionOffsets(JNIEnv*, jobject, int start, int end); |
47 void SetComposingRegion(JNIEnv*, jobject, int start, int end); | 47 void SetComposingRegion(JNIEnv*, jobject, int start, int end); |
48 void DeleteSurroundingText(JNIEnv*, jobject, int before, int after); | 48 void DeleteSurroundingText(JNIEnv*, jobject, int before, int after); |
49 void Unselect(JNIEnv*, jobject); | 49 void Unselect(JNIEnv*, jobject); |
50 void SelectAll(JNIEnv*, jobject); | 50 void SelectAll(JNIEnv*, jobject); |
51 void Cut(JNIEnv*, jobject); | 51 void Cut(JNIEnv*, jobject); |
52 void Copy(JNIEnv*, jobject); | 52 void Copy(JNIEnv*, jobject); |
53 void Paste(JNIEnv*, jobject); | 53 void Paste(JNIEnv*, jobject); |
| 54 void ResetImeAdapter(JNIEnv*, jobject); |
54 | 55 |
55 // Called from native -> java | 56 // Called from native -> java |
56 void CancelComposition(); | 57 void CancelComposition(); |
57 | 58 |
58 private: | 59 private: |
59 RenderWidgetHostViewAndroid* rwhva_; | 60 RenderWidgetHostViewAndroid* rwhva_; |
60 JavaObjectWeakGlobalRef java_ime_adapter_; | 61 JavaObjectWeakGlobalRef java_ime_adapter_; |
61 }; | 62 }; |
62 | 63 |
63 bool RegisterImeAdapter(JNIEnv* env); | 64 bool RegisterImeAdapter(JNIEnv* env); |
64 | 65 |
65 } // namespace content | 66 } // namespace content |
66 | 67 |
67 #endif // CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ | 68 #endif // CONTENT_BROWSER_RENDERER_HOST_IME_ADAPTER_ANDROID_H_ |
OLD | NEW |