Diff
Modified: branches/safari-601-branch/Source/WebInspectorUI/ChangeLog (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/ChangeLog 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/ChangeLog 2015-12-03 19:00:29 UTC (rev 193235)
@@ -1,5 +1,37 @@
2015-12-02 Timothy Hatcher <[email protected]>
+ Merge r190376. rdar://problem/23221163
+
+ 2015-09-30 Joseph Pecoraro <[email protected]>
+
+ Web Inspector: Reduce `delete` in TreeElements and DataGridNodes
+ https://bugs.webkit.org/show_bug.cgi?id=149680
+
+ Reviewed by Timothy Hatcher.
+
+ * UserInterface/Views/BreakpointTreeElement.js:
+ (WebInspector.BreakpointTreeElement):
+ (WebInspector.BreakpointTreeElement.prototype._removeProbeSet):
+ * UserInterface/Views/DataGrid.js:
+ (WebInspector.DataGrid.prototype._editingCommitted.moveToNextCell):
+ (WebInspector.DataGrid.prototype._editingCommitted):
+ (WebInspector.DataGrid.prototype._editingCancelled):
+ (WebInspector.DataGrid.prototype.removeColumn):
+ (WebInspector.DataGridNode.prototype.refreshIfNeeded):
+ (WebInspector.DataGridNode.prototype.refresh):
+ (WebInspector.DataGridNode.prototype.expand):
+ (WebInspector.DataGridNode.prototype.restorePosition):
+ (WebInspector.DataGridNode):
+ * UserInterface/Views/GeneralTreeElement.js:
+ (WebInspector.GeneralTreeElement.prototype.ondetach):
+ * UserInterface/Views/ResourceTimelineDataGridNode.js:
+ (WebInspector.ResourceTimelineDataGridNode.prototype.refresh):
+ * UserInterface/Views/TreeOutline.js:
+ (WebInspector.TreeElement.prototype._fireDidChange):
+ (WebInspector.TreeElement.prototype.expand):
+
+2015-12-02 Timothy Hatcher <[email protected]>
+
Merge r190342. rdar://problem/23221163
2015-09-29 Joseph Pecoraro <[email protected]>
Modified: branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/BreakpointTreeElement.js (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/BreakpointTreeElement.js 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/BreakpointTreeElement.js 2015-12-03 19:00:29 UTC (rev 193235)
@@ -35,6 +35,7 @@
super(["breakpoint", className], title, null, breakpoint, false);
this._breakpoint = breakpoint;
+ this._probeSet = null;
this._listeners = new WebInspector.EventListenerSet(this, "BreakpointTreeElement listeners");
if (!title)
@@ -194,7 +195,7 @@
probeSet.removeEventListener(WebInspector.ProbeSet.Event.SamplesCleared, this._samplesCleared, this);
probeSet.dataTable.removeEventListener(WebInspector.ProbeSetDataTable.Event.FrameInserted, this._dataUpdated, this);
- delete this._probeSet;
+ this._probeSet = null;
}
_probeSetAdded(event)
Modified: branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/DataGrid.js (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/DataGrid.js 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/DataGrid.js 2015-12-03 19:00:29 UTC (rev 193235)
@@ -315,7 +315,7 @@
var moveCommand = determineNextCell.call(this, valueDidChange);
if (moveCommand.shouldSort && this._sortAfterEditingCallback) {
this._sortAfterEditingCallback();
- delete this._sortAfterEditingCallback;
+ this._sortAfterEditingCallback = null;
}
if (moveCommand.editingNode)
this._startEditingNodeAtColumnIndex(moveCommand.editingNode, moveCommand.columnIndex);
@@ -334,7 +334,7 @@
_editingCancelled(element)
{
console.assert(this._editingNode.element === element.enclosingNodeOrSelfWithNodeName("tr"));
- delete this._editing;
+ this._editing = false;
this._editingNode = null;
}
@@ -516,7 +516,7 @@
removedColumn["listeners"].uninstall(true);
if (removedColumn["disclosure"])
- delete this.disclosureColumnIdentifier;
+ this.disclosureColumnIdentifier = undefined;
if (this.sortColumnIdentifier === columnIdentifier)
this.sortColumnIdentifier = null;
@@ -1391,7 +1391,7 @@
if (!this._needsRefresh)
return;
- delete this._needsRefresh;
+ this._needsRefresh = false;
this.refresh();
}
@@ -1551,10 +1551,10 @@
if (this._scheduledRefreshIdentifier) {
cancelAnimationFrame(this._scheduledRefreshIdentifier);
- delete this._scheduledRefreshIdentifier;
+ this._scheduledRefreshIdentifier = undefined;
}
- delete this._needsRefresh;
+ this._needsRefresh = false;
this._element.removeChildren();
this.createCells();
@@ -1685,7 +1685,7 @@
}
}
- delete this._shouldRefreshChildren;
+ this._shouldRefreshChildren = false;
}
if (this._element)
@@ -1896,7 +1896,7 @@
if (this.parent !== this._savedPosition.parent)
this._savedPosition.parent.insertChild(this, this._savedPosition.index);
- delete this._savedPosition;
+ this._savedPosition = null;
}
};
Modified: branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/GeneralTreeElement.js (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/GeneralTreeElement.js 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/GeneralTreeElement.js 2015-12-03 19:00:29 UTC (rev 193235)
@@ -250,7 +250,7 @@
{
if (this._boundContextMenuEventHandler) {
this._listItemNode.removeEventListener("contextmenu", this._boundContextMenuEventHandler);
- delete this._boundContextMenuEventHandler;
+ this._boundContextMenuEventHandler = null;
}
}
Modified: branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/ResourceTimelineDataGridNode.js (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/ResourceTimelineDataGridNode.js 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/ResourceTimelineDataGridNode.js 2015-12-03 19:00:29 UTC (rev 193235)
@@ -127,10 +127,10 @@
{
if (this._scheduledRefreshIdentifier) {
cancelAnimationFrame(this._scheduledRefreshIdentifier);
- delete this._scheduledRefreshIdentifier;
+ this._scheduledRefreshIdentifier = undefined;
}
- delete this._cachedData;
+ this._cachedData = null;
super.refresh();
}
Modified: branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (193234 => 193235)
--- branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2015-12-03 19:00:23 UTC (rev 193234)
+++ branches/safari-601-branch/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2015-12-03 19:00:29 UTC (rev 193235)
@@ -690,7 +690,7 @@
_fireDidChange()
{
- delete this._didChangeTimeoutIdentifier;
+ this._didChangeTimeoutIdentifier = undefined;
if (this.treeOutline)
this.treeOutline._treeElementDidChange(this);
@@ -890,7 +890,7 @@
for (var i = 0; i < this.children.length; ++i)
this.children[i]._attach();
- delete this._shouldRefreshChildren;
+ this._shouldRefreshChildren = false;
}
if (this._listItemNode) {