Chromium Code Reviews| Index: headless/lib/browser/headless_browser_impl.h |
| diff --git a/headless/lib/browser/headless_browser_impl.h b/headless/lib/browser/headless_browser_impl.h |
| index f37dff1dbc45b8c135fde8db85f6f33f53ff0160..014f9d6788201d46f1b2c688de222a02205db0ee 100644 |
| --- a/headless/lib/browser/headless_browser_impl.h |
| +++ b/headless/lib/browser/headless_browser_impl.h |
| @@ -13,16 +13,10 @@ |
| #include <vector> |
| #include "base/memory/weak_ptr.h" |
| +#include "content/public/browser/web_contents.h" |
| #include "headless/lib/browser/headless_devtools_manager_delegate.h" |
| #include "headless/lib/browser/headless_web_contents_impl.h" |
| - |
| -namespace aura { |
| -class WindowTreeHost; |
| - |
| -namespace client { |
| -class WindowParentingClient; |
| -} |
| -} |
| +#include "headless/lib/browser/headless_window_tree_host.h" |
|
Eric Seckler
2017/02/09 18:29:39
This reflects what Sami mentioned in headless_wind
dvallet
2017/02/10 05:12:20
Done, I've added #if defined(USE_AURA) directives,
|
| namespace headless { |
| @@ -70,7 +64,15 @@ class HeadlessBrowserImpl : public HeadlessBrowser { |
| base::WeakPtr<HeadlessBrowserImpl> GetWeakPtr(); |
| - aura::WindowTreeHost* window_tree_host() const; |
| + // All the methods that begin with Platform need to be implemented by the |
| + // platform specific headless implementation. |
| + // Helper for one time initialization of application |
| + void PlatformInitialize(); |
| + void PlatformCreateWindow(); |
| + void PlatformSetContents(const gfx::Size& initial_size, |
|
Sami
2017/02/09 18:08:22
nit: PlatformSetWebContents since that's what the
dvallet
2017/02/10 05:12:20
Done
|
| + content::WebContents* web_contents); |
| + |
| + HeadlessWindowTreeHost* window_tree_host() const; |
| protected: |
| base::Callback<void(HeadlessBrowser*)> on_start_callback_; |
| @@ -80,8 +82,7 @@ class HeadlessBrowserImpl : public HeadlessBrowser { |
| // TODO(eseckler): Currently one window and one window_tree_host |
| // is used for all web contents. We should probably use one |
| // window per web contents, but additional investigation is needed. |
| - std::unique_ptr<aura::WindowTreeHost> window_tree_host_; |
| - std::unique_ptr<aura::client::WindowParentingClient> window_parenting_client_; |
| + std::unique_ptr<HeadlessWindowTreeHost> window_tree_host_; |
| std::unordered_map<std::string, std::unique_ptr<HeadlessBrowserContextImpl>> |
| browser_contexts_; |