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

Side by Side Diff: components/crash/core/browser/crashes_ui_util.cc

Issue 1405373002: Fix WebRTC log list errors. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 2 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/ui/webui/media/webrtc_logs_ui.cc ('k') | components/upload_list/upload_list.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/crash/core/browser/crashes_ui_util.h" 5 #include "components/crash/core/browser/crashes_ui_util.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/i18n/time_formatting.h" 9 #include "base/i18n/time_formatting.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 25 matching lines...) Expand all
36 const char kCrashesUIRequestCrashUpload[] = "requestCrashUpload"; 36 const char kCrashesUIRequestCrashUpload[] = "requestCrashUpload";
37 const char kCrashesUIShortProductName[] = "shortProductName"; 37 const char kCrashesUIShortProductName[] = "shortProductName";
38 const char kCrashesUIUpdateCrashList[] = "updateCrashList"; 38 const char kCrashesUIUpdateCrashList[] = "updateCrashList";
39 39
40 void UploadListToValue(UploadList* upload_list, base::ListValue* out_value) { 40 void UploadListToValue(UploadList* upload_list, base::ListValue* out_value) {
41 std::vector<UploadList::UploadInfo> crashes; 41 std::vector<UploadList::UploadInfo> crashes;
42 upload_list->GetUploads(50, &crashes); 42 upload_list->GetUploads(50, &crashes);
43 43
44 for (const auto& info : crashes) { 44 for (const auto& info : crashes) {
45 base::DictionaryValue* crash = new base::DictionaryValue(); 45 base::DictionaryValue* crash = new base::DictionaryValue();
46 crash->SetString("id", info.id); 46 crash->SetString("id", info.upload_id);
47 crash->SetString("time", base::TimeFormatFriendlyDateAndTime(info.time)); 47 crash->SetString("time",
48 base::TimeFormatFriendlyDateAndTime(info.upload_time));
48 crash->SetString("local_id", info.local_id); 49 crash->SetString("local_id", info.local_id);
49 out_value->Append(crash); 50 out_value->Append(crash);
50 } 51 }
51 } 52 }
52 53
53 } // namespace crash 54 } // namespace crash
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/media/webrtc_logs_ui.cc ('k') | components/upload_list/upload_list.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698