OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
12 | 12 |
13 namespace IPC { | 13 namespace IPC { |
14 class Message; | 14 class Message; |
15 } | 15 } |
16 | 16 |
17 namespace content { | 17 namespace content { |
18 | 18 |
19 class BrowserContext; | |
19 class DevToolsAgentHost; | 20 class DevToolsAgentHost; |
20 class DevToolsClientHost; | 21 class DevToolsClientHost; |
21 | 22 |
22 // DevToolsManager connects a devtools client to inspected agent and routes | 23 // DevToolsManager connects a devtools client to inspected agent and routes |
23 // devtools messages between the inspected instance represented by the agent | 24 // devtools messages between the inspected instance represented by the agent |
24 // and devtools front-end represented by the client. If inspected agent | 25 // and devtools front-end represented by the client. If inspected agent |
25 // gets terminated DevToolsManager will notify corresponding client and | 26 // gets terminated DevToolsManager will notify corresponding client and |
26 // remove it from the map. | 27 // remove it from the map. |
27 class CONTENT_EXPORT DevToolsManager { | 28 class CONTENT_EXPORT DevToolsManager { |
28 public: | 29 public: |
(...skipping 22 matching lines...) Expand all Loading... | |
51 | 52 |
52 // This method will remove all references from the manager to the | 53 // This method will remove all references from the manager to the |
53 // DevToolsClientHost and unregister all listeners related to the | 54 // DevToolsClientHost and unregister all listeners related to the |
54 // DevToolsClientHost. Called by closing client. | 55 // DevToolsClientHost. Called by closing client. |
55 virtual void ClientHostClosing(DevToolsClientHost* client_host) = 0; | 56 virtual void ClientHostClosing(DevToolsClientHost* client_host) = 0; |
56 | 57 |
57 typedef base::Callback<void(DevToolsAgentHost*, bool attached)> Callback; | 58 typedef base::Callback<void(DevToolsAgentHost*, bool attached)> Callback; |
58 | 59 |
59 virtual void AddAgentStateCallback(const Callback& callback) = 0; | 60 virtual void AddAgentStateCallback(const Callback& callback) = 0; |
60 virtual void RemoveAgentStateCallback(const Callback& callback) = 0; | 61 virtual void RemoveAgentStateCallback(const Callback& callback) = 0; |
62 | |
63 // Opens the inspector for |agent_host|. | |
64 virtual void Inspect(BrowserContext* browser_context, | |
jam
2014/05/12 15:01:23
why is there a method on both DevToolsManager & De
horo
2014/05/12 16:21:48
Oh, we don't need this.
Removed Inspect() from Dev
| |
65 DevToolsAgentHost* agent_host) = 0; | |
61 }; | 66 }; |
62 | 67 |
63 } // namespace content | 68 } // namespace content |
64 | 69 |
65 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ | 70 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_ |
OLD | NEW |