| Index: chrome/browser/conflicts/module_database_win.h
|
| diff --git a/chrome/browser/conflicts/module_database_win.h b/chrome/browser/conflicts/module_database_win.h
|
| index 069ce8a1343dad1a8f9a6eb873c5995a1b2875e6..228a8e760f9f4d2edc645685d616e7631ec864ad 100644
|
| --- a/chrome/browser/conflicts/module_database_win.h
|
| +++ b/chrome/browser/conflicts/module_database_win.h
|
| @@ -16,6 +16,10 @@
|
|
|
| // A class that keeps track of all modules loaded across Chrome processes.
|
| // Drives the chrome://conflicts UI.
|
| +//
|
| +// This is effectively a singleton, but doesn't use base::Singleton. The intent
|
| +// is for the object to be created when Chrome is single-threaded, and for it
|
| +// be set as the process-wide singleton via SetInstance.
|
| class ModuleDatabase {
|
| public:
|
| // A ModuleDatabase is by default bound to a provided sequenced task runner.
|
| @@ -25,6 +29,13 @@ class ModuleDatabase {
|
| explicit ModuleDatabase(scoped_refptr<base::SequencedTaskRunner> task_runner);
|
| ~ModuleDatabase();
|
|
|
| + // Retrieves the singleton global instance of the ModuleDatabase.
|
| + static ModuleDatabase* GetInstance();
|
| +
|
| + // Sets the global instance of the ModuleDatabase. Ownership is passed to the
|
| + // global instance and deliberately leaked, unless manually cleaned up.
|
| + static void SetInstance(std::unique_ptr<ModuleDatabase> module_database);
|
| +
|
| // Indicates that process with the given type has started. This must be called
|
| // before any calls to OnModuleEvent or OnModuleUnload. Must be called in the
|
| // same sequence as |task_runner_|.
|
|
|