OLD | NEW |
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 src="../uber/uber_utils.js"> | 5 <include src="../uber/uber_utils.js"> |
6 | 6 |
7 cr.define('help', function() { | 7 cr.define('help', function() { |
8 var localStrings = new LocalStrings(); | 8 var localStrings = new LocalStrings(); |
9 | 9 |
10 /** | 10 /** |
(...skipping 10 matching lines...) Expand all Loading... |
21 * Perform initial setup. | 21 * Perform initial setup. |
22 */ | 22 */ |
23 initialize: function() { | 23 initialize: function() { |
24 uber.onContentFrameLoaded(); | 24 uber.onContentFrameLoaded(); |
25 | 25 |
26 // Set the title. | 26 // Set the title. |
27 var title = localStrings.getString('helpTitle'); | 27 var title = localStrings.getString('helpTitle'); |
28 uber.invokeMethodOnParent('setTitle', {title: title}); | 28 uber.invokeMethodOnParent('setTitle', {title: title}); |
29 | 29 |
30 $('product-license').innerHTML = localStrings.getString('productLicense'); | 30 $('product-license').innerHTML = localStrings.getString('productLicense'); |
31 if (cr.isChromeOS) | |
32 $('product-os-license').innerHTML = | |
33 localStrings.getString('productOsLicense'); | |
34 | 31 |
35 var productTOS = $('product-tos'); | 32 var productTOS = $('product-tos'); |
36 if (productTOS) | 33 if (productTOS) |
37 productTOS.innerHTML = localStrings.getString('productTOS'); | 34 productTOS.innerHTML = localStrings.getString('productTOS'); |
38 | 35 |
39 $('get-help').onclick = chrome.send.bind(chrome, 'openHelpPage'); | 36 $('get-help').onclick = chrome.send.bind(chrome, 'openHelpPage'); |
40 $('report-issue').onclick = | 37 $('report-issue').onclick = |
41 chrome.send.bind(chrome, 'openFeedbackDialog'); | 38 chrome.send.bind(chrome, 'openFeedbackDialog'); |
42 | 39 |
43 this.maybeSetOnClick_($('more-info-expander'), | 40 this.maybeSetOnClick_($('more-info-expander'), |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
252 | 249 |
253 // Export | 250 // Export |
254 return { | 251 return { |
255 HelpPage: HelpPage | 252 HelpPage: HelpPage |
256 }; | 253 }; |
257 }); | 254 }); |
258 | 255 |
259 window.onload = function() { | 256 window.onload = function() { |
260 help.HelpPage.getInstance().initialize(); | 257 help.HelpPage.getInstance().initialize(); |
261 }; | 258 }; |
OLD | NEW |