OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ | 5 #ifndef CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ |
6 #define CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ | 6 #define CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "content/public/renderer/render_frame_observer.h" | 11 #include "content/public/renderer/render_frame_observer.h" |
12 #include "content/public/renderer/render_frame_observer_tracker.h" | 12 #include "content/public/renderer/render_frame_observer_tracker.h" |
13 #include "mojo/public/cpp/system/core.h" | 13 #include "mojo/public/cpp/system/core.h" |
14 | 14 |
15 namespace gin { | |
16 class PerContextData; | |
17 } | |
18 | |
19 namespace content { | 15 namespace content { |
20 | 16 |
21 class MojoContextState; | 17 class MojoContextState; |
22 | 18 |
23 enum class MojoBindingsType { FOR_WEB_UI, FOR_LAYOUT_TESTS, FOR_HEADLESS }; | 19 enum class MojoBindingsType { FOR_WEB_UI, FOR_LAYOUT_TESTS, FOR_HEADLESS }; |
24 | 20 |
25 // MojoBindingsController is responsible for enabling the renderer side of mojo | 21 // MojoBindingsController is responsible for enabling the renderer side of mojo |
26 // bindings. It creates (and destroys) a MojoContextState at the appropriate | 22 // bindings. It creates (and destroys) a MojoContextState at the appropriate |
27 // times and handles the necessary browser messages. MojoBindingsController | 23 // times and handles the necessary browser messages. MojoBindingsController |
28 // destroys itself when the RendererFrame it is created with is destroyed. | 24 // destroys itself when the RendererFrame it is created with is destroyed. |
(...skipping 20 matching lines...) Expand all Loading... |
49 void OnDestruct() override; | 45 void OnDestruct() override; |
50 | 46 |
51 const MojoBindingsType bindings_type_; | 47 const MojoBindingsType bindings_type_; |
52 | 48 |
53 DISALLOW_COPY_AND_ASSIGN(MojoBindingsController); | 49 DISALLOW_COPY_AND_ASSIGN(MojoBindingsController); |
54 }; | 50 }; |
55 | 51 |
56 } // namespace content | 52 } // namespace content |
57 | 53 |
58 #endif // CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ | 54 #endif // CONTENT_RENDERER_MOJO_BINDINGS_CONTROLLER_H_ |
OLD | NEW |