Changeset 95614 in webkit


Ignore:
Timestamp:
Sep 21, 2011 4:50:05 AM (13 years ago)
Author:
pfeldman@chromium.org
Message:

Web Inspector: minor fixes in the DOM domain of the protocol.
https://bugs.webkit.org/show_bug.cgi?id=68517

Reviewed by Yury Semikhatsky.

  • inspector/Inspector.json:
  • inspector/InspectorDOMAgent.cpp:

(WebCore::InspectorDOMAgent::setAttributesAsText):

  • inspector/InspectorDOMAgent.h:
  • inspector/front-end/DOMAgent.js:

(WebInspector.DOMNode.prototype.setAttribute):

Location:
trunk/Source/WebCore
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r95613 r95614  
     12011-09-21  Pavel Feldman  <pfeldman@google.com>
     2
     3        Web Inspector: minor fixes in the DOM domain of the protocol.
     4        https://bugs.webkit.org/show_bug.cgi?id=68517
     5
     6        Reviewed by Yury Semikhatsky.
     7
     8        * inspector/Inspector.json:
     9        * inspector/InspectorDOMAgent.cpp:
     10        (WebCore::InspectorDOMAgent::setAttributesAsText):
     11        * inspector/InspectorDOMAgent.h:
     12        * inspector/front-end/DOMAgent.js:
     13        (WebInspector.DOMNode.prototype.setAttribute):
     14
    1152011-09-16  Pavel Feldman  <pfeldman@google.com>
    216
  • trunk/Source/WebCore/inspector/Inspector.json

    r95613 r95614  
    837837    {
    838838        "domain": "DOM",
    839         "description": "This domain exposes DOM read/write operations. Each DOM Node is represented with its mirror object that has an <code>id</code>. This <code>id</code> can be used to get additional information on the Node, convert it into the JavaScript object, etc. It is important that client receives DOM events only for the nodes that are known to the client. Backend keeps track of the nodes that were sent to the client and never sends the same node twice. It is client's responsibility to collect information about the nodes that were sent to the client.",
     839        "description": "This domain exposes DOM read/write operations. Each DOM Node is represented with its mirror object that has an <code>id</code>. This <code>id</code> can be used to get additional information on the Node, resolve it into the JavaScript object wrapper, etc. It is important that client receives DOM events only for the nodes that are known to the client. Backend keeps track of the nodes that were sent to the client and never sends the same node twice. It is client's responsibility to collect information about the nodes that were sent to the client.<p>Note that <code>iframe</code> owner elements will return corresponding document elements as their child nodes.</p>",
    840840        "types": [
    841841            {
     
    951951                ],
    952952                "returns": [
    953                     { "name": "outNodeId", "$ref": "NodeId", "description": "New node's id." }
     953                    { "name": "nodeId", "$ref": "NodeId", "description": "New node's id." }
    954954                ],
    955955                "description": "Sets node name for a node with given id."
     
    980980            },
    981981            {
    982                 "name": "setAttributesText",
     982                "name": "setAttributesAsText",
    983983                "parameters": [
    984984                    { "name": "nodeId", "$ref": "NodeId", "description": "Id of the element to set attributes for." },
     
    10321032                ],
    10331033                "returns": [
    1034                     { "name": "newNodeId", "$ref": "NodeId", "description": "Setting outer HTML can change node's id." }
     1034                    { "name": "nodeId", "$ref": "NodeId", "description": "Setting outer HTML can change node's id." }
    10351035                ],
    10361036                "description": "Sets node HTML markup, returns new node id."
     
    10581058                    { "name": "nodeId", "$ref": "NodeId", "description": "Node id for given object." }
    10591059                ],
    1060                 "description": "Requests that the node is sent to the caller given the JavaScript node object reference."
     1060                "description": "Requests that the node is sent to the caller given the JavaScript node object reference. All nodes that form the path from the node to the root are also sent to the client as a series of <code>setChildNodes</code> notifications."
    10611061            },
    10621062            {
     
    11331133                    { "name": "attributes", "type": "array", "items": { "type": "string" }, "description": "An interleaved array of node attribute names and values." }
    11341134                ],
    1135                 "description": "Returns attributes for the specified nodes."
     1135                "description": "Returns attributes for the specified node."
    11361136            },
    11371137            {
     
    11401140                    { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to drop." },
    11411141                    { "name": "targetNodeId", "$ref": "NodeId", "description": "Id of the element to drop into." },
    1142                     { "name": "anchorNodeId", "$ref": "NodeId", "optional": true, "description": "Drop node before given one." }
     1142                    { "name": "insertBeforeNodeId", "$ref": "NodeId", "optional": true, "description": "Drop node before given one." }
    11431143                ],
    11441144                "returns": [
     
    11791179                "parameters": [
    11801180                    { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
    1181                     { "name": "newValue", "type": "string", "description": "New text value." }
     1181                    { "name": "characterData", "type": "string", "description": "New text value." }
    11821182                ],
    11831183                "description": "Mirrors <code>DOMCharacterDataModified</code> event."
     
    11871187                "parameters": [
    11881188                    { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
    1189                     { "name": "newValue", "type": "integer", "description": "New node count." }
     1189                    { "name": "childNodeCount", "type": "integer", "description": "New node count." }
    11901190                ],
    11911191                "description": "Fired when <code>Container</code>'s child node count has changed."
  • trunk/Source/WebCore/inspector/InspectorDOMAgent.cpp

    r95372 r95614  
    625625}
    626626
    627 void InspectorDOMAgent::setAttributesText(ErrorString* errorString, int elementId, const String& text, const String* const name)
     627void InspectorDOMAgent::setAttributesAsText(ErrorString* errorString, int elementId, const String& text, const String* const name)
    628628{
    629629    Element* element = assertElement(errorString, elementId);
  • trunk/Source/WebCore/inspector/InspectorDOMAgent.h

    r93608 r95614  
    119119    void requestChildNodes(ErrorString*, int nodeId);
    120120    void setAttributeValue(ErrorString*, int elementId, const String& name, const String& value);
    121     void setAttributesText(ErrorString*, int elementId, const String& text, const String* const name);
     121    void setAttributesAsText(ErrorString*, int elementId, const String& text, const String* const name);
    122122    void removeAttribute(ErrorString*, int elementId, const String& name);
    123123    void removeNode(ErrorString*, int nodeId);
  • trunk/Source/WebCore/inspector/front-end/DOMAgent.js

    r94754 r95614  
    133133    setAttribute: function(name, text, callback)
    134134    {
    135         DOMAgent.setAttributesText(this.id, text, name, callback);
     135        DOMAgent.setAttributesAsText(this.id, text, name, callback);
    136136    },
    137137
Note: See TracChangeset for help on using the changeset viewer.