| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/browser/android/uma_bridge.h" | 5 #include "chrome/browser/android/uma_bridge.h" |
| 6 | 6 |
| 7 #include <jni.h> | 7 #include <jni.h> |
| 8 | 8 |
| 9 #include "content/public/browser/user_metrics.h" | 9 #include "content/public/browser/user_metrics.h" |
| 10 #include "jni/UmaBridge_jni.h" | 10 #include "jni/UmaBridge_jni.h" |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 } | 29 } |
| 30 } else { | 30 } else { |
| 31 if (is_dragging) { | 31 if (is_dragging) { |
| 32 RecordAction(UserMetricsAction("MobileUsingMenuBySwButtonDragging")); | 32 RecordAction(UserMetricsAction("MobileUsingMenuBySwButtonDragging")); |
| 33 } else { | 33 } else { |
| 34 RecordAction(UserMetricsAction("MobileUsingMenuBySwButtonTap")); | 34 RecordAction(UserMetricsAction("MobileUsingMenuBySwButtonTap")); |
| 35 } | 35 } |
| 36 } | 36 } |
| 37 } | 37 } |
| 38 | 38 |
| 39 // Android Beam |
| 40 static void RecordBeamCallbackSuccess(JNIEnv*, jclass) { |
| 41 RecordAction(UserMetricsAction("MobileBeamCallbackSuccess")); |
| 42 } |
| 43 |
| 44 static void RecordBeamInvalidAppState(JNIEnv*, jclass) { |
| 45 RecordAction(UserMetricsAction("MobileBeamInvalidAppState")); |
| 46 } |
| 47 |
| 39 namespace chrome { | 48 namespace chrome { |
| 40 namespace android { | 49 namespace android { |
| 41 | 50 |
| 42 // Register native methods | 51 // Register native methods |
| 43 bool RegisterUmaBridge(JNIEnv* env) { | 52 bool RegisterUmaBridge(JNIEnv* env) { |
| 44 return RegisterNativesImpl(env); | 53 return RegisterNativesImpl(env); |
| 45 } | 54 } |
| 46 | 55 |
| 47 } // namespace android | 56 } // namespace android |
| 48 } // namespace chrome | 57 } // namespace chrome |
| OLD | NEW |