| 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 CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ | 5 #ifndef CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ |
| 6 #define CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ | 6 #define CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "components/devtools_http_handler/devtools_http_handler_delegate.h" | 8 #include "components/devtools_http_handler/devtools_http_handler_delegate.h" |
| 9 #include "content/public/browser/devtools_manager_delegate.h" | |
| 10 #include "net/socket/stream_listen_socket.h" | 9 #include "net/socket/stream_listen_socket.h" |
| 11 | 10 |
| 12 namespace base { | |
| 13 class FilePath; | |
| 14 } | |
| 15 | |
| 16 namespace content { | |
| 17 class BrowserContext; | |
| 18 } | |
| 19 | |
| 20 namespace chromecast { | 11 namespace chromecast { |
| 21 namespace shell { | 12 namespace shell { |
| 22 | 13 |
| 23 class CastDevToolsDelegate : | 14 class CastDevToolsDelegate : |
| 24 public devtools_http_handler::DevToolsHttpHandlerDelegate { | 15 public devtools_http_handler::DevToolsHttpHandlerDelegate { |
| 25 public: | 16 public: |
| 26 CastDevToolsDelegate(); | 17 CastDevToolsDelegate(); |
| 27 ~CastDevToolsDelegate() override; | 18 ~CastDevToolsDelegate() override; |
| 28 | 19 |
| 29 // devtools_http_handler::DevToolsHttpHandlerDelegate implementation. | 20 // devtools_http_handler::DevToolsHttpHandlerDelegate implementation. |
| 30 std::string GetDiscoveryPageHTML() override; | 21 std::string GetDiscoveryPageHTML() override; |
| 31 std::string GetFrontendResource(const std::string& path) override; | 22 std::string GetFrontendResource(const std::string& path) override; |
| 23 std::string GetPageThumbnailData(const GURL& url) override; |
| 32 | 24 |
| 33 private: | 25 private: |
| 34 DISALLOW_COPY_AND_ASSIGN(CastDevToolsDelegate); | 26 DISALLOW_COPY_AND_ASSIGN(CastDevToolsDelegate); |
| 35 }; | 27 }; |
| 36 | 28 |
| 37 class CastDevToolsManagerDelegate : public content::DevToolsManagerDelegate { | |
| 38 public: | |
| 39 CastDevToolsManagerDelegate(); | |
| 40 ~CastDevToolsManagerDelegate() override; | |
| 41 | |
| 42 // DevToolsManagerDelegate implementation. | |
| 43 void Inspect( | |
| 44 content::BrowserContext* browser_context, | |
| 45 content::DevToolsAgentHost* agent_host) override {} | |
| 46 void DevToolsAgentStateChanged( | |
| 47 content::DevToolsAgentHost* agent_host, | |
| 48 bool attached) override {} | |
| 49 base::DictionaryValue* HandleCommand( | |
| 50 content::DevToolsAgentHost* agent_host, | |
| 51 base::DictionaryValue* command) override; | |
| 52 scoped_ptr<content::DevToolsTarget> CreateNewTarget(const GURL& url) override; | |
| 53 void EnumerateTargets(TargetCallback callback) override; | |
| 54 std::string GetPageThumbnailData(const GURL& url) override; | |
| 55 | |
| 56 private: | |
| 57 DISALLOW_COPY_AND_ASSIGN(CastDevToolsManagerDelegate); | |
| 58 }; | |
| 59 | |
| 60 } // namespace shell | 29 } // namespace shell |
| 61 } // namespace chromecast | 30 } // namespace chromecast |
| 62 | 31 |
| 63 #endif // CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ | 32 #endif // CHROMECAST_BROWSER_DEVTOOLS_CAST_DEV_TOOLS_DELEGATE_H_ |
| OLD | NEW |