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

Unified Diff: Source/devtools/front_end/treeoutline.js

Issue 22548006: DevTools: Improve performance of the element breadcrumbs. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fixed the test Created 7 years, 4 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/ElementsTreeOutline.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/treeoutline.js
diff --git a/Source/devtools/front_end/treeoutline.js b/Source/devtools/front_end/treeoutline.js
index 37f0b0f18b6769062b2c79d0f9065f249cb6c089..bf17bc05bc13c61aa82a5cadd6f50e0c85d7e917 100644
--- a/Source/devtools/front_end/treeoutline.js
+++ b/Source/devtools/front_end/treeoutline.js
@@ -51,9 +51,9 @@ function TreeOutline(listNode, nonFocusable)
this.setFocusable(!nonFocusable);
this._childrenListNode.addEventListener("keydown", this._treeKeyDown.bind(this), true);
- /** @type {!Map.<Object, !Array.<!TreeElement>>} */
+ /** @type {!Map.<!Object, !Array.<!TreeElement>>} */
this._treeElementsMap = new Map();
- /** @type {!Map.<Object, boolean>} */
+ /** @type {!Map.<!Object, boolean>} */
this._expandedStateMap = new Map();
}
@@ -265,6 +265,10 @@ TreeOutline.prototype._forgetChildrenRecursive = function(parentElement)
}
}
+/**
+ * @param {Object} representedObject
+ * @return {TreeElement}
+ */
TreeOutline.prototype.getCachedTreeElement = function(representedObject)
{
if (!representedObject)
@@ -276,6 +280,10 @@ TreeOutline.prototype.getCachedTreeElement = function(representedObject)
return null;
}
+/**
+ * @param {Object} representedObject
+ * @return {TreeElement}
+ */
TreeOutline.prototype.findTreeElement = function(representedObject, isAncestor, getParent)
{
if (!representedObject)
@@ -306,6 +314,11 @@ TreeOutline.prototype.findTreeElement = function(representedObject, isAncestor,
return this.getCachedTreeElement(representedObject);
}
+/**
+ * @param {number} x
+ * @param {number} y
+ * @return {TreeElement}
+ */
TreeOutline.prototype.treeElementFromPoint = function(x, y)
{
var node = this._childrenListNode.ownerDocument.elementFromPoint(x, y);
« no previous file with comments | « Source/devtools/front_end/ElementsTreeOutline.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698