Index: components/url_formatter/android/component_jni_registrar.cc |
diff --git a/components/url_formatter/android/component_jni_registrar.cc b/components/url_formatter/android/component_jni_registrar.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..0829460cd2430cb13923622469dc442c898c5a79 |
--- /dev/null |
+++ b/components/url_formatter/android/component_jni_registrar.cc |
@@ -0,0 +1,27 @@ |
+// Copyright 2016 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#include "components/url_formatter/android/component_jni_registrar.h" |
+ |
+#include "base/android/jni_android.h" |
+#include "base/android/jni_registrar.h" |
+#include "components/url_formatter/url_formatter_android.h" |
+ |
+namespace url_formatter { |
+ |
+namespace android { |
+ |
+static base::android::RegistrationMethod kUrlFormatterRegisteredMethods[] = { |
Peter Kasting
2016/07/01 06:59:33
Nit: Declare this inside the function below to kee
|
+ {"UrlFormatter", url_formatter::android::RegisterUrlFormatter}, |
+}; |
+ |
+bool RegisterUrlFormatter(JNIEnv* env) { |
+ return base::android::RegisterNativeMethods( |
+ env, kUrlFormatterRegisteredMethods, |
+ arraysize(kUrlFormatterRegisteredMethods)); |
+} |
+ |
+} // namespace android |
+ |
+} // namespace url_formatter |