OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ | 5 #ifndef BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ |
6 #define BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ | 6 #define BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
| 10 #include <vector> |
| 11 |
10 #include "base/macros.h" | 12 #include "base/macros.h" |
11 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
12 #include "blimp/common/proto/blimp_message.pb.h" | 14 #include "blimp/common/proto/blimp_message.pb.h" |
13 #include "blimp/engine/browser/engine_render_widget_feature.h" | 15 #include "blimp/engine/browser/engine_render_widget_feature.h" |
14 #include "blimp/net/blimp_message_processor.h" | 16 #include "blimp/net/blimp_message_processor.h" |
| 17 #include "blimp/net/connection_error_observer.h" |
15 #include "content/public/browser/invalidate_type.h" | 18 #include "content/public/browser/invalidate_type.h" |
16 #include "content/public/browser/web_contents_delegate.h" | 19 #include "content/public/browser/web_contents_delegate.h" |
17 #include "content/public/browser/web_contents_observer.h" | 20 #include "content/public/browser/web_contents_observer.h" |
18 #include "net/base/completion_callback.h" | 21 #include "net/base/completion_callback.h" |
19 #include "ui/gfx/geometry/size.h" | 22 #include "ui/gfx/geometry/size.h" |
20 | 23 |
21 namespace aura { | 24 namespace aura { |
22 class WindowTreeHost; | 25 class WindowTreeHost; |
23 | 26 |
24 namespace client { | 27 namespace client { |
(...skipping 22 matching lines...) Expand all Loading... |
47 | 50 |
48 namespace blimp { | 51 namespace blimp { |
49 | 52 |
50 class BlimpConnection; | 53 class BlimpConnection; |
51 class BlimpMessage; | 54 class BlimpMessage; |
52 | 55 |
53 namespace engine { | 56 namespace engine { |
54 | 57 |
55 class BlimpBrowserContext; | 58 class BlimpBrowserContext; |
56 class BlimpFocusClient; | 59 class BlimpFocusClient; |
57 class BlimpNetworkComponents; | |
58 class BlimpScreen; | 60 class BlimpScreen; |
59 class BlimpUiContextFactory; | 61 class BlimpUiContextFactory; |
60 class BlimpWindowTreeHost; | 62 class BlimpWindowTreeHost; |
| 63 class EngineNetworkComponents; |
61 | 64 |
62 class BlimpEngineSession | 65 class BlimpEngineSession |
63 : public BlimpMessageProcessor, | 66 : public BlimpMessageProcessor, |
64 public content::WebContentsDelegate, | 67 public content::WebContentsDelegate, |
65 public content::WebContentsObserver, | 68 public content::WebContentsObserver, |
66 public EngineRenderWidgetFeature::RenderWidgetMessageDelegate { | 69 public EngineRenderWidgetFeature::RenderWidgetMessageDelegate { |
67 public: | 70 public: |
68 explicit BlimpEngineSession(scoped_ptr<BlimpBrowserContext> browser_context, | 71 explicit BlimpEngineSession(scoped_ptr<BlimpBrowserContext> browser_context, |
69 net::NetLog* net_log); | 72 net::NetLog* net_log); |
70 ~BlimpEngineSession() override; | 73 ~BlimpEngineSession() override; |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 | 154 |
152 // Used to manage input capture. | 155 // Used to manage input capture. |
153 scoped_ptr<aura::client::DefaultCaptureClient> capture_client_; | 156 scoped_ptr<aura::client::DefaultCaptureClient> capture_client_; |
154 | 157 |
155 // Only one web_contents is supported for blimp 0.5 | 158 // Only one web_contents is supported for blimp 0.5 |
156 scoped_ptr<content::WebContents> web_contents_; | 159 scoped_ptr<content::WebContents> web_contents_; |
157 | 160 |
158 // Container for connection manager, authentication handler, and | 161 // Container for connection manager, authentication handler, and |
159 // browser connection handler. The components run on the I/O thread, and | 162 // browser connection handler. The components run on the I/O thread, and |
160 // this object is destroyed there. | 163 // this object is destroyed there. |
161 scoped_ptr<BlimpNetworkComponents> net_components_; | 164 scoped_ptr<EngineNetworkComponents> net_components_; |
162 | 165 |
163 // Handles all incoming and outgoing messages related to RenderWidget, | 166 // Handles all incoming and outgoing messages related to RenderWidget, |
164 // including INPUT, COMPOSITOR and RENDER_WIDGET messages. | 167 // including INPUT, COMPOSITOR and RENDER_WIDGET messages. |
165 // TODO(dtrainor, haibinlu): Move this to a higher level once we start dealing | 168 // TODO(dtrainor, haibinlu): Move this to a higher level once we start dealing |
166 // with multiple tabs. | 169 // with multiple tabs. |
167 EngineRenderWidgetFeature render_widget_feature_; | 170 EngineRenderWidgetFeature render_widget_feature_; |
168 | 171 |
169 scoped_ptr<BlimpMessageProcessor> tab_control_message_sender_; | 172 scoped_ptr<BlimpMessageProcessor> tab_control_message_sender_; |
170 scoped_ptr<BlimpMessageProcessor> navigation_message_sender_; | 173 scoped_ptr<BlimpMessageProcessor> navigation_message_sender_; |
171 | 174 |
172 DISALLOW_COPY_AND_ASSIGN(BlimpEngineSession); | 175 DISALLOW_COPY_AND_ASSIGN(BlimpEngineSession); |
173 }; | 176 }; |
174 | 177 |
175 } // namespace engine | 178 } // namespace engine |
176 } // namespace blimp | 179 } // namespace blimp |
177 | 180 |
178 #endif // BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ | 181 #endif // BLIMP_ENGINE_BROWSER_BLIMP_ENGINE_SESSION_H_ |
OLD | NEW |