Title: [200345] trunk/Source/WebInspectorUI
- Revision
- 200345
- Author
- commit-qu...@webkit.org
- Date
- 2016-05-02 16:07:21 -0700 (Mon, 02 May 2016)
Log Message
Web Inspector: Prefer "Console Evaluation" to "Eval Code" if we know it was a console evaluation
https://bugs.webkit.org/show_bug.cgi?id=157278
Patch by Joseph Pecoraro <pecor...@apple.com> on 2016-05-02
Reviewed by Timothy Hatcher.
* Localizations/en.lproj/localizedStrings.js:
"Console Evaluation" string.
* UserInterface/Controllers/DebuggerManager.js:
(WebInspector.DebuggerManager.prototype._sourceCodeLocationFromPayload): Deleted.
Delete an assert that would throw when the location is noSourceID:-1:-1.
* UserInterface/Models/CallFrame.js:
(WebInspector.CallFrame.fromDebuggerPayload):
(WebInspector.CallFrame.fromPayload):
(WebInspector.CallFrame):
When this is in a Console Evalution provide better values.
* UserInterface/Models/GarbageCollection.js:
(WebInspector.GarbageCollection):
Drive-by address a common assertions seen while paused.
Modified Paths
Diff
Modified: trunk/Source/WebInspectorUI/ChangeLog (200344 => 200345)
--- trunk/Source/WebInspectorUI/ChangeLog 2016-05-02 22:21:20 UTC (rev 200344)
+++ trunk/Source/WebInspectorUI/ChangeLog 2016-05-02 23:07:21 UTC (rev 200345)
@@ -1,3 +1,27 @@
+2016-05-02 Joseph Pecoraro <pecor...@apple.com>
+
+ Web Inspector: Prefer "Console Evaluation" to "Eval Code" if we know it was a console evaluation
+ https://bugs.webkit.org/show_bug.cgi?id=157278
+
+ Reviewed by Timothy Hatcher.
+
+ * Localizations/en.lproj/localizedStrings.js:
+ "Console Evaluation" string.
+
+ * UserInterface/Controllers/DebuggerManager.js:
+ (WebInspector.DebuggerManager.prototype._sourceCodeLocationFromPayload): Deleted.
+ Delete an assert that would throw when the location is noSourceID:-1:-1.
+
+ * UserInterface/Models/CallFrame.js:
+ (WebInspector.CallFrame.fromDebuggerPayload):
+ (WebInspector.CallFrame.fromPayload):
+ (WebInspector.CallFrame):
+ When this is in a Console Evalution provide better values.
+
+ * UserInterface/Models/GarbageCollection.js:
+ (WebInspector.GarbageCollection):
+ Drive-by address a common assertions seen while paused.
+
2016-05-02 Nikita Vasilyev <nvasil...@apple.com>
Web Inspector: Adding a new console message shouldn't modify DOM when the console log is hidden
Modified: trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js (200344 => 200345)
--- trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2016-05-02 22:21:20 UTC (rev 200344)
+++ trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2016-05-02 23:07:21 UTC (rev 200345)
@@ -181,6 +181,7 @@
localizedStrings["Condition"] = "Condition";
localizedStrings["Conditional _expression_"] = "Conditional _expression_";
localizedStrings["Console"] = "Console";
+localizedStrings["Console Evaluation"] = "Console Evaluation";
localizedStrings["Console Evaluation %d"] = "Console Evaluation %d";
localizedStrings["Console Profile Recorded"] = "Console Profile Recorded";
localizedStrings["Console errors, click to show the Console tab"] = "Console errors, click to show the Console tab";
Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/DebuggerManager.js (200344 => 200345)
--- trunk/Source/WebInspectorUI/UserInterface/Controllers/DebuggerManager.js 2016-05-02 22:21:20 UTC (rev 200344)
+++ trunk/Source/WebInspectorUI/UserInterface/Controllers/DebuggerManager.js 2016-05-02 23:07:21 UTC (rev 200345)
@@ -633,7 +633,6 @@
_sourceCodeLocationFromPayload(payload)
{
let script = this._scriptIdMap.get(payload.scriptId);
- console.assert(script);
if (!script)
return null;
Modified: trunk/Source/WebInspectorUI/UserInterface/Models/CallFrame.js (200344 => 200345)
--- trunk/Source/WebInspectorUI/UserInterface/Models/CallFrame.js 2016-05-02 22:21:20 UTC (rev 200344)
+++ trunk/Source/WebInspectorUI/UserInterface/Models/CallFrame.js 2016-05-02 23:07:21 UTC (rev 200345)
@@ -133,6 +133,11 @@
let nativeCode = false;
let programCode = WebInspector.CallFrame.programCodeFromPayload(payload);
+ if (sourceCodeLocation && isWebInspectorConsoleEvaluationScript(sourceCodeLocation.sourceCode.sourceURL)) {
+ functionName = WebInspector.UIString("Console Evaluation");
+ programCode = true;
+ }
+
return new WebInspector.CallFrame(id, sourceCodeLocation, functionName, thisObject, scopeChain, nativeCode, programCode);
}
@@ -173,6 +178,11 @@
}
}
+ if (sourceCodeLocation && isWebInspectorConsoleEvaluationScript(sourceCodeLocation.sourceCode.sourceURL)) {
+ functionName = WebInspector.UIString("Console Evaluation");
+ programCode = true;
+ }
+
return new WebInspector.CallFrame(null, sourceCodeLocation, functionName, null, null, nativeCode, programCode);
}
};
Modified: trunk/Source/WebInspectorUI/UserInterface/Models/GarbageCollection.js (200344 => 200345)
--- trunk/Source/WebInspectorUI/UserInterface/Models/GarbageCollection.js 2016-05-02 22:21:20 UTC (rev 200344)
+++ trunk/Source/WebInspectorUI/UserInterface/Models/GarbageCollection.js 2016-05-02 23:07:21 UTC (rev 200345)
@@ -29,7 +29,7 @@
{
super();
- console.assert(endTime > startTime);
+ console.assert(endTime >= startTime);
this._type = type;
this._startTime = startTime;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes