| 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 EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ | 5 #ifndef EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ |
| 6 #define EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ | 6 #define EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "content/public/renderer/content_renderer_client.h" | 12 #include "content/public/renderer/content_renderer_client.h" |
| 13 | 13 |
| 14 namespace blink { | 14 namespace blink { |
| 15 class WebURL; | 15 class WebURL; |
| 16 } // namespace blink | 16 } // namespace blink |
| 17 | 17 |
| 18 namespace extensions { | 18 namespace extensions { |
| 19 | 19 |
| 20 class Dispatcher; | |
| 21 class DispatcherDelegate; | |
| 22 class ExtensionsClient; | 20 class ExtensionsClient; |
| 23 class ExtensionsGuestViewContainerDispatcher; | 21 class ExtensionsGuestViewContainerDispatcher; |
| 24 class ShellExtensionsRendererClient; | 22 class ShellExtensionsRendererClient; |
| 25 | 23 |
| 26 // Renderer initialization and runtime support for app_shell. | 24 // Renderer initialization and runtime support for app_shell. |
| 27 class ShellContentRendererClient : public content::ContentRendererClient { | 25 class ShellContentRendererClient : public content::ContentRendererClient { |
| 28 public: | 26 public: |
| 29 ShellContentRendererClient(); | 27 ShellContentRendererClient(); |
| 30 ~ShellContentRendererClient() override; | 28 ~ShellContentRendererClient() override; |
| 31 | 29 |
| (...skipping 21 matching lines...) Expand all Loading... |
| 53 void RunScriptsAtDocumentEnd(content::RenderFrame* render_frame) override; | 51 void RunScriptsAtDocumentEnd(content::RenderFrame* render_frame) override; |
| 54 | 52 |
| 55 protected: | 53 protected: |
| 56 // app_shell embedders may need custom extensions client interfaces. | 54 // app_shell embedders may need custom extensions client interfaces. |
| 57 // This class takes ownership of the returned object. | 55 // This class takes ownership of the returned object. |
| 58 virtual ExtensionsClient* CreateExtensionsClient(); | 56 virtual ExtensionsClient* CreateExtensionsClient(); |
| 59 | 57 |
| 60 private: | 58 private: |
| 61 std::unique_ptr<ExtensionsClient> extensions_client_; | 59 std::unique_ptr<ExtensionsClient> extensions_client_; |
| 62 std::unique_ptr<ShellExtensionsRendererClient> extensions_renderer_client_; | 60 std::unique_ptr<ShellExtensionsRendererClient> extensions_renderer_client_; |
| 63 std::unique_ptr<DispatcherDelegate> extension_dispatcher_delegate_; | |
| 64 std::unique_ptr<Dispatcher> extension_dispatcher_; | |
| 65 std::unique_ptr<ExtensionsGuestViewContainerDispatcher> | 61 std::unique_ptr<ExtensionsGuestViewContainerDispatcher> |
| 66 guest_view_container_dispatcher_; | 62 guest_view_container_dispatcher_; |
| 67 | 63 |
| 68 DISALLOW_COPY_AND_ASSIGN(ShellContentRendererClient); | 64 DISALLOW_COPY_AND_ASSIGN(ShellContentRendererClient); |
| 69 }; | 65 }; |
| 70 | 66 |
| 71 } // namespace extensions | 67 } // namespace extensions |
| 72 | 68 |
| 73 #endif // EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ | 69 #endif // EXTENSIONS_SHELL_RENDERER_SHELL_CONTENT_RENDERER_CLIENT_H_ |
| OLD | NEW |