Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1972)

Unified Diff: content/public/browser/devtools/devtools_manager.h

Issue 8549022: Define DevTools content API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments addressed Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/public/browser/devtools/devtools_manager.h
diff --git a/content/public/browser/devtools/devtools_manager.h b/content/public/browser/devtools/devtools_manager.h
new file mode 100644
index 0000000000000000000000000000000000000000..d2d4a7ca85b20c2981d40ebc844ec055ddc0713e
--- /dev/null
+++ b/content/public/browser/devtools/devtools_manager.h
@@ -0,0 +1,54 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_
+#define CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_
+#pragma once
+
+#include "content/common/content_export.h"
+
+class TabContents;
+
+namespace IPC {
+class Message;
+}
+
+namespace content {
+
+class DevToolsAgentHost;
+class DevToolsClientHost;
+
+class CONTENT_EXPORT DevToolsManager {
jam 2011/11/21 21:16:04 nit: comment about what this class is used for
yurys 2011/11/30 15:49:43 Done.
+ public:
+ static DevToolsManager* GetInstance();
+
+ virtual bool ForwardToDevToolsAgent(DevToolsClientHost* from,
jam 2011/11/21 21:16:04 nit: comment (also 36)
yurys 2011/11/30 15:49:43 Done.
+ const IPC::Message& message) = 0;
+
+ // Invoked when a tab is replaced by another tab. This is triggered by
+ // TabStripModel::ReplaceTabContentsAt.
+ virtual void TabReplaced(TabContents* old_tab, TabContents* new_tab) = 0;
+
+ // Closes all open developer tools windows.
+ virtual void CloseAllClientHosts() = 0;
+
+ virtual DevToolsClientHost* GetDevToolsClientHostFor(
+ DevToolsAgentHost* agent_host) = 0;
+
+ // Registers new DevToolsClientHost for inspected |agent_host|. There must be
+ // no other DevToolsClientHosts registered for the |agent_host| at the moment.
+ virtual void RegisterDevToolsClientHostFor(
+ DevToolsAgentHost* agent_host,
+ DevToolsClientHost* client_host) = 0;
+ virtual void UnregisterDevToolsClientHostFor(
+ DevToolsAgentHost* agent_host) = 0;
+
+ virtual void AttachClientHost(int client_host_cookie,
+ DevToolsAgentHost* to_agent) = 0;
+ virtual int DetachClientHost(DevToolsAgentHost* from_agent) = 0;
+};
+
+} // namespace content
+
+#endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_MANAGER_H_

Powered by Google App Engine
This is Rietveld 408576698