diff options
author | pfeldman@chromium.org <pfeldman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-24 13:54:28 +0000 |
---|---|---|
committer | pfeldman@chromium.org <pfeldman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-24 13:54:28 +0000 |
commit | d0ef30f4636680ba1ca213d72bb13540fb5ce7f2 (patch) | |
tree | 5c76b111a2e8a54e7d6343cdf56d6eec4b3cd75b /webkit/glue/devtools/js/devtools.js | |
parent | 8ee332ca459d463eecb7807ecd966eda13be0456 (diff) | |
download | chromium_src-d0ef30f4636680ba1ca213d72bb13540fb5ce7f2.zip chromium_src-d0ef30f4636680ba1ca213d72bb13540fb5ce7f2.tar.gz chromium_src-d0ef30f4636680ba1ca213d72bb13540fb5ce7f2.tar.bz2 |
Wire 'Inspect Element' action to the new DevTools (depending on the devtools flag):
- Add new devtools IPC message
- Expose WebView's hit target
- Refactor dom_agent interaction not to send information known to client
- Collect incoming messages on the client until frontend is loaded
- Add Inspect Element scenario into the devtools_host_stub
Review URL: http://codereview.chromium.org/45022
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12355 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/devtools/js/devtools.js')
-rw-r--r-- | webkit/glue/devtools/js/devtools.js | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/webkit/glue/devtools/js/devtools.js b/webkit/glue/devtools/js/devtools.js index 4ef1c14..33d23a9 100644 --- a/webkit/glue/devtools/js/devtools.js +++ b/webkit/glue/devtools/js/devtools.js @@ -13,13 +13,14 @@ goog.require('devtools.DomAgent'); goog.require('devtools.NetAgent'); devtools.ToolsAgent = function() { - + RemoteToolsAgent.UpdateFocusedNode = + goog.bind(this.updateFocusedNode, this); }; // ToolsAgent implementation. devtools.ToolsAgent.prototype.updateFocusedNode = function(node_id) { - var node = dom.getNodeForId(node_id); + var node = domAgent.getNodeForId(node_id); WebInspector.updateFocusedNode(node); }; @@ -49,10 +50,10 @@ WebInspector.loaded = function() { netAgent = new devtools.NetAgent(); toolsAgent = new devtools.ToolsAgent(); - oldLoaded.call(this); Preferences.ignoreWhitespace = false; toolsAgent.setDomAgentEnabled(true); toolsAgent.setNetAgentEnabled(true); + oldLoaded.call(this); domAgent.getDocumentElementAsync(); }; @@ -61,7 +62,8 @@ var webkitUpdateChildren = WebInspector.ElementsTreeElement.prototype.updateChildren; WebInspector.ElementsTreeElement.prototype.updateChildren = function() { - domAgent.getChildNodesAsync( - this.representedObject.id, - goog.bind(webkitUpdateChildren, this)); + var self = this; + domAgent.getChildNodesAsync(this.representedObject.id, function() { + webkitUpdateChildren.call(self); + }); }; |