OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ |
6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | |
9 #include "base/memory/scoped_ptr.h" | |
10 #include "base/message_loop.h" | |
jam
2012/12/21 02:21:46
nit: can forward declare too
| |
8 #include "content/public/browser/browser_main_parts.h" | 11 #include "content/public/browser/browser_main_parts.h" |
9 | 12 |
10 namespace android_webview { | 13 namespace android_webview { |
11 | 14 |
12 // TODO(joth): Remove this method when when http://crbug.com/161864 is closed. | 15 // TODO(joth): Remove this method when when http://crbug.com/161864 is closed. |
13 bool UseCompositorDirectDraw(); | 16 bool UseCompositorDirectDraw(); |
14 | 17 |
15 class AwBrowserContext; | 18 class AwBrowserContext; |
16 | 19 |
17 class AwBrowserMainParts : public content::BrowserMainParts { | 20 class AwBrowserMainParts : public content::BrowserMainParts { |
18 public: | 21 public: |
19 AwBrowserMainParts(AwBrowserContext* browser_context); | 22 explicit AwBrowserMainParts(AwBrowserContext* browser_context); |
20 virtual ~AwBrowserMainParts(); | 23 virtual ~AwBrowserMainParts(); |
21 | 24 |
22 // Overriding methods from content::BrowserMainParts. | 25 // Overriding methods from content::BrowserMainParts. |
23 virtual void PreEarlyInitialization() OVERRIDE; | 26 virtual void PreEarlyInitialization() OVERRIDE; |
24 virtual int PreCreateThreads() OVERRIDE; | 27 virtual int PreCreateThreads() OVERRIDE; |
25 virtual bool MainMessageLoopRun(int* result_code) OVERRIDE; | 28 virtual bool MainMessageLoopRun(int* result_code) OVERRIDE; |
26 | 29 |
27 private: | 30 private: |
28 // Android specific UI MessageLoop. | 31 // Android specific UI MessageLoop. |
29 scoped_ptr<MessageLoop> main_message_loop_; | 32 scoped_ptr<MessageLoop> main_message_loop_; |
30 | 33 |
31 AwBrowserContext* browser_context_; // weak | 34 AwBrowserContext* browser_context_; // weak |
32 | 35 |
33 DISALLOW_COPY_AND_ASSIGN(AwBrowserMainParts); | 36 DISALLOW_COPY_AND_ASSIGN(AwBrowserMainParts); |
34 }; | 37 }; |
35 | 38 |
36 } // namespace android_webview | 39 } // namespace android_webview |
37 | 40 |
38 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ | 41 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_MAIN_PARTS_H_ |
OLD | NEW |