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

Side by Side Diff: base/android/jni_array.h

Issue 1589953005: Support InputMethodManager#updateCursorAnchorInfo for Android 5.0 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Findbugs warning / Simplify the state transition. Created 4 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
« no previous file with comments | « no previous file | base/android/jni_array.cc » ('j') | chrome/app/generated_resources.grd » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 BASE_ANDROID_JNI_ARRAY_H_ 5 #ifndef BASE_ANDROID_JNI_ARRAY_H_
6 #define BASE_ANDROID_JNI_ARRAY_H_ 6 #define BASE_ANDROID_JNI_ARRAY_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 #include <stddef.h> 9 #include <stddef.h>
10 #include <stdint.h> 10 #include <stdint.h>
(...skipping 24 matching lines...) Expand all
35 35
36 // Returns a new Java long array converted from the given int64_t array. 36 // Returns a new Java long array converted from the given int64_t array.
37 BASE_EXPORT ScopedJavaLocalRef<jlongArray> ToJavaLongArray(JNIEnv* env, 37 BASE_EXPORT ScopedJavaLocalRef<jlongArray> ToJavaLongArray(JNIEnv* env,
38 const int64_t* longs, 38 const int64_t* longs,
39 size_t len); 39 size_t len);
40 40
41 BASE_EXPORT ScopedJavaLocalRef<jlongArray> ToJavaLongArray( 41 BASE_EXPORT ScopedJavaLocalRef<jlongArray> ToJavaLongArray(
42 JNIEnv* env, 42 JNIEnv* env,
43 const std::vector<int64_t>& longs); 43 const std::vector<int64_t>& longs);
44 44
45 // Returns a new Java float array converted from the given C++ float array.
46 BASE_EXPORT ScopedJavaLocalRef<jfloatArray> ToJavaFloatArray(
47 JNIEnv* env, const float* floats, size_t len);
48
45 // Returns a array of Java byte array converted from |v|. 49 // Returns a array of Java byte array converted from |v|.
46 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfByteArray( 50 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfByteArray(
47 JNIEnv* env, const std::vector<std::string>& v); 51 JNIEnv* env, const std::vector<std::string>& v);
48 52
49 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfStrings( 53 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfStrings(
50 JNIEnv* env, const std::vector<std::string>& v); 54 JNIEnv* env, const std::vector<std::string>& v);
51 55
52 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfStrings( 56 BASE_EXPORT ScopedJavaLocalRef<jobjectArray> ToJavaArrayOfStrings(
53 JNIEnv* env, const std::vector<string16>& v); 57 JNIEnv* env, const std::vector<string16>& v);
54 58
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 // contents of |out| with the corresponding vectors of ints. 112 // contents of |out| with the corresponding vectors of ints.
109 BASE_EXPORT void JavaArrayOfIntArrayToIntVector( 113 BASE_EXPORT void JavaArrayOfIntArrayToIntVector(
110 JNIEnv* env, 114 JNIEnv* env,
111 jobjectArray array, 115 jobjectArray array,
112 std::vector<std::vector<int>>* out); 116 std::vector<std::vector<int>>* out);
113 117
114 } // namespace android 118 } // namespace android
115 } // namespace base 119 } // namespace base
116 120
117 #endif // BASE_ANDROID_JNI_ARRAY_H_ 121 #endif // BASE_ANDROID_JNI_ARRAY_H_
OLDNEW
« no previous file with comments | « no previous file | base/android/jni_array.cc » ('j') | chrome/app/generated_resources.grd » ('J')

Powered by Google App Engine
This is Rietveld 408576698