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

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

Issue 7647001: ntp4: attribution tweak (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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/resources/ntp4/new_tab.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/ntp/ntp_resource_cache.cc
diff --git a/chrome/browser/ui/webui/ntp/ntp_resource_cache.cc b/chrome/browser/ui/webui/ntp/ntp_resource_cache.cc
index 330abd805cb7c87faeac71cd072b3064e3f68850..cd40cb6e99628383277e6aa7ab37db0ac367c5df 100644
--- a/chrome/browser/ui/webui/ntp/ntp_resource_cache.cc
+++ b/chrome/browser/ui/webui/ntp/ntp_resource_cache.cc
@@ -385,6 +385,12 @@ void NTPResourceCache::CreateNewTabHTML() {
ui::Animation::ShouldRenderRichAnimation() ? "true" : "false";
localized_strings.SetString("anim", anim);
+ int alignment;
+ ui::ThemeProvider* tp = ThemeServiceFactory::GetForProfile(profile_);
+ tp->GetDisplayProperty(ThemeService::NTP_BACKGROUND_ALIGNMENT, &alignment);
+ if (alignment & ThemeService::ALIGN_RIGHT)
+ localized_strings.SetString("themegravity", "right");
+
// Pass the shown_sections pref early so that we can prevent flicker.
const int shown_sections = ShownSectionsHandler::GetShownSections(
profile_->GetPrefs());
« no previous file with comments | « chrome/browser/resources/ntp4/new_tab.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698