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

Unified Diff: chrome/browser/notifications/sync_notifier/synced_notification_app_info_service.cc

Issue 228753006: Reland r262272: "Hook up the Info URL from SyncedNotificationsAppInfo". (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed test on linux+aura, disabled on linux-gtk Created 6 years, 8 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/browser/notifications/sync_notifier/synced_notification_app_info_service.cc
diff --git a/chrome/browser/notifications/sync_notifier/synced_notification_app_info_service.cc b/chrome/browser/notifications/sync_notifier/synced_notification_app_info_service.cc
index 78abecc46703c4ca436c6d16a2fd6dab01530aad..9facf217a2a121a6996aca357d966beeaed30c63 100644
--- a/chrome/browser/notifications/sync_notifier/synced_notification_app_info_service.cc
+++ b/chrome/browser/notifications/sync_notifier/synced_notification_app_info_service.cc
@@ -245,6 +245,7 @@ SyncedNotificationAppInfoService::CreateSyncedNotificationAppInfoFromProtobuf(
if (server_app_info.has_settings_display_name()) {
display_name = server_app_info.settings_display_name();
}
+
scoped_ptr<SyncedNotificationAppInfo> app_info;
if (display_name.length() == 0)
return app_info.Pass();
@@ -252,6 +253,12 @@ SyncedNotificationAppInfoService::CreateSyncedNotificationAppInfoFromProtobuf(
// Create a new app info object based on the supplied protobuf.
app_info.reset(new SyncedNotificationAppInfo(profile_, display_name, this));
+ // This URL is used whenever the user clicks on the body of the app's welcome
+ // notification.
+ if (server_app_info.has_info_url()) {
+ app_info->SetWelcomeLinkUrl(GURL(server_app_info.info_url()));
+ }
+
// TODO(petewil): Eventually we will add the monochrome icon here, and we may
// need to fetch the correct url for the current DPI.
// Add the icon URL, if any.

Powered by Google App Engine
This is Rietveld 408576698