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

Unified Diff: content/browser/debugger/devtools_window.h

Issue 7322004: DevTools: devtools manager should know nothing about DevToolsWindow (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments addressed Created 9 years, 5 months 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
« no previous file with comments | « content/browser/debugger/devtools_sanity_unittest.cc ('k') | content/browser/debugger/devtools_window.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/debugger/devtools_window.h
diff --git a/content/browser/debugger/devtools_window.h b/content/browser/debugger/devtools_window.h
index 744d1d334eaf8508c7aa7a8ad8b1a24b5b23a41f..fbe6409509cee4a8609fae94f8156f2db0f7010b 100644
--- a/content/browser/debugger/devtools_window.h
+++ b/content/browser/debugger/devtools_window.h
@@ -7,6 +7,7 @@
#pragma once
#include <string>
+#include <vector>
#include "base/basictypes.h"
#include "content/browser/debugger/devtools_client_host.h"
@@ -32,12 +33,16 @@ class DevToolsWindow
public:
static const char kDevToolsApp[];
static TabContentsWrapper* GetDevToolsContents(TabContents* inspected_tab);
+ static DevToolsWindow* FindDevToolsWindow(RenderViewHost* window_rvh);
+
+ static DevToolsWindow* OpenDevToolsWindow(RenderViewHost* inspected_rvh);
+ static DevToolsWindow* ToggleDevToolsWindow(RenderViewHost* inspected_rvh,
+ DevToolsToggleAction action);
+ static void InspectElement(RenderViewHost* inspected_rvh, int x, int y);
- DevToolsWindow(Profile* profile, RenderViewHost* inspected_rvh, bool docked);
virtual ~DevToolsWindow();
// Overridden from DevToolsClientHost.
- virtual DevToolsWindow* AsDevToolsWindow();
virtual void SendMessageToClient(const IPC::Message& message);
virtual void InspectedTabClosing();
virtual void TabReplaced(TabContentsWrapper* new_tab);
@@ -53,6 +58,8 @@ class DevToolsWindow
bool is_docked() { return docked_; }
private:
+ DevToolsWindow(Profile* profile, RenderViewHost* inspected_rvh, bool docked);
+
void CreateDevToolsBrowser();
bool FindInspectedBrowserAndTabIndex(Browser**, int* tab);
BrowserWindow* GetInspectedBrowserWindow();
@@ -90,6 +97,11 @@ class DevToolsWindow
virtual void FrameNavigating(const std::string& url) {}
+ static DevToolsWindow* ToggleDevToolsWindow(RenderViewHost* inspected_rvh,
+ bool force_open,
+ DevToolsToggleAction action);
+ static DevToolsWindow* AsDevToolsWindow(DevToolsClientHost*);
+
Profile* profile_;
TabContentsWrapper* inspected_tab_;
TabContentsWrapper* tab_contents_;
@@ -98,6 +110,8 @@ class DevToolsWindow
bool is_loaded_;
DevToolsToggleAction action_on_load_;
NotificationRegistrar registrar_;
+ typedef std::vector<DevToolsWindow*> DevToolsWindowList;
+ static DevToolsWindowList instances_;
DISALLOW_COPY_AND_ASSIGN(DevToolsWindow);
};
« no previous file with comments | « content/browser/debugger/devtools_sanity_unittest.cc ('k') | content/browser/debugger/devtools_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698