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

Unified Diff: chrome/browser/ui/webui/ntp/ntp_resource_cache.cc

Issue 10911196: Support for ntp promo bubble. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: allow BR in parseHtmlSubset Created 8 years, 3 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/ui/webui/ntp/ntp_resource_cache.cc
===================================================================
--- chrome/browser/ui/webui/ntp/ntp_resource_cache.cc (revision 155564)
+++ chrome/browser/ui/webui/ntp/ntp_resource_cache.cc (working copy)
@@ -421,8 +421,19 @@
} else {
NotificationPromo notification_promo(profile_);
notification_promo.InitFromPrefs(NotificationPromo::NTP_NOTIFICATION_PROMO);
- if (notification_promo.CanShow())
- load_time_data.SetString("serverpromo", notification_promo.promo_text());
+ if (notification_promo.CanShow()) {
+ load_time_data.SetString("notificationPromoText",
+ notification_promo.promo_text());
+ DVLOG(1) << "Notification promo:" << notification_promo.promo_text();
+ }
+
+ NotificationPromo bubble_promo(profile_);
+ bubble_promo.InitFromPrefs(NotificationPromo::NTP_BUBBLE_PROMO);
+ if (bubble_promo.CanShow()) {
+ load_time_data.SetString("bubblePromoText",
+ bubble_promo.promo_text());
+ DVLOG(1) << "Bubble promo:" << bubble_promo.promo_text();
+ }
}
// Determine whether to show the menu for accessing tabs on other devices.
« no previous file with comments | « chrome/browser/ui/webui/ntp/new_tab_page_handler.cc ('k') | chrome/browser/web_resource/notification_promo.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698