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

Unified Diff: chrome/browser/extensions/lazy_background_task_queue.h

Issue 10082019: Have LazyBackgroundTaskQueue notify consumers when the transient page fails to (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: yoyo 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/lazy_background_task_queue.h
diff --git a/chrome/browser/extensions/lazy_background_task_queue.h b/chrome/browser/extensions/lazy_background_task_queue.h
index 18860fa07e368921fa59224baeff19e2e805c977..12b85ba73049d51f84c15d84801464815d0c8deb 100644
--- a/chrome/browser/extensions/lazy_background_task_queue.h
+++ b/chrome/browser/extensions/lazy_background_task_queue.h
@@ -40,6 +40,9 @@ class LazyBackgroundTaskQueue : public content::NotificationObserver {
// Adds a task to the queue for a given extension. If this is the first
// task added for the extension, its lazy background page will be loaded.
+ // The task will be called either when the page is loaded, or when the
+ // page fails to load for some reason (e.g. a crash). In the latter case,
+ // the ExtensionHost parameter is NULL.
void AddPendingTask(
Profile* profile,
const std::string& extension_id,
@@ -59,9 +62,12 @@ class LazyBackgroundTaskQueue : public content::NotificationObserver {
const content::NotificationSource& source,
const content::NotificationDetails& details) OVERRIDE;
- // Called when a lazy background page has finished loading. All enqueued
- // tasks are run in order.
- void ProcessPendingTasks(ExtensionHost* host);
+ // Called when a lazy background page has finished loading, or has failed to
+ // load (host is NULL in that case). All enqueued tasks are run in order.
+ void ProcessPendingTasks(
+ ExtensionHost* host,
+ Profile* profile,
+ const Extension* extension);
Profile* profile_;
content::NotificationRegistrar registrar_;
« no previous file with comments | « chrome/browser/extensions/extension_message_service.cc ('k') | chrome/browser/extensions/lazy_background_task_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698