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

Unified Diff: content/browser/browser_main_loop.h

Issue 8302016: Make GTK and Aura parts orthogonal to OS parts (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Moved BrowserMainLoop into its own file, changed PreMainMessageLoopStart to return void Created 9 years, 2 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
Index: content/browser/browser_main_loop.h
diff --git a/content/browser/browser_main_loop.h b/content/browser/browser_main_loop.h
new file mode 100644
index 0000000000000000000000000000000000000000..4d95685dd90235cc4098ea8cfa521b6e90471876
--- /dev/null
+++ b/content/browser/browser_main_loop.h
@@ -0,0 +1,46 @@
+// 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.
+
+#ifndef CONTENT_BROWSER_BROWSER_MAIN_LOOP_H_
+#define CONTENT_BROWSER_BROWSER_MAIN_LOOP_H_
+#pragma once
+
+#include "base/basictypes.h"
+#include "base/command_line.h"
jam 2011/10/25 06:11:28 nit: most of these headers aren't referenced in th
stevenjb 2011/10/25 19:21:18 Done.
+#include "base/message_loop.h"
+#include "base/system_monitor/system_monitor.h"
+#include "content/browser/browser_thread.h"
+#include "content/common/hi_res_timer_manager.h"
+#include "content/common/main_function_params.h"
+#include "net/base/network_change_notifier.h"
+
+namespace content {
+
+// Implements the main browser loop stages called from |BrowserMain()|.
+// See comments in browser_main_parts.h for additional info.
+class BrowserMainLoop {
jam 2011/10/25 06:11:28 sorry maybe I wasn't clear. I had meant just putti
stevenjb 2011/10/25 16:24:34 I generally prefer to keep implementation details
jam 2011/10/25 16:33:59 hmm I haven't encountered this anywhere else in ch
stevenjb 2011/10/25 19:21:18 OK, I will change this.
+ public:
+ static BrowserMainLoop* CreateInstance(
+ const MainFunctionParams& parameters);
+
+ BrowserMainLoop() {}
+ virtual ~BrowserMainLoop() {}
+
+ // Parts to be called by |BrowserMain()|.
+ virtual void EarlyInitialization() = 0;
+ virtual void InitializeToolkit() = 0;
+ virtual void MainMessageLoopStart() = 0;
+ virtual void RunMainMessageLoopParts(
+ bool* completed_main_message_loop) = 0;
+ virtual void MainMessageLoopRun() = 0;
+
+ virtual int GetResultCode() const = 0;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(BrowserMainLoop);
+};
+
+} // namespace content
+
+#endif // CONTENT_BROWSER_BROWSER_MAIN_LOOP_H_

Powered by Google App Engine
This is Rietveld 408576698