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 #include "android_webview/native/android_webview_jni_registrar.h" | 5 #include "android_webview/native/android_webview_jni_registrar.h" |
6 | 6 |
| 7 #include "android_webview/native/android_web_view_util.h" |
| 8 #include "android_webview/native/aw_contents.h" |
7 #include "base/android/jni_android.h" | 9 #include "base/android/jni_android.h" |
8 #include "base/android/jni_registrar.h" | 10 #include "base/android/jni_registrar.h" |
9 #include "chrome/browser/component/web_contents_delegate_android/component_jni_r
egistrar.h" | 11 #include "chrome/browser/component/web_contents_delegate_android/component_jni_r
egistrar.h" |
10 | 12 |
11 namespace android_webview { | 13 namespace android_webview { |
12 | 14 |
| 15 static base::android::RegistrationMethod kWebViewRegisteredMethods[] = { |
| 16 { "AndroidWebViewUtil", RegisterAndroidWebViewUtil }, |
| 17 { "AwContents", RegisterAwContents }, |
| 18 }; |
| 19 |
13 bool RegisterJni(JNIEnv* env) { | 20 bool RegisterJni(JNIEnv* env) { |
14 return web_contents_delegate_android::RegisterJni(env); | 21 if (!web_contents_delegate_android::RegisterJni(env)) |
| 22 return false; |
| 23 |
| 24 return RegisterNativeMethods(env, |
| 25 kWebViewRegisteredMethods, arraysize(kWebViewRegisteredMethods)); |
15 } | 26 } |
16 | 27 |
17 } // namespace android_webview | 28 } // namespace android_webview |
OLD | NEW |