[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
loislo at chromium.org
loislo at chromium.org
Wed Dec 22 11:21:54 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit fc2db78044d05fc8dfd7fef9367e714e37a8149f
Author: loislo at chromium.org <loislo at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Jul 20 17:53:44 2010 +0000
2010-07-20 Ilya Tikhonovsky <loislo at chromium.org>
Reviewed by Pavel Feldman.
WebInspector: It is possible to show full call stack instead of top frame for Caller
and Call Site properties in Timeline panel.
https://bugs.webkit.org/show_bug.cgi?id=42620
* English.lproj/localizedStrings.js:
* inspector/front-end/TimelinePanel.js:
(WebInspector.TimelinePanel.FormattedRecord):
(WebInspector.TimelinePanel.FormattedRecord.prototype._generatePopupContent):
(WebInspector.TimelinePanel.FormattedRecord.prototype._getRecordDetails):
(WebInspector.TimelinePanel.PopupContentHelper.prototype._appendElementRow):
(WebInspector.TimelinePanel.PopupContentHelper.prototype._appendLinkRow):
(WebInspector.TimelinePanel.PopupContentHelper.prototype._appendStackTrace):
* inspector/front-end/inspector.css:
(.timeline-details):
(.timeline-function-name):
(.timeline-stacktrace-title):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@63757 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index c85d801..1a76311 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,24 @@
+2010-07-20 Ilya Tikhonovsky <loislo at chromium.org>
+
+ Reviewed by Pavel Feldman.
+
+ WebInspector: It is possible to show full call stack instead of top frame for Caller
+ and Call Site properties in Timeline panel.
+ https://bugs.webkit.org/show_bug.cgi?id=42620
+
+ * English.lproj/localizedStrings.js:
+ * inspector/front-end/TimelinePanel.js:
+ (WebInspector.TimelinePanel.FormattedRecord):
+ (WebInspector.TimelinePanel.FormattedRecord.prototype._generatePopupContent):
+ (WebInspector.TimelinePanel.FormattedRecord.prototype._getRecordDetails):
+ (WebInspector.TimelinePanel.PopupContentHelper.prototype._appendElementRow):
+ (WebInspector.TimelinePanel.PopupContentHelper.prototype._appendLinkRow):
+ (WebInspector.TimelinePanel.PopupContentHelper.prototype._appendStackTrace):
+ * inspector/front-end/inspector.css:
+ (.timeline-details):
+ (.timeline-function-name):
+ (.timeline-stacktrace-title):
+
2010-07-20 Leon Clarke <leonclarke at google.com>
Reviewed by Pavel Feldman.
diff --git a/WebCore/English.lproj/localizedStrings.js b/WebCore/English.lproj/localizedStrings.js
index 8891a3c..010c28c 100644
Binary files a/WebCore/English.lproj/localizedStrings.js and b/WebCore/English.lproj/localizedStrings.js differ
diff --git a/WebCore/inspector/front-end/TimelinePanel.js b/WebCore/inspector/front-end/TimelinePanel.js
index 1f12625..8900d8d 100644
--- a/WebCore/inspector/front-end/TimelinePanel.js
+++ b/WebCore/inspector/front-end/TimelinePanel.js
@@ -841,10 +841,8 @@ WebInspector.TimelinePanel.FormattedRecord = function(record, parentRecord, pane
this._selfTime = this.endTime - this.startTime;
this._lastChildEndTime = this.endTime;
this.originalRecordForTests = record;
- if (record.stackTrace && record.stackTrace.length) {
- this.callerScriptName = record.stackTrace[0].scriptName;
- this.callerScriptLine = record.stackTrace[0].lineNumber;
- }
+ if (record.stackTrace && record.stackTrace.length)
+ this.stackTrace = record.stackTrace;
this.totalHeapSize = record.totalHeapSize;
this.usedHeapSize = record.usedHeapSize;
@@ -877,8 +875,7 @@ WebInspector.TimelinePanel.FormattedRecord = function(record, parentRecord, pane
} else if (record.type === recordTypes.TimerFire) {
var timerInstalledRecord = panel._timerRecords[record.data.timerId];
if (timerInstalledRecord) {
- this.callSiteScriptName = timerInstalledRecord.callerScriptName;
- this.callSiteScriptLine = timerInstalledRecord.callerScriptLine;
+ this.callSiteStackTrace = timerInstalledRecord.stackTrace;
this.timeout = timerInstalledRecord.timeout;
this.singleShot = timerInstalledRecord.singleShot;
}
@@ -940,8 +937,6 @@ WebInspector.TimelinePanel.FormattedRecord.prototype = {
contentHelper._appendTextRow(WebInspector.UIString("Timeout"), Number.secondsToString(this.timeout / 1000, WebInspector.UIString));
contentHelper._appendTextRow(WebInspector.UIString("Repeats"), !this.singleShot);
}
- if (typeof this.callSiteScriptLine === "number")
- contentHelper._appendLinkRow(WebInspector.UIString("Call Site"), this.callSiteScriptName, this.callSiteScriptLine);
break;
case recordTypes.FunctionCall:
contentHelper._appendLinkRow(WebInspector.UIString("Location"), this.data.scriptName, this.data.scriptLine);
@@ -979,12 +974,15 @@ WebInspector.TimelinePanel.FormattedRecord.prototype = {
if (this.data.scriptName && this.type !== recordTypes.FunctionCall)
contentHelper._appendLinkRow(WebInspector.UIString("Function Call"), this.data.scriptName, this.data.scriptLine);
- if (this.callerScriptName && this.type !== recordTypes.GCEvent)
- contentHelper._appendLinkRow(WebInspector.UIString("Caller"), this.callerScriptName, this.callerScriptLine);
-
if (this.usedHeapSize)
contentHelper._appendTextRow(WebInspector.UIString("Used Heap Size"), WebInspector.UIString("%s of %s", Number.bytesToString(this.usedHeapSize, WebInspector.UIString), Number.bytesToString(this.totalHeapSize, WebInspector.UIString)));
+ if (this.callSiteStackTrace && this.callSiteStackTrace.length)
+ contentHelper._appendStackTrace(WebInspector.UIString("Call Site stack"), this.callSiteStackTrace);
+
+ if (this.stackTrace)
+ contentHelper._appendStackTrace(WebInspector.UIString("Call Stack"), this.stackTrace);
+
return contentHelper._contentTable;
},
@@ -1003,10 +1001,10 @@ WebInspector.TimelinePanel.FormattedRecord.prototype = {
return record.data.width + "\u2009\u00d7\u2009" + record.data.height;
case WebInspector.TimelineAgent.RecordType.TimerInstall:
case WebInspector.TimelineAgent.RecordType.TimerRemove:
- return this.callerScriptName ? WebInspector.linkifyResourceAsNode(this.callerScriptName, "scripts", this.callerScriptLine, "", "") : record.data.timerId;
+ return this.stackTrace ? WebInspector.linkifyResourceAsNode(this.stackTrace[0].scriptName, "scripts", this.stackTrace[0].lineNumber, "", "") : record.data.timerId;
case WebInspector.TimelineAgent.RecordType.ParseHTML:
case WebInspector.TimelineAgent.RecordType.RecalculateStyles:
- return this.callerScriptName ? WebInspector.linkifyResourceAsNode(this.callerScriptName, "scripts", this.callerScriptLine, "", "") : null;
+ return this.stackTrace ? WebInspector.linkifyResourceAsNode(this.stackTrace[0].scriptName, "scripts", this.stackTrace[0].lineNumber, "", "") : null;
case WebInspector.TimelineAgent.RecordType.EvaluateScript:
return record.data.url ? WebInspector.linkifyResourceAsNode(record.data.url, "scripts", record.data.lineNumber, "", "") : null;
case WebInspector.TimelineAgent.RecordType.XHRReadyStateChange:
@@ -1075,11 +1073,15 @@ WebInspector.TimelinePanel.PopupContentHelper.prototype = {
this._contentTable.appendChild(row);
},
- _appendElementRow: function(title, content)
+ _appendElementRow: function(title, content, titleStyle)
{
var row = document.createElement("tr");
- row.appendChild(this._createCell(title, "timeline-details-row-title"));
+ var titleCell = this._createCell(title, "timeline-details-row-title");
+ if (titleStyle)
+ titleCell.addStyleClass(titleStyle);
+ row.appendChild(titleCell);
var cell = document.createElement("td");
+ cell.className = "timeline-details";
cell.appendChild(content);
row.appendChild(cell);
this._contentTable.appendChild(row);
@@ -1089,6 +1091,24 @@ WebInspector.TimelinePanel.PopupContentHelper.prototype = {
{
var link = WebInspector.linkifyResourceAsNode(scriptName, "scripts", scriptLine, "timeline-details");
this._appendElementRow(title, link);
+ },
+
+ _appendStackTrace: function(title, stackTrace)
+ {
+ this._appendTextRow("", "");
+ var framesTable = document.createElement("table");
+ for (var i = 0; i < stackTrace.length; ++i) {
+ var stackFrame = stackTrace[i];
+ var row = document.createElement("tr");
+ row.className = "timeline-details";
+ row.appendChild(this._createCell(stackFrame.functionName ? stackFrame.functionName : WebInspector.UIString("(anonymous function)"), "timeline-function-name"));
+ row.appendChild(this._createCell(" @ "));
+ var linkCell = document.createElement("td");
+ linkCell.appendChild(WebInspector.linkifyResourceAsNode(stackFrame.scriptName, "scripts", stackFrame.lineNumber, "timeline-details"));
+ row.appendChild(linkCell);
+ framesTable.appendChild(row);
+ }
+ this._appendElementRow(title, framesTable, "timeline-stacktrace-title");
}
}
diff --git a/WebCore/inspector/front-end/inspector.css b/WebCore/inspector/front-end/inspector.css
index 12e99b4..f1ee49f 100644
--- a/WebCore/inspector/front-end/inspector.css
+++ b/WebCore/inspector/front-end/inspector.css
@@ -3693,6 +3693,15 @@ body.inactive .sidebar-tree-item.selected .bubble.search-matches {
.timeline-details {
-webkit-user-select: text;
+ vertical-align: top;
+}
+
+.timeline-function-name {
+ text-align: right;
+}
+
+.timeline-stacktrace-title {
+ padding-top: 4px;
}
.timeline-details-row-title {
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list