summaryrefslogtreecommitdiffstats
path: root/src/core/dev_tools_http_handler_delegate_qt.h
diff options
context:
space:
mode:
authorJocelyn Turcotte <jocelyn.turcotte@digia.com>2015-01-14 12:19:41 +0100
committerJocelyn Turcotte <jocelyn.turcotte@digia.com>2015-01-22 16:22:03 +0100
commit9d9268ae1ce34a853b48d3b7189dba6448c38033 (patch)
tree57a070c5b8d9653bdff472b9b98aa5ceacc7909e /src/core/dev_tools_http_handler_delegate_qt.h
parent9c852a048ebce776fba08a668e4e45251f987d10 (diff)
Fix the inspector after the 40 update
Update our copy of the DevTools code according to the modifications in Chromium 40. Add a DevToolsManagerDelegate subclass to re-add the target enumeration code and import the new shell Target code. Change-Id: I8c56faaf4dd77ca8f4129fcdc80690c7a117464b Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
Diffstat (limited to 'src/core/dev_tools_http_handler_delegate_qt.h')
-rw-r--r--src/core/dev_tools_http_handler_delegate_qt.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/core/dev_tools_http_handler_delegate_qt.h b/src/core/dev_tools_http_handler_delegate_qt.h
index 0a28cf5c6..bbee613a2 100644
--- a/src/core/dev_tools_http_handler_delegate_qt.h
+++ b/src/core/dev_tools_http_handler_delegate_qt.h
@@ -38,6 +38,7 @@
#define DEV_TOOLS_HTTP_HANDLER_DELEGATE_QT_H
#include "content/public/browser/devtools_http_handler_delegate.h"
+#include "content/public/browser/devtools_manager_delegate.h"
#include <QtCore/qcompilerdetection.h> // needed for Q_DECL_OVERRIDE
@@ -63,11 +64,21 @@ public:
virtual base::FilePath GetDebugFrontendDir() Q_DECL_OVERRIDE;
// Requests the list of all inspectable targets.
// The caller gets the ownership of the returned targets.
- virtual scoped_ptr<net::StreamListenSocket> CreateSocketForTethering(net::StreamListenSocket::Delegate* delegate, std::string* name) Q_DECL_OVERRIDE;
+ virtual scoped_ptr<net::StreamListenSocket> CreateSocketForTethering(net::StreamListenSocket::Delegate *delegate, std::string *name) Q_DECL_OVERRIDE;
private:
content::BrowserContext* m_browserContext;
- content::DevToolsHttpHandler* m_devtoolsHttpHandler;
+ content::DevToolsHttpHandler *m_devtoolsHttpHandler;
+};
+
+class DevToolsManagerDelegateQt : public content::DevToolsManagerDelegate {
+public:
+ void Inspect(content::BrowserContext *browser_context, content::DevToolsAgentHost *agent_host) Q_DECL_OVERRIDE { }
+ void DevToolsAgentStateChanged(content::DevToolsAgentHost *agent_host, bool attached) Q_DECL_OVERRIDE { }
+ base::DictionaryValue *HandleCommand(content::DevToolsAgentHost *agent_host, base::DictionaryValue *command) Q_DECL_OVERRIDE;
+ scoped_ptr<content::DevToolsTarget> CreateNewTarget(const GURL &url) Q_DECL_OVERRIDE;
+ void EnumerateTargets(TargetCallback callback) Q_DECL_OVERRIDE;
+ std::string GetPageThumbnailData(const GURL &url) Q_DECL_OVERRIDE;
};
#endif // DEV_TOOLS_HTTP_HANDLER_DELEGATE_QT_H