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

Unified Diff: chrome/browser/android/shortcut_info.cc

Issue 1220813010: Add UMA metrics to track the source of homescreen icons on launch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing reviewer comments Created 5 years, 5 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
« no previous file with comments | « chrome/browser/android/shortcut_info.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/shortcut_info.cc
diff --git a/chrome/browser/android/shortcut_info.cc b/chrome/browser/android/shortcut_info.cc
index 24406b889b509c0ea2166e59a1eb8abb2dc9977f..67e0c5549c344667fdc39db4fc854bd8da65ea7d 100644
--- a/chrome/browser/android/shortcut_info.cc
+++ b/chrome/browser/android/shortcut_info.cc
@@ -6,13 +6,15 @@
ShortcutInfo::ShortcutInfo()
: display(content::Manifest::DISPLAY_MODE_BROWSER),
- orientation(blink::WebScreenOrientationLockDefault) {
+ orientation(blink::WebScreenOrientationLockDefault),
+ source(SOURCE_ADD_TO_HOMESCREEN) {
}
ShortcutInfo::ShortcutInfo(const GURL& shortcut_url)
: url(shortcut_url),
display(content::Manifest::DISPLAY_MODE_BROWSER),
- orientation(blink::WebScreenOrientationLockDefault) {
+ orientation(blink::WebScreenOrientationLockDefault),
+ source(SOURCE_ADD_TO_HOMESCREEN) {
}
void ShortcutInfo::UpdateFromManifest(const content::Manifest& manifest) {
@@ -45,3 +47,7 @@ void ShortcutInfo::UpdateFromManifest(const content::Manifest& manifest) {
orientation = manifest.orientation;
}
}
+
+void ShortcutInfo::UpdateSource(const Source new_source) {
+ source = new_source;
+}
« no previous file with comments | « chrome/browser/android/shortcut_info.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698