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

Unified Diff: content/browser/browser_main_loop.h

Issue 8477004: Have content/ create and destroy its own threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix official build, avoid DCHECK in official Linux/ChromeOS builds. Created 9 years, 1 month 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 | « chrome_frame/test/net/fake_external_tab.cc ('k') | content/browser/browser_main_loop.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_main_loop.h
diff --git a/content/browser/browser_main_loop.h b/content/browser/browser_main_loop.h
index d02d578595dd60ac5379801768b439a3f98e206c..3038332a3f7366e62ca12cf52709ec83d0dfeb96 100644
--- a/content/browser/browser_main_loop.h
+++ b/content/browser/browser_main_loop.h
@@ -8,6 +8,7 @@
#include "base/basictypes.h"
#include "base/memory/scoped_ptr.h"
+#include "content/browser/browser_process_sub_thread.h"
class CommandLine;
class HighResolutionTimerManager;
@@ -25,6 +26,7 @@ class NetworkChangeNotifier;
namespace content {
class BrowserMainParts;
+class BrowserShutdownImpl;
class BrowserThreadImpl;
struct MainFunctionParams;
@@ -46,6 +48,13 @@ class BrowserMainLoop {
int GetResultCode() const { return result_code_; }
private:
+ // For ShutdownThreadsAndCleanUp.
+ friend class BrowserShutdownImpl;
+
+ // Performs the shutdown sequence, starting with PostMainMessageLoopRun
+ // through stopping threads to PostDestroyThreads.
+ void ShutdownThreadsAndCleanUp();
+
void InitializeMainThread();
// Members initialized on construction ---------------------------------------
@@ -69,6 +78,14 @@ class BrowserMainLoop {
// Members initialized in |InitializeMainThread()| ---------------------------
// This must get destroyed before other threads that are created in parts_.
scoped_ptr<BrowserThreadImpl> main_thread_;
+ scoped_ptr<BrowserProcessSubThread> io_thread_;
+ scoped_ptr<BrowserProcessSubThread> file_thread_;
+ scoped_ptr<BrowserProcessSubThread> db_thread_;
+ scoped_ptr<BrowserProcessSubThread> process_launcher_thread_;
+ scoped_ptr<BrowserProcessSubThread> cache_thread_;
+#if defined(OS_CHROMEOS)
+ scoped_ptr<BrowserProcessSubThread> web_socket_proxy_thread_;
+#endif
DISALLOW_COPY_AND_ASSIGN(BrowserMainLoop);
};
« no previous file with comments | « chrome_frame/test/net/fake_external_tab.cc ('k') | content/browser/browser_main_loop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698