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

Unified Diff: chrome/browser/extensions/signin/gaia_auth_extension_loader.h

Issue 961443003: Unload the ScopedGaiaAuthExtension asynchronously. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix whitespace Created 5 years, 9 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/extensions/signin/gaia_auth_extension_loader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/signin/gaia_auth_extension_loader.h
diff --git a/chrome/browser/extensions/signin/gaia_auth_extension_loader.h b/chrome/browser/extensions/signin/gaia_auth_extension_loader.h
index 146596e11691145ac9532c4686a9fcd85bdb4c43..b16b9dab276002eb6aea286c8fb56bdc5604b161 100644
--- a/chrome/browser/extensions/signin/gaia_auth_extension_loader.h
+++ b/chrome/browser/extensions/signin/gaia_auth_extension_loader.h
@@ -9,6 +9,7 @@
#include <string>
#include "base/macros.h"
+#include "base/memory/weak_ptr.h"
#include "extensions/browser/browser_context_keyed_api_factory.h"
namespace content {
@@ -31,6 +32,7 @@ class GaiaAuthExtensionLoader : public BrowserContextKeyedAPI {
void LoadIfNeeded();
// Unload the gaia auth extension if no pending reference.
void UnloadIfNeeded();
+ void UnloadIfNeededAsync();
// Add a string data for gaia auth extension. Returns an ID that
// could be used to get the data. All strings are cleared when gaia auth
@@ -65,6 +67,8 @@ class GaiaAuthExtensionLoader : public BrowserContextKeyedAPI {
int last_data_id_;
std::map<int, std::string> data_;
+ base::WeakPtrFactory<GaiaAuthExtensionLoader> weak_ptr_factory_;
+
DISALLOW_COPY_AND_ASSIGN(GaiaAuthExtensionLoader);
};
« no previous file with comments | « no previous file | chrome/browser/extensions/signin/gaia_auth_extension_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698