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

Unified Diff: chrome/browser/ui/webui/crashes_ui.cc

Issue 23020015: In chrome://crashes, re-read the crash list on page reload (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/upload_list.cc » ('j') | chrome/browser/upload_list.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/crashes_ui.cc
diff --git a/chrome/browser/ui/webui/crashes_ui.cc b/chrome/browser/ui/webui/crashes_ui.cc
index b885b013ff63318d863a8566963f3ea2c5bbc46c..9d0e7525748f6686a5f002d31eda294237c8dca0 100644
--- a/chrome/browser/ui/webui/crashes_ui.cc
+++ b/chrome/browser/ui/webui/crashes_ui.cc
@@ -89,13 +89,12 @@ class CrashesDOMHandler : public WebUIMessageHandler,
scoped_refptr<CrashUploadList> upload_list_;
bool list_available_;
vapier 2013/09/14 04:43:39 pretty sure this is now unused
achaulk1 2013/09/16 18:06:21 Ah, yes it is
- bool js_request_pending_;
DISALLOW_COPY_AND_ASSIGN(CrashesDOMHandler);
};
CrashesDOMHandler::CrashesDOMHandler()
- : list_available_(false), js_request_pending_(false) {
+ : list_available_(false) {
upload_list_ = CrashUploadList::Create(this);
}
@@ -104,24 +103,18 @@ CrashesDOMHandler::~CrashesDOMHandler() {
}
void CrashesDOMHandler::RegisterMessages() {
- upload_list_->LoadUploadListAsynchronously();
-
web_ui()->RegisterMessageCallback("requestCrashList",
base::Bind(&CrashesDOMHandler::HandleRequestCrashes,
base::Unretained(this)));
}
void CrashesDOMHandler::HandleRequestCrashes(const ListValue* args) {
- if (!CrashesUI::CrashReportingUIEnabled() || list_available_)
- UpdateUI();
- else
- js_request_pending_ = true;
+ upload_list_->LoadUploadListAsynchronously();
}
void CrashesDOMHandler::OnUploadListAvailable() {
list_available_ = true;
- if (js_request_pending_)
- UpdateUI();
+ UpdateUI();
}
void CrashesDOMHandler::UpdateUI() {
« no previous file with comments | « no previous file | chrome/browser/upload_list.cc » ('j') | chrome/browser/upload_list.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698