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

Unified Diff: base/android/jni_local_ref_extensions.h

Issue 12282004: Added personal_data_manager android implementation for auto-populating auto-fill on android builds … (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed Nits Created 7 years, 9 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
« no previous file with comments | « no previous file | base/android/jni_local_ref_extensions.cc » ('j') | base/android/jni_local_ref_extensions.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/android/jni_local_ref_extensions.h
diff --git a/base/android/jni_local_ref_extensions.h b/base/android/jni_local_ref_extensions.h
new file mode 100644
index 0000000000000000000000000000000000000000..62c21904b29e49186e15d722dc09eb248285cb26
--- /dev/null
+++ b/base/android/jni_local_ref_extensions.h
@@ -0,0 +1,29 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
Ilya Sherman 2013/03/11 22:39:44 nit: Remove the (c)
apiccion 2013/03/13 20:17:28 Done.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef BASE_ANDROID_JNI_LOCAL_REF_EXTENSIONS_H_
+#define BASE_ANDROID_JNI_LOCAL_REF_EXTENSIONS_H_
+
+#include "base/android/jni_android.h"
+#include "base/android/jni_array.h"
+#include "base/android/jni_string.h"
+
+namespace base {
+namespace android {
+
+// Returns an empty string if java string is null,
+// otherwise converts and returns the string.
+string16 SafeJavaStringToUTF16(ScopedJavaLocalRef<jstring> jstring);
Ilya Sherman 2013/03/11 22:39:44 nit: Should this be passed by const-ref?
apiccion 2013/03/13 20:17:28 Done.
+
+// Fills |string_vector| with the contents of |jarray|.
+// If the Java array is null, then |string_vector| is not modified.
+void SafeJavaStringArrayToStringVector(
+ ScopedJavaLocalRef<jobjectArray> jarray,
Ilya Sherman 2013/03/11 22:39:44 nit: Should this be passed by const-ref?
apiccion 2013/03/13 20:17:28 Done.
+ JNIEnv* env,
+ std::vector<string16>* string_vector);
+
+} // namespace android
+} // namespace base
+
+#endif // BASE_ANDROID_JNI_LOCAL_REF_EXTENSIONS_H_
« no previous file with comments | « no previous file | base/android/jni_local_ref_extensions.cc » ('j') | base/android/jni_local_ref_extensions.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698