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

Side by Side Diff: chrome/browser/ui/webui/options/browser_options_handler.cc

Issue 263803007: Make some l10n values on Options independent from ENABLE_FULL_PRINTING. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase onto latest LKGR Created 6 years, 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/webui/options/browser_options_handler.h" 5 #include "chrome/browser/ui/webui/options/browser_options_handler.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "apps/app_window.h" 10 #include "apps/app_window.h"
(...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after
603 chromeos::GetChromeDeviceType())); 603 chromeos::GetChromeDeviceType()));
604 604
605 values->SetBoolean( 605 values->SetBoolean(
606 "consumerManagementEnabled", 606 "consumerManagementEnabled",
607 CommandLine::ForCurrentProcess()->HasSwitch( 607 CommandLine::ForCurrentProcess()->HasSwitch(
608 chromeos::switches::kEnableConsumerManagement)); 608 chromeos::switches::kEnableConsumerManagement));
609 609
610 RegisterTitle(values, "thirdPartyImeConfirmOverlay", 610 RegisterTitle(values, "thirdPartyImeConfirmOverlay",
611 IDS_OPTIONS_SETTINGS_LANGUAGES_THIRD_PARTY_WARNING_TITLE); 611 IDS_OPTIONS_SETTINGS_LANGUAGES_THIRD_PARTY_WARNING_TITLE);
612 #endif 612 #endif
613
614 values->SetBoolean("showSetDefault", ShouldShowSetDefaultBrowser());
615
616 values->SetBoolean("allowAdvancedSettings", ShouldAllowAdvancedSettings());
613 } 617 }
614 618
615 #if defined(ENABLE_FULL_PRINTING) 619 #if defined(ENABLE_FULL_PRINTING)
616 void BrowserOptionsHandler::RegisterCloudPrintValues( 620 void BrowserOptionsHandler::RegisterCloudPrintValues(
617 base::DictionaryValue* values) { 621 base::DictionaryValue* values) {
618 values->SetString("cloudPrintOptionLabel", 622 values->SetString("cloudPrintOptionLabel",
619 l10n_util::GetStringFUTF16( 623 l10n_util::GetStringFUTF16(
620 IDS_CLOUD_PRINT_CHROMEOS_OPTION_LABEL, 624 IDS_CLOUD_PRINT_CHROMEOS_OPTION_LABEL,
621 l10n_util::GetStringUTF16(IDS_GOOGLE_CLOUD_PRINT))); 625 l10n_util::GetStringUTF16(IDS_GOOGLE_CLOUD_PRINT)));
622
623 values->SetBoolean("showSetDefault", ShouldShowSetDefaultBrowser());
624 values->SetBoolean("allowAdvancedSettings", ShouldAllowAdvancedSettings());
625 } 626 }
626 #endif // defined(ENABLE_FULL_PRINTING) 627 #endif // defined(ENABLE_FULL_PRINTING)
627 628
628 void BrowserOptionsHandler::RegisterMessages() { 629 void BrowserOptionsHandler::RegisterMessages() {
629 web_ui()->RegisterMessageCallback( 630 web_ui()->RegisterMessageCallback(
630 "becomeDefaultBrowser", 631 "becomeDefaultBrowser",
631 base::Bind(&BrowserOptionsHandler::BecomeDefaultBrowser, 632 base::Bind(&BrowserOptionsHandler::BecomeDefaultBrowser,
632 base::Unretained(this))); 633 base::Unretained(this)));
633 web_ui()->RegisterMessageCallback( 634 web_ui()->RegisterMessageCallback(
634 "setDefaultSearchEngine", 635 "setDefaultSearchEngine",
(...skipping 1162 matching lines...) Expand 10 before | Expand all | Expand 10 after
1797 extension = extensions::GetExtensionOverridingProxy( 1798 extension = extensions::GetExtensionOverridingProxy(
1798 Profile::FromWebUI(web_ui())); 1799 Profile::FromWebUI(web_ui()));
1799 AppendExtensionData("proxy", extension, &extension_controlled); 1800 AppendExtensionData("proxy", extension, &extension_controlled);
1800 1801
1801 web_ui()->CallJavascriptFunction("BrowserOptions.toggleExtensionIndicators", 1802 web_ui()->CallJavascriptFunction("BrowserOptions.toggleExtensionIndicators",
1802 extension_controlled); 1803 extension_controlled);
1803 #endif // defined(OS_WIN) 1804 #endif // defined(OS_WIN)
1804 } 1805 }
1805 1806
1806 } // namespace options 1807 } // namespace options
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698