Title: [291729] trunk/Source/WebInspectorUI
Revision
291729
Author
pan...@apple.com
Date
2022-03-22 17:19:32 -0700 (Tue, 22 Mar 2022)

Log Message

Web Inspector: Elements tab: selection variable not displayed after losing focus
https://bugs.webkit.org/show_bug.cgi?id=238226

Reviewed by Devin Rousso.

When rebuilding the underlying `DOMTreeElements`, we should make sure the inspected node is marked as such,
otherwise we won't update this until a different element becomes the inspected node.

* UserInterface/Views/DOMTreeOutline.js:
(WI.DOMTreeOutline.prototype.update):

Modified Paths

Diff

Modified: trunk/Source/WebInspectorUI/ChangeLog (291728 => 291729)


--- trunk/Source/WebInspectorUI/ChangeLog	2022-03-23 00:11:38 UTC (rev 291728)
+++ trunk/Source/WebInspectorUI/ChangeLog	2022-03-23 00:19:32 UTC (rev 291729)
@@ -1,5 +1,18 @@
 2022-03-22  Patrick Angle  <pan...@apple.com>
 
+        Web Inspector: Elements tab: selection variable not displayed after losing focus
+        https://bugs.webkit.org/show_bug.cgi?id=238226
+
+        Reviewed by Devin Rousso.
+
+        When rebuilding the underlying `DOMTreeElements`, we should make sure the inspected node is marked as such,
+        otherwise we won't update this until a different element becomes the inspected node.
+
+        * UserInterface/Views/DOMTreeOutline.js:
+        (WI.DOMTreeOutline.prototype.update):
+
+2022-03-22  Patrick Angle  <pan...@apple.com>
+
         Web Inspector: `console.log` format strings containing invalid specifiers results in `[Object object]` replacing the specifier instead of ignoring the invalid specifier
         https://bugs.webkit.org/show_bug.cgi?id=235061
 

Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js (291728 => 291729)


--- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js	2022-03-23 00:11:38 UTC (rev 291728)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js	2022-03-23 00:19:32 UTC (rev 291729)
@@ -189,6 +189,14 @@
             }
         }
 
+        if (WI.domManager.inspectedNode) {
+            let inspectedNodeTreeElement = this.findTreeElement(WI.domManager.inspectedNode);
+            if (inspectedNodeTreeElement) {
+                inspectedNodeTreeElement.reveal();
+                inspectedNodeTreeElement.listItemElement.classList.add("inspected-node");
+            }
+        }
+
         if (!selectedTreeElements.length)
             return;
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to