Changeset 183376 in webkit


Ignore:
Timestamp:
Apr 26, 2015, 6:25:50 PM (10 years ago)
Author:
timothy@apple.com
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):

Location:
trunk/Source/WebInspectorUI
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebInspectorUI/ChangeLog

    r183375 r183376  
     12015-04-26  Timothy Hatcher  <timothy@apple.com>
     2
     3        Web Inspector: Allow Timeline tab to show resource when a go-to arrow is clicked in a recording
     4        https://bugs.webkit.org/show_bug.cgi?id=144240
     5
     6        Only support showing a resource or script if we have that represented object in the Timeline sidebar.
     7
     8        Reviewed by Darin Adler.
     9
     10        * UserInterface/Views/TimelineTabContentView.js:
     11        (WebInspector.TimelineTabContentView.prototype.canShowRepresentedObject):
     12
    1132015-04-26  Timothy Hatcher  <timothy@apple.com>
    214
  • trunk/Source/WebInspectorUI/UserInterface/Views/TimelineTabContentView.js

    r183323 r183376  
    4848    canShowRepresentedObject: function(representedObject)
    4949    {
    50         return representedObject instanceof WebInspector.TimelineRecording;
     50        if (representedObject instanceof WebInspector.TimelineRecording)
     51            return true;
     52
     53        // Only support showing a resource or script if we have that represented object in the sidebar.
     54        if (representedObject instanceof WebInspector.Resource || representedObject instanceof WebInspector.Script)
     55            return !!this.navigationSidebarPanel.treeElementForRepresentedObject(representedObject);
     56
     57        return false;
    5158    },
    5259
Note: See TracChangeset for help on using the changeset viewer.