|
Grant origins engagement for having interactions on their notifications.
This CL implements support for interactions on persistent (i.e.
ServiceWorker-based) notifications to generate site engagement. A new
engagement type and points bucket is added for notification
interactions.
In the future it would be better to have notification observers so the
site engagement service itself can directly observe notifications
without needing to expose HandleNotificationInteraction() publicly.
Several tests are added and extended to ensure that the correct
behaviour is exhibited on Android and desktop when users:
- click on a notification (increase engagement)
- click on an action button in a notification (increase engagement)
- click on the settings button (no action)
- close the notification (no action)
This CL also corrects some errors in histograms.xml as well as adding
the new engagement type.
BUG= 679336
Review-Url: https://codereview.chromium.org/2748103011
Cr-Commit-Position: refs/heads/master@{#458021}
Committed: https://chromium.googlesource.com/chromium/src/+/b8a53b39667bab5aa73c5526b33bfdb04ea5351b
Total comments: 1
Total comments: 8
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+268 lines, -46 lines) |
Patch |
|
M |
chrome/android/java/src/org/chromium/chrome/browser/engagement/SiteEngagementService.java
|
View
|
|
2 chunks |
+8 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/android/javatests/src/org/chromium/chrome/browser/notifications/NotificationPlatformBridgeTest.java
|
View
|
1
2
3
|
18 chunks |
+55 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_metrics.h
|
View
|
|
2 chunks |
+3 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_observer.h
|
View
|
|
1 chunk |
+4 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_score.h
|
View
|
|
4 chunks |
+9 lines, -10 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_score.cc
|
View
|
1
2
3
|
3 chunks |
+29 lines, -23 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_service.h
|
View
|
1
2
3
4
|
2 chunks |
+5 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_service.cc
|
View
|
1
2
3
4
|
4 chunks |
+20 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_service_android.cc
|
View
|
|
2 chunks |
+5 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/engagement/site_engagement_service_unittest.cc
|
View
|
|
3 chunks |
+55 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/notifications/platform_notification_service_impl.h
|
View
|
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/notifications/platform_notification_service_impl.cc
|
View
|
1
2
|
3 chunks |
+12 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/notifications/platform_notification_service_interactive_uitest.cc
|
View
|
|
16 chunks |
+56 lines, -2 lines |
0 comments
|
Download
|
|
M |
tools/metrics/histograms/histograms.xml
|
View
|
1
|
1 chunk |
+4 lines, -2 lines |
0 comments
|
Download
|
Total messages: 32 (23 generated)
|