Index: components/gcm_driver/gcm_driver_android.cc |
diff --git a/components/gcm_driver/gcm_driver_android.cc b/components/gcm_driver/gcm_driver_android.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..c540b48c38958a765930cb0ccea1866ebac52569 |
--- /dev/null |
+++ b/components/gcm_driver/gcm_driver_android.cc |
@@ -0,0 +1,24 @@ |
+// Copyright 2014 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/gcm_driver/gcm_driver_android.h" |
+ |
+#include "base/android/jni_android.h" |
+#include "jni/GCMDriver_jni.h" |
+ |
+namespace gcm { |
+ |
+// Prevents Java_GCMDriver_doNothing from being considered unused. |
+// TODO(johnme): Replace this with something useful. |
+void doNothing() { |
bulach
2014/05/15 17:49:09
nit: s/do/Do/
also, unindent below.
how come it's
johnme
2014/05/15 19:29:42
Done - I now forward declare it with ALLOW_UNUSED
|
+ JNIEnv* env = base::android::AttachCurrentThread(); |
+ gcm::Java_GCMDriver_doNothing(env); |
+} |
+ |
+// static |
+bool GCMDriverAndroid::RegisterBindings(JNIEnv* env) { |
+ return RegisterNativesImpl(env); |
+} |
+ |
+} // namespace gcm |