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

Unified Diff: components/crash/core/browser/crashes_ui_util.cc

Issue 2330573002: Show crash report size in crashes UI for Android. (Closed)
Patch Set: Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: components/crash/core/browser/crashes_ui_util.cc
diff --git a/components/crash/core/browser/crashes_ui_util.cc b/components/crash/core/browser/crashes_ui_util.cc
index fa459cc69df420ded9158b57dc92f9026caeaf51..32cf1eb4838df1fd70b60963f2826a657f7e33cd 100644
--- a/components/crash/core/browser/crashes_ui_util.cc
+++ b/components/crash/core/browser/crashes_ui_util.cc
@@ -10,6 +10,7 @@
#include "base/i18n/time_formatting.h"
#include "base/macros.h"
+#include "base/strings/string_number_conversions.h"
#include "base/values.h"
#include "components/upload_list/upload_list.h"
#include "grit/components_chromium_strings.h"
@@ -32,6 +33,7 @@ const CrashesUILocalizedString kCrashesUILocalizedStrings[] = {
{"noCrashesMessage", IDS_CRASH_NO_CRASHES_MESSAGE},
{"uploadCrashesLinkText", IDS_CRASH_UPLOAD_MESSAGE},
{"uploadNowLinkText", IDS_CRASH_UPLOAD_NOW_LINK_TEXT},
+ {"crashSizeMessage", IDS_CRASH_SIZE_MESSAGE},
};
const size_t kCrashesUILocalizedStringsCount =
@@ -76,6 +78,9 @@ void UploadListToValue(UploadList* upload_list, base::ListValue* out_value) {
}
crash->SetString("local_id", info.local_id);
crash->SetString("state", UploadInfoStateAsString(info.state));
+ crash->SetString("file_size", info.file_size == 0
Mark Mentovai 2016/09/13 16:13:25 A crash report’s might accidentally wind up as 0 b
gayane -on leave until 09-2017 2016/09/13 17:40:23 Done.
+ ? ""
+ : base::IntToString(info.file_size));
out_value->Append(std::move(crash));
}
}

Powered by Google App Engine
This is Rietveld 408576698