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

Side by Side Diff: base/android/jni_generator/testEagerCalledByNativesOption.golden

Issue 960873002: Update from https://crrev.com/318214 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // This file is autogenerated by 5 // This file is autogenerated by
6 // base/android/jni_generator/jni_generator.py 6 // base/android/jni_generator/jni_generator.py
7 // For 7 // For
8 // org/chromium/example/jni_generator/Test 8 // org/chromium/example/jni_generator/Test
9 9
10 #ifndef org_chromium_example_jni_generator_Test_JNI 10 #ifndef org_chromium_example_jni_generator_Test_JNI
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 static const JNINativeMethod kMethodsTest[] = { 72 static const JNINativeMethod kMethodsTest[] = {
73 { "nativeMethod", 73 { "nativeMethod",
74 "(" 74 "("
75 "J" 75 "J"
76 "I" 76 "I"
77 ")" 77 ")"
78 "I", reinterpret_cast<void*>(Method) }, 78 "I", reinterpret_cast<void*>(Method) },
79 }; 79 };
80 80
81 static bool RegisterNativesImpl(JNIEnv* env, jclass clazz) { 81 static bool RegisterNativesImpl(JNIEnv* env, jclass clazz) {
82
82 g_Test_clazz = static_cast<jclass>(env->NewWeakGlobalRef(clazz)); 83 g_Test_clazz = static_cast<jclass>(env->NewWeakGlobalRef(clazz));
83 84
84 const int kMethodsTestSize = arraysize(kMethodsTest); 85 const int kMethodsTestSize = arraysize(kMethodsTest);
85 86
86 if (env->RegisterNatives(Test_clazz(env), 87 if (env->RegisterNatives(Test_clazz(env),
87 kMethodsTest, 88 kMethodsTest,
88 kMethodsTestSize) < 0) { 89 kMethodsTestSize) < 0) {
89 jni_generator::HandleRegistrationError( 90 jni_generator::HandleRegistrationError(
90 env, Test_clazz(env), __FILE__); 91 env, Test_clazz(env), __FILE__);
91 return false; 92 return false;
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 return true; 137 return true;
137 } 138 }
138 139
139 extern "C" JNIEXPORT bool JNICALL 140 extern "C" JNIEXPORT bool JNICALL
140 Java_org_chromium_example_jni_generator_Test_nativeInitNativeClass(JNIEnv* env, 141 Java_org_chromium_example_jni_generator_Test_nativeInitNativeClass(JNIEnv* env,
141 jclass clazz) { 142 jclass clazz) {
142 return RegisterNativesImpl(env, clazz); 143 return RegisterNativesImpl(env, clazz);
143 } 144 }
144 145
145 #endif // org_chromium_example_jni_generator_Test_JNI 146 #endif // org_chromium_example_jni_generator_Test_JNI
OLDNEW
« no previous file with comments | « base/android/jni_generator/testConstantsFromJavaP.golden ('k') | base/android/jni_generator/testFromJavaP.golden » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698