Title: [134928] trunk
Revision
134928
Author
yu...@chromium.org
Date
2012-11-16 04:04:52 -0800 (Fri, 16 Nov 2012)

Log Message

Web Inspector: don't show an Error when evaluating a watch _expression_ results in an exception
https://bugs.webkit.org/show_bug.cgi?id=102470

Reviewed by Vsevolod Vlasov.

Source/WebCore:

Dim watch _expression_ and show "<not available>" as its value in cases when it evaluates
into an exception.

* English.lproj/localizedStrings.js:
* inspector/front-end/WatchExpressionsSidebarPane.js:
(WebInspector.WatchExpressionTreeElement.prototype.update):
* inspector/front-end/inspector.css:

LayoutTests:

Check that watch _expression_ has value "<not available>" in case of exception
during its evaluation instead of a special style class tha has been removed.

* inspector/debugger/error-in-watch-expressions.html:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (134927 => 134928)


--- trunk/LayoutTests/ChangeLog	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/LayoutTests/ChangeLog	2012-11-16 12:04:52 UTC (rev 134928)
@@ -1,3 +1,15 @@
+2012-11-16  Yury Semikhatsky  <yu...@chromium.org>
+
+        Web Inspector: don't show an Error when evaluating a watch _expression_ results in an exception
+        https://bugs.webkit.org/show_bug.cgi?id=102470
+
+        Reviewed by Vsevolod Vlasov.
+
+        Check that watch _expression_ has value "<not available>" in case of exception
+        during its evaluation instead of a special style class tha has been removed.
+
+        * inspector/debugger/error-in-watch-expressions.html:
+
 2012-11-16  Elliott Sprehn  <espr...@chromium.org>
 
         REGRESSION (r134774-r134779): fast/frames/detached-shadow-frame.html failing on Apple Win 7 Release (Tests)

Modified: trunk/LayoutTests/inspector/debugger/error-in-watch-expressions.html (134927 => 134928)


--- trunk/LayoutTests/inspector/debugger/error-in-watch-expressions.html	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/LayoutTests/inspector/debugger/error-in-watch-expressions.html	2012-11-16 12:04:52 UTC (rev 134928)
@@ -19,7 +19,7 @@
 
     function step1()
     {
-        InspectorTest.addResult(watchExpressionsSection.element.innerHTML.indexOf("watch-expressions-error-level") !== -1 ? "SUCCESS" : "FAILED");
+        InspectorTest.addResult(watchExpressionsSection.element.textContent.indexOf("<not available>") !== -1 ? "SUCCESS" : "FAILED");
 
         // Clear watch expressions after execution.
         watchExpressionsSection.watchExpressions = [];

Modified: trunk/Source/WebCore/ChangeLog (134927 => 134928)


--- trunk/Source/WebCore/ChangeLog	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/Source/WebCore/ChangeLog	2012-11-16 12:04:52 UTC (rev 134928)
@@ -1,3 +1,18 @@
+2012-11-16  Yury Semikhatsky  <yu...@chromium.org>
+
+        Web Inspector: don't show an Error when evaluating a watch _expression_ results in an exception
+        https://bugs.webkit.org/show_bug.cgi?id=102470
+
+        Reviewed by Vsevolod Vlasov.
+
+        Dim watch _expression_ and show "<not available>" as its value in cases when it evaluates
+        into an exception.
+
+        * English.lproj/localizedStrings.js:
+        * inspector/front-end/WatchExpressionsSidebarPane.js:
+        (WebInspector.WatchExpressionTreeElement.prototype.update):
+        * inspector/front-end/inspector.css:
+
 2012-11-16  Vsevolod Vlasov  <vse...@chromium.org>
 
         Web Inspector: Rollout 134404 134548 134552 Temporarily rolling out to ease merging.

Modified: trunk/Source/WebCore/English.lproj/localizedStrings.js (134927 => 134928)


--- trunk/Source/WebCore/English.lproj/localizedStrings.js	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/Source/WebCore/English.lproj/localizedStrings.js	2012-11-16 12:04:52 UTC (rev 134928)
@@ -472,6 +472,7 @@
 localizedStrings["Subtree Modifications"] = "Subtree Modifications";
 localizedStrings["Subtree modifications"] = "Subtree modifications";
 localizedStrings["<node>"] = "<node>";
+localizedStrings["<not available>"] = "<not available>";
 localizedStrings["Paused on a \"%s\" breakpoint set on %s, because a new child was added to its descendant %s."] = "Paused on a \"%s\" breakpoint set on %s, because a new child was added to its descendant %s.";
 localizedStrings["Paused on a \"%s\" breakpoint set on %s, because a new child was added to that node."] = "Paused on a \"%s\" breakpoint set on %s, because a new child was added to that node.";
 localizedStrings["Paused on a \"%s\" breakpoint set on %s, because its descendant %s was removed."] = "Paused on a \"%s\" breakpoint set on %s, because its descendant %s was removed.";

Modified: trunk/Source/WebCore/inspector/front-end/WatchExpressionsSidebarPane.js (134927 => 134928)


--- trunk/Source/WebCore/inspector/front-end/WatchExpressionsSidebarPane.js	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/Source/WebCore/inspector/front-end/WatchExpressionsSidebarPane.js	2012-11-16 12:04:52 UTC (rev 134928)
@@ -388,8 +388,11 @@
     {
         WebInspector.ObjectPropertyTreeElement.prototype.update.call(this);
 
-        if (this.property.wasThrown)
-            this.valueElement.addStyleClass("watch-expressions-error-level");
+        if (this.property.wasThrown) {
+            this.valueElement.textContent = WebInspector.UIString("<not available>");
+            this.listItemElement.addStyleClass("dimmed");
+        } else
+            this.listItemElement.removeStyleClass("dimmed");
 
         var deleteButton = document.createElement("input");
         deleteButton.type = "button";

Modified: trunk/Source/WebCore/inspector/front-end/inspector.css (134927 => 134928)


--- trunk/Source/WebCore/inspector/front-end/inspector.css	2012-11-16 12:00:23 UTC (rev 134927)
+++ trunk/Source/WebCore/inspector/front-end/inspector.css	2012-11-16 12:04:52 UTC (rev 134928)
@@ -1648,10 +1648,6 @@
     display: none;
 }
 
-.watch-expressions-error-level {
-    color: red;
-}
-
 .section .properties li.editing-sub-part {
     padding: 3px 6px 8px 18px;
     margin: -3px -6px -8px -6px;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to