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

Side by Side Diff: chrome/browser/resources/help/help.js

Issue 10038034: Implemented a "Last Updated" field for the about page of Chrome OS. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Moved #include out of #if defined(OS_CHROMEOS) Created 8 years, 8 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 | « chrome/browser/resources/help/help.html ('k') | chrome/browser/ui/webui/help/help_handler.h » ('j') | 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 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 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 option.selected = true; 206 option.selected = true;
207 } 207 }
208 }, 208 },
209 209
210 /** 210 /**
211 * @private 211 * @private
212 */ 212 */
213 setReleaseChannel_: function(channel) { 213 setReleaseChannel_: function(channel) {
214 chrome.send('setReleaseTrack', [channel]); 214 chrome.send('setReleaseTrack', [channel]);
215 }, 215 },
216
217 /**
218 * Sets the value of the "Last Updated" field of the "More Info" section.
219 * @param {String} lastUpdated The date of the last update.
220 * @private
221 */
222 setLastUpdated_: function(lastUpdated) {
223 $('last-updated-container').classList.remove('empty');
224 $('last-updated').textContent = lastUpdated;
225 },
216 }; 226 };
217 227
218 HelpPage.setUpdateStatus = function(status, message) { 228 HelpPage.setUpdateStatus = function(status, message) {
219 HelpPage.getInstance().setUpdateStatus_(status, message); 229 HelpPage.getInstance().setUpdateStatus_(status, message);
220 }; 230 };
221 231
222 HelpPage.setProgress = function(progress) { 232 HelpPage.setProgress = function(progress) {
223 HelpPage.getInstance().setProgress_(progress); 233 HelpPage.getInstance().setProgress_(progress);
224 }; 234 };
225 235
(...skipping 18 matching lines...) Expand all
244 }; 254 };
245 255
246 HelpPage.updateEnableReleaseChannel = function(enabled) { 256 HelpPage.updateEnableReleaseChannel = function(enabled) {
247 HelpPage.getInstance().updateEnableReleaseChannel_(enabled); 257 HelpPage.getInstance().updateEnableReleaseChannel_(enabled);
248 }; 258 };
249 259
250 HelpPage.setReleaseChannel = function(channel) { 260 HelpPage.setReleaseChannel = function(channel) {
251 HelpPage.getInstance().setReleaseChannel_(channel); 261 HelpPage.getInstance().setReleaseChannel_(channel);
252 }; 262 };
253 263
264 HelpPage.setLastUpdated = function(lastUpdated) {
265 HelpPage.getInstance().setLastUpdated_(lastUpdated);
266 }
267
254 // Export 268 // Export
255 return { 269 return {
256 HelpPage: HelpPage 270 HelpPage: HelpPage
257 }; 271 };
258 }); 272 });
259 273
260 /** 274 /**
261 * onload listener to initialize the HelpPage. 275 * onload listener to initialize the HelpPage.
262 */ 276 */
263 window.onload = function() { 277 window.onload = function() {
264 help.HelpPage.getInstance().initialize(); 278 help.HelpPage.getInstance().initialize();
265 }; 279 };
OLDNEW
« no previous file with comments | « chrome/browser/resources/help/help.html ('k') | chrome/browser/ui/webui/help/help_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698