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

Unified Diff: content/browser/browser_process_io_thread.cc

Issue 8477004: Have content/ create and destroy its own threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: With this patchset, Chrome runs and exits normally on Linux. 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
Index: content/browser/browser_process_io_thread.cc
diff --git a/content/browser/browser_process_io_thread.cc b/content/browser/browser_process_io_thread.cc
new file mode 100644
index 0000000000000000000000000000000000000000..9d3136819d77130afc68361d39303d47a5a0da03
--- /dev/null
+++ b/content/browser/browser_process_io_thread.cc
@@ -0,0 +1,32 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "content/browser/browser_process_io_thread.h"
+
+#include "content/public/browser/browser_thread.h"
+
+namespace content {
+
+BrowserProcessIOThread::BrowserProcessIOThread(IOThreadDelegate* delegate)
+ : BrowserProcessSubThread(BrowserThread::IO),
+ delegate_(delegate) {
+}
+
+BrowserProcessIOThread::~BrowserProcessIOThread() {
+ Stop();
+}
+
+void BrowserProcessIOThread::Init() {
+ BrowserProcessSubThread::Init();
+ if (delegate_)
+ delegate_->Init();
+}
+
+void BrowserProcessIOThread::CleanUp() {
+ BrowserProcessSubThread::CleanUp();
+ if (delegate_)
+ delegate_->CleanUp();
+}
+
+} // namespace content

Powered by Google App Engine
This is Rietveld 408576698