Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(989)

Unified Diff: Source/devtools/front_end/elements/ElementsTreeOutline.js

Issue 301163005: DevTools: [JSDoc] Avoid partial arg list annotations in code except "profiler" module (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/devtools/front_end/elements/ElementsPanel.js ('k') | Source/devtools/front_end/elements/Spectrum.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/elements/ElementsTreeOutline.js
diff --git a/Source/devtools/front_end/elements/ElementsTreeOutline.js b/Source/devtools/front_end/elements/ElementsTreeOutline.js
index 4376e7e38b51789214f38ad1346b10d0f63dcef4..1e91339b01318cf04e1e654d1b2c20cfcc1a4617 100644
--- a/Source/devtools/front_end/elements/ElementsTreeOutline.js
+++ b/Source/devtools/front_end/elements/ElementsTreeOutline.js
@@ -834,6 +834,7 @@ WebInspector.ElementsTreeOutline.PseudoStateDecorator.prototype = {
/**
* @constructor
* @extends {TreeElement}
+ * @param {!WebInspector.DOMNode} node
* @param {boolean=} elementCloseTag
*/
WebInspector.ElementsTreeElement = function(node, elementCloseTag)
@@ -1059,6 +1060,8 @@ WebInspector.ElementsTreeElement.prototype = {
},
/**
+ * @param {!WebInspector.DOMNode} child
+ * @param {number} index
* @param {boolean=} closingTag
* @return {!WebInspector.ElementsTreeElement}
*/
@@ -1668,6 +1671,11 @@ WebInspector.ElementsTreeElement.prototype = {
return true;
},
+ /**
+ * @param {function(string, string)} commitCallback
+ * @param {?Protocol.Error} error
+ * @param {string} initialValue
+ */
_startEditingAsHTML: function(commitCallback, error, initialValue)
{
if (error)
@@ -2151,12 +2159,13 @@ WebInspector.ElementsTreeElement.prototype = {
switch (node.nodeType()) {
case Node.ATTRIBUTE_NODE:
- this._buildAttributeDOM(info.titleDOM, node.name, node.value, true);
+ this._buildAttributeDOM(info.titleDOM, /** @type {string} */ (node.name), /** @type {string} */ (node.value), true);
break;
case Node.ELEMENT_NODE:
- if (node.pseudoType()) {
- this._buildPseudoElementDOM(info.titleDOM, node.pseudoType());
+ var pseudoType = node.pseudoType();
+ if (pseudoType) {
+ this._buildPseudoElementDOM(info.titleDOM, pseudoType);
info.hasChildren = false;
break;
}
@@ -2286,7 +2295,7 @@ WebInspector.ElementsTreeElement.prototype = {
return;
var self = this;
- function removeNodeCallback(error, removedNodeId)
+ function removeNodeCallback(error)
{
if (error)
return;
@@ -2311,7 +2320,10 @@ WebInspector.ElementsTreeElement.prototype = {
var index = node.index;
var wasExpanded = this.expanded;
- function selectNode(error, nodeId)
+ /**
+ * @param {?Protocol.Error} error
+ */
+ function selectNode(error)
{
if (error)
return;
@@ -2332,12 +2344,14 @@ WebInspector.ElementsTreeElement.prototype = {
}
}
+ /**
+ * @param {string} initialValue
+ * @param {string} value
+ */
function commitChange(initialValue, value)
{
if (initialValue !== value)
node.setOuterHTML(value, selectNode);
- else
- return;
}
node.getOuterHTML(this._startEditingAsHTML.bind(this, commitChange));
@@ -2407,7 +2421,7 @@ WebInspector.ElementsTreeElement.prototype = {
},
/**
- * @return {!Array.<!WebInspector.DOMModel>}
+ * @return {!Array.<!WebInspector.DOMNode>}
*/
_visibleShadowRoots: function()
{
« no previous file with comments | « Source/devtools/front_end/elements/ElementsPanel.js ('k') | Source/devtools/front_end/elements/Spectrum.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698