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

Unified Diff: base/android/jni_generator/testMultipleJNIAdditionalImport.golden

Issue 298973005: Updating JNIAdditionalImport to allow more than one import. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tests Created 6 years, 7 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: base/android/jni_generator/testMultipleJNIAdditionalImport.golden
diff --git a/base/android/jni_generator/testJNIAdditionalImport.golden b/base/android/jni_generator/testMultipleJNIAdditionalImport.golden
similarity index 88%
copy from base/android/jni_generator/testJNIAdditionalImport.golden
copy to base/android/jni_generator/testMultipleJNIAdditionalImport.golden
index e395657cf79bfc5b48642d54426b2d83a72c33c3..9cc1256cbfe2b8c90b6021ab77be332d0c9c5479 100644
--- a/base/android/jni_generator/testJNIAdditionalImport.golden
+++ b/base/android/jni_generator/testMultipleJNIAdditionalImport.golden
@@ -25,12 +25,14 @@ jclass g_Foo_clazz = NULL;
} // namespace
static void DoSomething(JNIEnv* env, jclass jcaller,
- jobject callback);
+ jobject callback1,
+ jobject callback2);
// Step 2: method stubs.
static base::subtle::AtomicWord g_Foo_calledByNative = 0;
-static void Java_Foo_calledByNative(JNIEnv* env, jobject callback) {
+static void Java_Foo_calledByNative(JNIEnv* env, jobject callback1,
+ jobject callback2) {
/* Must call RegisterNativesImpl() */
CHECK_CLAZZ(env, g_Foo_clazz,
g_Foo_clazz);
@@ -41,13 +43,14 @@ static void Java_Foo_calledByNative(JNIEnv* env, jobject callback) {
"calledByNative",
"("
-"Lorg/chromium/foo/Bar$Callback;"
+"Lorg/chromium/foo/Bar1$Callback;"
+"Lorg/chromium/foo/Bar2$Callback;"
")"
"V",
&g_Foo_calledByNative);
env->CallStaticVoidMethod(g_Foo_clazz,
- method_id, callback);
+ method_id, callback1, callback2);
jni_generator::CheckException(env);
}
@@ -57,7 +60,8 @@ static void Java_Foo_calledByNative(JNIEnv* env, jobject callback) {
static const JNINativeMethod kMethodsFoo[] = {
{ "nativeDoSomething",
"("
-"Lorg/chromium/foo/Bar$Callback;"
+"Lorg/chromium/foo/Bar1$Callback;"
+"Lorg/chromium/foo/Bar2$Callback;"
")"
"V", reinterpret_cast<void*>(DoSomething) },
};

Powered by Google App Engine
This is Rietveld 408576698