Web Inspector: track HTML revisions when editing DOM and / or upon free flow edits.
authorpfeldman@chromium.org <pfeldman@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 18 Jan 2012 12:52:46 +0000 (12:52 +0000)
committerpfeldman@chromium.org <pfeldman@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 18 Jan 2012 12:52:46 +0000 (12:52 +0000)
commitad8cf71d15dd9844b0f541aa3dbe65993b33c1a7
treee5295f302c0241f871b83dc9edad05900da0f308
parent791e9d48ee838088c82dfcea87078224b8ae95c6
Web Inspector: track HTML revisions when editing DOM and / or upon free flow edits.
https://bugs.webkit.org/show_bug.cgi?id=76457

Reviewed by Yury Semikhatsky.

Source/WebCore:

Test: inspector/elements/set-html-via-resource.html

* inspector/DOMEditor.cpp:
(WebCore::DOMEditor::patchNode):
* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::getOuterHTML):
(WebCore::InspectorDOMAgent::setOuterHTML):
(WebCore::InspectorDOMAgent::buildObjectForNode):
* inspector/front-end/DOMAgent.js:
(WebInspector.DOMNode):
(WebInspector.DOMNode.prototype.setNodeName):
(WebInspector.DOMNode.prototype.setNodeValue):
(WebInspector.DOMNode.prototype.setAttribute):
(WebInspector.DOMNode.prototype.setAttributeValue):
(WebInspector.DOMNode.prototype.removeAttribute):
(WebInspector.DOMNode.prototype.getChildNodes.mycallback):
(WebInspector.DOMNode.prototype.getChildNodes):
(WebInspector.DOMNode.prototype.setOuterHTML):
(WebInspector.DOMNode.prototype.removeNode):
(WebInspector.DOMNode.prototype.moveTo):
(WebInspector.DOMDocument):
(WebInspector.DOMAgent):
(WebInspector.DOMAgent.prototype._setDocument):
(WebInspector.DOMAgent.prototype._buildHighlightConfig):
(WebInspector.DOMAgent.prototype._markRevision):
(WebInspector.DOMAgent.prototype._captureDOM.callback):
(WebInspector.DOMAgent.prototype._captureDOM):
(WebInspector.DOMModelResourceBinding.prototype.setContent):
(WebInspector.DOMModelResourceBinding.prototype.setContent.setOuterHTML):
(WebInspector.DOMModelResourceBinding.prototype.setContent.withDocument):
* inspector/front-end/ElementsTreeOutline.js:
(WebInspector.ElementsTreeElement.prototype._attributeEditingCommitted):

LayoutTests:

* inspector/elements/resources/set-outer-html-body-iframe.html:
* inspector/elements/set-html-via-resource-expected.txt: Added.
* inspector/elements/set-html-via-resource.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@105262 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/inspector/inspector-test.js
LayoutTests/inspector/elements/edit-dom-actions-expected.txt
LayoutTests/inspector/elements/set-html-via-resource-expected.txt [new file with mode: 0644]
LayoutTests/inspector/elements/set-html-via-resource.html [new file with mode: 0644]
LayoutTests/inspector/elements/set-outer-html-test.js
Source/WebCore/ChangeLog
Source/WebCore/inspector/DOMEditor.cpp
Source/WebCore/inspector/InspectorDOMAgent.cpp
Source/WebCore/inspector/front-end/DOMAgent.js
Source/WebCore/inspector/front-end/ElementsTreeOutline.js
Source/WebCore/inspector/front-end/Settings.js