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

Side by Side Diff: chrome/browser/resources/options2/chromeos/pointer_overlay.js

Issue 10391044: retry 136193 - convert localStrings to loadTimeData for options page (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync Created 8 years, 7 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 | Annotate | Revision Log
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('options', function() { 5 cr.define('options', function() {
6 /** @const */ var SettingsDialog = options.SettingsDialog; 6 /** @const */ var SettingsDialog = options.SettingsDialog;
7 7
8 /** 8 /**
9 * PointerOverlay class 9 * PointerOverlay class
10 * Dialog that allows users to set pointer settings (touchpad/mouse). 10 * Dialog that allows users to set pointer settings (touchpad/mouse).
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 * button that activates the overlay is also updated to stay in sync. A 55 * button that activates the overlay is also updated to stay in sync. A
56 * message is displayed in the main settings page if no pointer devices are 56 * message is displayed in the main settings page if no pointer devices are
57 * available. 57 * available.
58 * @param {String} label i18n key for the overlay title. 58 * @param {String} label i18n key for the overlay title.
59 */ 59 */
60 PointerOverlay.setTitle = function(label) { 60 PointerOverlay.setTitle = function(label) {
61 var header = $('pointer-overlay-title'); 61 var header = $('pointer-overlay-title');
62 var button = $('pointer-settings-button'); 62 var button = $('pointer-settings-button');
63 var noPointersLabel = $('no-pointing-devices'); 63 var noPointersLabel = $('no-pointing-devices');
64 if (label.length > 0) { 64 if (label.length > 0) {
65 var title = localStrings.getString(label); 65 var title = loadTimeData.getString(label);
66 header.textContent = title; 66 header.textContent = title;
67 button.textContent = title; 67 button.textContent = title;
68 button.hidden = false; 68 button.hidden = false;
69 noPointersLabel.hidden = true; 69 noPointersLabel.hidden = true;
70 } else { 70 } else {
71 header.textContent = ''; 71 header.textContent = '';
72 button.hidden = true; 72 button.hidden = true;
73 noPointersLabel.hidden = false; 73 noPointersLabel.hidden = false;
74 } 74 }
75 }; 75 };
76 76
77 // Export 77 // Export
78 return { 78 return {
79 PointerOverlay: PointerOverlay 79 PointerOverlay: PointerOverlay
80 }; 80 };
81 }); 81 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698