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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java

Issue 1956403002: Re-submit of AppLink implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Lock it and throw away the key Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java b/chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java
index a29af93745e6625603822f58e3c545132bf0d48e..203f773f2e8fd791396bfd4e82d53c88e2f18362 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/metrics/LaunchMetrics.java
@@ -9,6 +9,8 @@ import android.util.Pair;
import org.chromium.base.annotations.JNINamespace;
import org.chromium.base.metrics.RecordHistogram;
import org.chromium.base.metrics.RecordUserAction;
+import org.chromium.chrome.browser.AppLinkHandler;
+import org.chromium.chrome.browser.ChromeApplication;
import org.chromium.content_public.browser.WebContents;
import java.util.ArrayList;
@@ -167,8 +169,9 @@ public class LaunchMetrics {
* This intermediate step is necessary because Activity.onCreate() may be called when
* the native library has not yet been loaded.
* @param webContents WebContents for the current Tab.
+ * @param application The ChromeApplication object.
*/
- public static void commitLaunchMetrics(WebContents webContents) {
+ public static void commitLaunchMetrics(WebContents webContents, ChromeApplication application) {
for (Pair<String, Integer> item : sActivityUrls) {
nativeRecordLaunch(true, item.first, item.second, webContents);
}
@@ -185,6 +188,8 @@ public class LaunchMetrics {
}
sWebappHistogramTimes.clear();
+ AppLinkHandler.getInstance(application).commitMetrics();
+
// Record generic cached events.
for (CachedHistogram event : CachedHistogram.sEvents) event.commitAndClear();
}

Powered by Google App Engine
This is Rietveld 408576698