summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsail@chromium.org <sail@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-06 19:20:38 +0000
committersail@chromium.org <sail@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-06 19:20:38 +0000
commit7bc551f6363486b7ea6f004d1404304f7f69a7e0 (patch)
tree91a1cee303086fffc1e65cd198d4c77b45da9d6e
parent98acd3ac8060ad1f7e46170189040a1db2c42a3f (diff)
downloadchromium_src-7bc551f6363486b7ea6f004d1404304f7f69a7e0.zip
chromium_src-7bc551f6363486b7ea6f004d1404304f7f69a7e0.tar.gz
chromium_src-7bc551f6363486b7ea6f004d1404304f7f69a7e0.tar.bz2
Sync Promo: Fix few issues in configure pane
The configure pane of the sync promo was missing a few strings. It also had the wrong background color. BUG=98923 TEST= Review URL: http://codereview.chromium.org/8163009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104344 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/resources/sync_promo.css1
-rw-r--r--chrome/browser/resources/sync_promo.js2
-rw-r--r--chrome/browser/ui/webui/options/core_options_handler.cc5
-rw-r--r--chrome/browser/ui/webui/options/core_options_handler.h4
-rw-r--r--chrome/browser/ui/webui/sync_promo_ui.cc2
5 files changed, 14 insertions, 0 deletions
diff --git a/chrome/browser/resources/sync_promo.css b/chrome/browser/resources/sync_promo.css
index 244c3ce..9404bca 100644
--- a/chrome/browser/resources/sync_promo.css
+++ b/chrome/browser/resources/sync_promo.css
@@ -25,6 +25,7 @@ body {
}
#sync-setup-configure {
+ background-color: transparent;
margin-left: auto;
margin-right: auto;
width: 600px;
diff --git a/chrome/browser/resources/sync_promo.js b/chrome/browser/resources/sync_promo.js
index 7fff29b..f651288 100644
--- a/chrome/browser/resources/sync_promo.js
+++ b/chrome/browser/resources/sync_promo.js
@@ -30,6 +30,8 @@ cr.define('sync_promo', function() {
// Initializes the page.
initializePage: function() {
+ localStrings = new LocalStrings();
+
options.SyncSetupOverlay.prototype.initializePage.call(this);
// Hide parts of the login UI and show the promo UI.
diff --git a/chrome/browser/ui/webui/options/core_options_handler.cc b/chrome/browser/ui/webui/options/core_options_handler.cc
index ac5b872..a63da16 100644
--- a/chrome/browser/ui/webui/options/core_options_handler.cc
+++ b/chrome/browser/ui/webui/options/core_options_handler.cc
@@ -71,6 +71,11 @@ void CoreOptionsHandler::Initialize() {
void CoreOptionsHandler::GetLocalizedValues(
DictionaryValue* localized_strings) {
+ GetStaticLocalizedValues(localized_strings);
+}
+
+void CoreOptionsHandler::GetStaticLocalizedValues(
+ base::DictionaryValue* localized_strings) {
DCHECK(localized_strings);
// Main
localized_strings->SetString("title",
diff --git a/chrome/browser/ui/webui/options/core_options_handler.h b/chrome/browser/ui/webui/options/core_options_handler.h
index 24f76b2..bfd8895 100644
--- a/chrome/browser/ui/webui/options/core_options_handler.h
+++ b/chrome/browser/ui/webui/options/core_options_handler.h
@@ -39,6 +39,10 @@ class CoreOptionsHandler : public OptionsPageUIHandler {
handlers_host_ = handlers_host;
}
+ // Adds localized strings to |localized_strings|.
+ static void GetStaticLocalizedValues(
+ base::DictionaryValue* localized_strings);
+
protected:
// Fetches a pref value of given |pref_name|.
// Note that caller owns the returned Value.
diff --git a/chrome/browser/ui/webui/sync_promo_ui.cc b/chrome/browser/ui/webui/sync_promo_ui.cc
index 59c05d42..13a5a44 100644
--- a/chrome/browser/ui/webui/sync_promo_ui.cc
+++ b/chrome/browser/ui/webui/sync_promo_ui.cc
@@ -12,6 +12,7 @@
#include "chrome/browser/sync/profile_sync_service.h"
#include "chrome/browser/ui/webui/chrome_url_data_manager.h"
#include "chrome/browser/ui/webui/chrome_web_ui_data_source.h"
+#include "chrome/browser/ui/webui/options/core_options_handler.h"
#include "chrome/browser/ui/webui/sync_promo_handler.h"
#include "chrome/browser/ui/webui/theme_source.h"
#include "chrome/common/chrome_switches.h"
@@ -51,6 +52,7 @@ class SyncPromoUIHTMLSource : public ChromeWebUIDataSource {
SyncPromoUIHTMLSource::SyncPromoUIHTMLSource()
: ChromeWebUIDataSource(chrome::kChromeUISyncPromoHost) {
DictionaryValue localized_strings;
+ CoreOptionsHandler::GetStaticLocalizedValues(&localized_strings);
SyncSetupHandler::GetStaticLocalizedValues(&localized_strings);
AddLocalizedStrings(localized_strings);
}