| Index: chrome/browser/chrome_thread.h
|
| ===================================================================
|
| --- chrome/browser/chrome_thread.h (revision 20100)
|
| +++ chrome/browser/chrome_thread.h (working copy)
|
| @@ -38,6 +38,10 @@
|
| // This is the thread that interacts with the database.
|
| DB,
|
|
|
| + // This is the "main" thread for WebKit within the browser process when
|
| + // NOT in --single-process mode.
|
| + WEBKIT,
|
| +
|
| // This is the thread that interacts with the history database.
|
| HISTORY,
|
|
|
| @@ -68,6 +72,16 @@
|
| //
|
| static MessageLoop* GetMessageLoop(ID identifier);
|
|
|
| + // Callable on any thread. Returns whether you're currently on a particular
|
| + // thread.
|
| + //
|
| + // WARNING:
|
| + // When running under unit-tests, this will return true if you're on the
|
| + // main thread and the thread ID you pass in isn't running. This is
|
| + // normally the correct behavior because you want to ignore these asserts
|
| + // unless you've specifically spun up the threads, but be mindful of it.
|
| + static bool CurrentlyOn(ID identifier);
|
| +
|
| private:
|
| // The identifier of this thread. Only one thread can exist with a given
|
| // identifier at a given time.
|
|
|