Title: [183376] trunk/Source/WebInspectorUI
Revision
183376
Author
[email protected]
Date
2015-04-26 18:25:50 -0700 (Sun, 26 Apr 2015)

Log Message

Web Inspector: Allow Timeline tab to show resource when a go-to arrow is clicked in a recording
https://bugs.webkit.org/show_bug.cgi?id=144240

Only support showing a resource or script if we have that represented object in the Timeline sidebar.

Reviewed by Darin Adler.

* UserInterface/Views/TimelineTabContentView.js:
(WebInspector.TimelineTabContentView.prototype.canShowRepresentedObject):

Modified Paths

Diff

Modified: trunk/Source/WebInspectorUI/ChangeLog (183375 => 183376)


--- trunk/Source/WebInspectorUI/ChangeLog	2015-04-27 01:24:37 UTC (rev 183375)
+++ trunk/Source/WebInspectorUI/ChangeLog	2015-04-27 01:25:50 UTC (rev 183376)
@@ -1,5 +1,17 @@
 2015-04-26  Timothy Hatcher  <[email protected]>
 
+        Web Inspector: Allow Timeline tab to show resource when a go-to arrow is clicked in a recording
+        https://bugs.webkit.org/show_bug.cgi?id=144240
+
+        Only support showing a resource or script if we have that represented object in the Timeline sidebar.
+
+        Reviewed by Darin Adler.
+
+        * UserInterface/Views/TimelineTabContentView.js:
+        (WebInspector.TimelineTabContentView.prototype.canShowRepresentedObject):
+
+2015-04-26  Timothy Hatcher  <[email protected]>
+
         Web Inspector: Don't use treeElement.revealAndSelect when showing a default content view
         https://bugs.webkit.org/show_bug.cgi?id=144239
 

Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TimelineTabContentView.js (183375 => 183376)


--- trunk/Source/WebInspectorUI/UserInterface/Views/TimelineTabContentView.js	2015-04-27 01:24:37 UTC (rev 183375)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/TimelineTabContentView.js	2015-04-27 01:25:50 UTC (rev 183376)
@@ -47,7 +47,14 @@
 
     canShowRepresentedObject: function(representedObject)
     {
-        return representedObject instanceof WebInspector.TimelineRecording;
+        if (representedObject instanceof WebInspector.TimelineRecording)
+            return true;
+
+        // Only support showing a resource or script if we have that represented object in the sidebar.
+        if (representedObject instanceof WebInspector.Resource || representedObject instanceof WebInspector.Script)
+            return !!this.navigationSidebarPanel.treeElementForRepresentedObject(representedObject);
+
+        return false;
     },
 
     get supportsSplitContentBrowser()
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to