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

Side by Side Diff: components/crash/core/browser/resources/crashes.js

Issue 2622363006: Revert of Fix Incorrect date/time info under chrome://crashes. (Closed)
Patch Set: Created 3 years, 11 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 | « components/crash/core/browser/crashes_ui_util.cc ('k') | components/crash_strings.grdp » ('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 /* Id for tracking automatic refresh of crash list. */ 5 /* Id for tracking automatic refresh of crash list. */
6 var refreshCrashListId = undefined; 6 var refreshCrashListId = undefined;
7 7
8 /** 8 /**
9 * Requests the list of crashes from the backend. 9 * Requests the list of crashes from the backend.
10 */ 10 */
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 var uploaded = crash.state == 'uploaded'; 50 var uploaded = crash.state == 'uploaded';
51 if (uploaded) { 51 if (uploaded) {
52 title.textContent = loadTimeData.getStringF('crashHeaderFormat', 52 title.textContent = loadTimeData.getStringF('crashHeaderFormat',
53 crash.id, 53 crash.id,
54 crash.local_id); 54 crash.local_id);
55 } else { 55 } else {
56 title.textContent = loadTimeData.getStringF('crashHeaderFormatLocalOnly', 56 title.textContent = loadTimeData.getStringF('crashHeaderFormatLocalOnly',
57 crash.local_id); 57 crash.local_id);
58 } 58 }
59 crashBlock.appendChild(title); 59 crashBlock.appendChild(title);
60 var date = document.createElement('p');
61 date.textContent = ""
62 if (crash.time) {
63 date.textContent += loadTimeData.getStringF('crashTimeFormat',
64 crash.time);
65 }
66 if (crash.upload_time) {
67 date.textContent += loadTimeData.getStringF('crashUploadTimeFormat',
68 crash.upload_time);
69 }
70 crashBlock.appendChild(date);
71
72 if (uploaded) { 60 if (uploaded) {
61 var date = document.createElement('p');
62 date.textContent = loadTimeData.getStringF('crashTimeFormat',
63 crash.time,
64 crash.upload_time);
65 crashBlock.appendChild(date);
73 var linkBlock = document.createElement('p'); 66 var linkBlock = document.createElement('p');
74 var link = document.createElement('a'); 67 var link = document.createElement('a');
75 var commentLines = [ 68 var commentLines = [
76 'IMPORTANT: Your crash has already been automatically reported ' + 69 'IMPORTANT: Your crash has already been automatically reported ' +
77 'to our crash system. Please file this bug only if you can provide ' + 70 'to our crash system. Please file this bug only if you can provide ' +
78 'more information about it.', 71 'more information about it.',
79 '', 72 '',
80 '', 73 '',
81 'Chrome Version: ' + version, 74 'Chrome Version: ' + version,
82 'Operating System: ' + os, 75 'Operating System: ' + os,
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 154
162 // Trigger a refresh in 5 seconds. Clear any previous requests. 155 // Trigger a refresh in 5 seconds. Clear any previous requests.
163 clearTimeout(refreshCrashListId); 156 clearTimeout(refreshCrashListId);
164 refreshCrashListId = setTimeout(requestCrashes, 5000); 157 refreshCrashListId = setTimeout(requestCrashes, 5000);
165 } 158 }
166 159
167 document.addEventListener('DOMContentLoaded', function() { 160 document.addEventListener('DOMContentLoaded', function() {
168 $('uploadCrashes').onclick = requestCrashUpload; 161 $('uploadCrashes').onclick = requestCrashUpload;
169 requestCrashes(); 162 requestCrashes();
170 }); 163 });
OLDNEW
« no previous file with comments | « components/crash/core/browser/crashes_ui_util.cc ('k') | components/crash_strings.grdp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698