summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorscottbyer@chromium.org <scottbyer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-18 22:49:44 +0000
committerscottbyer@chromium.org <scottbyer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-18 22:49:44 +0000
commitb798b0c0e7c85212a3ce415fc709b868c4025510 (patch)
tree890e0e20572aad4745070abc3c01f3e080156ff8 /chrome
parent791726222d9bdab836fe445d8b2009b731e34996 (diff)
downloadchromium_src-b798b0c0e7c85212a3ce415fc709b868c4025510.zip
chromium_src-b798b0c0e7c85212a3ce415fc709b868c4025510.tar.gz
chromium_src-b798b0c0e7c85212a3ce415fc709b868c4025510.tar.bz2
Cloud print options fix.
There seemed to be a timing issue on Mac and non-views Linux build that prevented the button handlers from being properly installed. By always installing the handlers and basing their behavior on the visibility of the ui instead, things work on all platforms. BUG=none TEST=Start up Mac Chromium with --enable-cloud-print-proxy, go to Under the Hood, and try to start cloud print - with this patch, the sign in UI will start. Review URL: http://codereview.chromium.org/6541027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75458 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/dom_ui/options/advanced_options_handler.cc6
-rw-r--r--chrome/browser/printing/cloud_print/cloud_print_setup_flow.cc6
-rw-r--r--chrome/browser/resources/options/advanced_options.js3
-rw-r--r--chrome/browser/resources/options/options.html3
-rw-r--r--chrome/browser/resources/options/options_page.css8
5 files changed, 8 insertions, 18 deletions
diff --git a/chrome/browser/dom_ui/options/advanced_options_handler.cc b/chrome/browser/dom_ui/options/advanced_options_handler.cc
index 79c687b..1d9152c 100644
--- a/chrome/browser/dom_ui/options/advanced_options_handler.cc
+++ b/chrome/browser/dom_ui/options/advanced_options_handler.cc
@@ -184,12 +184,6 @@ void AdvancedOptionsHandler::GetLocalizedValues(
localized_strings->SetString("privacyLearnMoreURL",
google_util::AppendGoogleLocaleParam(
GURL(chrome::kPrivacyLearnMoreURL)).spec());
-#if !defined(OS_CHROMEOS)
- // Add the cloud print proxy management ui section if it's been runtime
- // enabled.
- localized_strings->SetBoolean("enable-cloud-print-proxy",
- cloud_print_proxy_ui_enabled_);
-#endif
}
void AdvancedOptionsHandler::Initialize() {
diff --git a/chrome/browser/printing/cloud_print/cloud_print_setup_flow.cc b/chrome/browser/printing/cloud_print/cloud_print_setup_flow.cc
index 6fe624e..32a8d00 100644
--- a/chrome/browser/printing/cloud_print/cloud_print_setup_flow.cc
+++ b/chrome/browser/printing/cloud_print/cloud_print_setup_flow.cc
@@ -132,6 +132,12 @@ void CloudPrintSetupFlow::GetDialogSize(gfx::Size* size) const {
IDS_CLOUD_PRINT_SETUP_WIZARD_HEIGHT_LINES,
approximate_web_font);
}
+
+#if !defined(OS_WIN)
+ float scale_hack = 96.f/72.f;
+ size->set_width(size->width() * scale_hack);
+ size->set_height(size->height() * scale_hack);
+#endif
}
// A callback to notify the delegate that the dialog closed.
diff --git a/chrome/browser/resources/options/advanced_options.js b/chrome/browser/resources/options/advanced_options.js
index cefd902..19b7275 100644
--- a/chrome/browser/resources/options/advanced_options.js
+++ b/chrome/browser/resources/options/advanced_options.js
@@ -128,8 +128,7 @@ var OptionsPage = options.OptionsPage;
// 'cloudPrintProxyEnabled' is true for Chrome branded builds on
// certain platforms, or could be enabled by a lab.
- if (!cr.isChromeOS &&
- localStrings.getString('enable-cloud-print-proxy') == 'true') {
+ if (!cr.isChromeOS) {
$('cloudPrintProxySetupButton').onclick = function(event) {
if ($('cloudPrintProxyManageButton').style.display == 'none') {
// Disable the button, set it's text to the intermediate state.
diff --git a/chrome/browser/resources/options/options.html b/chrome/browser/resources/options/options.html
index 4658de9..529d4d7 100644
--- a/chrome/browser/resources/options/options.html
+++ b/chrome/browser/resources/options/options.html
@@ -1,7 +1,6 @@
<!DOCTYPE HTML>
<html
- i18n-values="dir:textdirection;
- enable-cloud-print-proxy:enable-cloud-print-proxy"
+ i18n-values="dir:textdirection"
id="t">
<head>
<meta charset="utf-8">
diff --git a/chrome/browser/resources/options/options_page.css b/chrome/browser/resources/options/options_page.css
index e3157d7..7f59a2b 100644
--- a/chrome/browser/resources/options/options_page.css
+++ b/chrome/browser/resources/options/options_page.css
@@ -597,14 +597,6 @@ html[enable-background-mode=false] #background-mode-section {
display: none;
}
-html[enable-cloud-print-proxy=false] #cloud-print-proxy-section {
- display: none;
-}
-
-html[enable-cloud-print-proxy=true] #cloudPrintProxyManageButton {
- display: none;
-}
-
/* UI Controls */
/* Currently we can't make custom focus outlines look right on the Mac, so