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

Side by Side Diff: chrome/browser/resources/print_preview/settings/page_settings.js

Issue 590643002: Move Print Preview onto newer i18nTemplate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update new invitations code Created 6 years, 3 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
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 cr.define('print_preview', function() { 5 cr.define('print_preview', function() {
6 'use strict'; 6 'use strict';
7 7
8 /** 8 /**
9 * Creates a PageSettings object. This object encapsulates all settings and 9 * Creates a PageSettings object. This object encapsulates all settings and
10 * logic related to page selection. 10 * logic related to page selection.
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 /** @override */ 131 /** @override */
132 decorateInternal: function() { 132 decorateInternal: function() {
133 this.customInput_ = this.getElement().getElementsByClassName( 133 this.customInput_ = this.getElement().getElementsByClassName(
134 PageSettings.Classes_.CUSTOM_INPUT)[0]; 134 PageSettings.Classes_.CUSTOM_INPUT)[0];
135 this.allRadio_ = this.getElement().getElementsByClassName( 135 this.allRadio_ = this.getElement().getElementsByClassName(
136 PageSettings.Classes_.ALL_RADIO)[0]; 136 PageSettings.Classes_.ALL_RADIO)[0];
137 this.customRadio_ = this.getElement().getElementsByClassName( 137 this.customRadio_ = this.getElement().getElementsByClassName(
138 PageSettings.Classes_.CUSTOM_RADIO)[0]; 138 PageSettings.Classes_.CUSTOM_RADIO)[0];
139 this.customHintEl_ = this.getElement().getElementsByClassName( 139 this.customHintEl_ = this.getElement().getElementsByClassName(
140 PageSettings.Classes_.CUSTOM_HINT)[0]; 140 PageSettings.Classes_.CUSTOM_HINT)[0];
141 this.customHintEl_.textContent = localStrings.getStringF( 141 this.customHintEl_.textContent = loadTimeData.getStringF(
142 'pageRangeInstruction', 142 'pageRangeInstruction',
143 localStrings.getString('examplePageRangeText')); 143 loadTimeData.getString('examplePageRangeText'));
144 }, 144 },
145 145
146 /** 146 /**
147 * @param {boolean} isVisible Whether the custom hint is visible. 147 * @param {boolean} isVisible Whether the custom hint is visible.
148 * @private 148 * @private
149 */ 149 */
150 setInvalidStateVisible_: function(isVisible) { 150 setInvalidStateVisible_: function(isVisible) {
151 if (isVisible) { 151 if (isVisible) {
152 this.customInput_.classList.add('invalid'); 152 this.customInput_.classList.add('invalid');
153 fadeInElement(this.customHintEl_); 153 fadeInElement(this.customHintEl_);
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 } 259 }
260 this.updateUiStateInternal(); 260 this.updateUiStateInternal();
261 } 261 }
262 }; 262 };
263 263
264 // Export 264 // Export
265 return { 265 return {
266 PageSettings: PageSettings 266 PageSettings: PageSettings
267 }; 267 };
268 }); 268 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698