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

Unified Diff: chrome/browser/resources/options/browser_options.js

Issue 12328054: Fix prefs registration for BrowserInstantController. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sketch of solution. Created 7 years, 10 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/resources/options/browser_options.js
diff --git a/chrome/browser/resources/options/browser_options.js b/chrome/browser/resources/options/browser_options.js
index 548a6068d4007f25427caf70b04c26575dafbc3d..1d0d929668962bc2d7fb59ac8d9be3399ec9920c 100644
--- a/chrome/browser/resources/options/browser_options.js
+++ b/chrome/browser/resources/options/browser_options.js
@@ -167,6 +167,13 @@ cr.define('options', function() {
$('instant-enabled-control').setAttribute(
'metric', 'Options_InstantExtendedEnabled');
}
+ // We need to set the starting value for the instant checkbox as
+ // it may be different from the value of the preference.
Mattias Nissler (ping if slow) 2013/02/25 18:53:41 If the instant_enabled is set to the right pref na
+ if (loadTimeData.getValue('instant_starting_value')) {
+ $('instant-enabled-control').setAttribute('checked', 'true');
+ } else {
+ $('instant-enabled-control').setAttribute('checked', 'false');
+ }
// Users section.
if (loadTimeData.valueExists('profilesInfo')) {

Powered by Google App Engine
This is Rietveld 408576698