From f85d541dfff6b40ede739d3c0c3094ba420bafa2 Mon Sep 17 00:00:00 2001 From: "yurys@google.com" Date: Tue, 17 Mar 2009 12:05:48 +0000 Subject: Initial unit tests implementation. Review URL: http://codereview.chromium.org/42233 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11855 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/debugger/devtools_manager.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'chrome/browser/debugger/devtools_manager.h') diff --git a/chrome/browser/debugger/devtools_manager.h b/chrome/browser/debugger/devtools_manager.h index ebacc5e..ce6ee73 100644 --- a/chrome/browser/debugger/devtools_manager.h +++ b/chrome/browser/debugger/devtools_manager.h @@ -15,8 +15,10 @@ namespace IPC { class Message; } +class DevToolsInstanceDescriptor; class DevToolsInstanceDescriptorImpl; class DevToolsWindow; +class DevToolsWindowFactory; class NavigationController; class NotificationRegistrar; class RenderViewHost; @@ -26,7 +28,9 @@ class WebContents; // messages between developer tools clients and agents. class DevToolsManager : public NotificationObserver { public: - DevToolsManager(); + // If the factory is NULL, this will create DevToolsWindow objects using + // DevToolsWindow::Create static method. + DevToolsManager(DevToolsWindowFactory* factory); virtual ~DevToolsManager(); // Opend developer tools window for |web_contents|. If there is already @@ -43,6 +47,11 @@ class DevToolsManager : public NotificationObserver { const IPC::Message& message); private: + // Creates a DevToolsWindow using devtools_window_factory_ or by calling + // DevToolsWindow::Create, if the factory is NULL. All DevToolsWindows should + // be created by means of this method. + DevToolsWindow* CreateDevToolsWindow(DevToolsInstanceDescriptor* descriptor); + // NotificationObserver override. virtual void Observe(NotificationType type, const NotificationSource& source, @@ -72,6 +81,7 @@ class DevToolsManager : public NotificationObserver { typedef std::map DescriptorMap; DescriptorMap navcontroller_to_descriptor_; + DevToolsWindowFactory* devtools_window_factory_; DISALLOW_COPY_AND_ASSIGN(DevToolsManager); }; -- cgit v1.1