| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ | 6 #define CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 public: | 30 public: |
| 31 static DevToolsManager* GetInstance(); | 31 static DevToolsManager* GetInstance(); |
| 32 | 32 |
| 33 // Routes devtools message from |from| client to corresponding | 33 // Routes devtools message from |from| client to corresponding |
| 34 // DevToolsAgentHost. | 34 // DevToolsAgentHost. |
| 35 virtual bool DispatchOnInspectorBackend(DevToolsClientHost* from, | 35 virtual bool DispatchOnInspectorBackend(DevToolsClientHost* from, |
| 36 const std::string& message) = 0; | 36 const std::string& message) = 0; |
| 37 | 37 |
| 38 // Invoked when a tab is replaced by another tab. This is triggered by | 38 // Invoked when a tab is replaced by another tab. This is triggered by |
| 39 // TabStripModel::ReplaceTabContentsAt. | 39 // TabStripModel::ReplaceTabContentsAt. |
| 40 virtual void TabReplaced(TabContents* old_tab, TabContents* new_tab) = 0; | 40 virtual void TabReplaced(WebContents* old_tab, WebContents* new_tab) = 0; |
| 41 | 41 |
| 42 // Closes all open developer tools windows. | 42 // Closes all open developer tools windows. |
| 43 virtual void CloseAllClientHosts() = 0; | 43 virtual void CloseAllClientHosts() = 0; |
| 44 | 44 |
| 45 // Returns client attached to the |agent_host| if there is one. | 45 // Returns client attached to the |agent_host| if there is one. |
| 46 virtual DevToolsClientHost* GetDevToolsClientHostFor( | 46 virtual DevToolsClientHost* GetDevToolsClientHostFor( |
| 47 DevToolsAgentHost* agent_host) = 0; | 47 DevToolsAgentHost* agent_host) = 0; |
| 48 | 48 |
| 49 // Registers new DevToolsClientHost for inspected |agent_host|. There must be | 49 // Registers new DevToolsClientHost for inspected |agent_host|. There must be |
| 50 // no other DevToolsClientHosts registered for the |agent_host| at the moment. | 50 // no other DevToolsClientHosts registered for the |agent_host| at the moment. |
| (...skipping 19 matching lines...) Expand all Loading... |
| 70 // DevToolsClientHost. Called by closing client. | 70 // DevToolsClientHost. Called by closing client. |
| 71 virtual void ClientHostClosing(DevToolsClientHost* client_host) = 0; | 71 virtual void ClientHostClosing(DevToolsClientHost* client_host) = 0; |
| 72 | 72 |
| 73 // Starts inspecting element at position (x, y) in the specified page. | 73 // Starts inspecting element at position (x, y) in the specified page. |
| 74 virtual void InspectElement(DevToolsAgentHost* agent_host, int x, int y) = 0; | 74 virtual void InspectElement(DevToolsAgentHost* agent_host, int x, int y) = 0; |
| 75 }; | 75 }; |
| 76 | 76 |
| 77 } // namespace content | 77 } // namespace content |
| 78 | 78 |
| 79 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ | 79 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ |
| OLD | NEW |