Changeset 193771 in webkit


Ignore:
Timestamp:
Dec 8, 2015, 12:42:42 PM (10 years ago)
Author:
Matt Baker
Message:

Web Inspector: Global Breakpoints should always be visible
https://bugs.webkit.org/show_bug.cgi?id=151066

Reviewed by Timothy Hatcher.

  • UserInterface/Views/DebuggerSidebarPanel.js:

(WebInspector.DebuggerSidebarPanel):
Turn off filtering for Global Breakpoints elements.

  • UserInterface/Views/NavigationSidebarPanel.js:

(WebInspector.NavigationSidebarPanel.prototype.suppressFilteringOnTreeElements):
Allow filtering to be turned off for specific tree elements.
(WebInspector.NavigationSidebarPanel.prototype.applyFiltersToTreeElement):
Make element visible if filtering suppressed.
(WebInspector.NavigationSidebarPanel.prototype._checkForEmptyFilterResults):
Visible elements with filtering disabled aren't considered when
showing/hiding the empty content placeholder.

Location:
trunk/Source/WebInspectorUI
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebInspectorUI/ChangeLog

    r193646 r193771  
     12015-12-08  Matt Baker  <mattbaker@apple.com>
     2
     3        Web Inspector: Global Breakpoints should always be visible
     4        https://bugs.webkit.org/show_bug.cgi?id=151066
     5
     6        Reviewed by Timothy Hatcher.
     7
     8        * UserInterface/Views/DebuggerSidebarPanel.js:
     9        (WebInspector.DebuggerSidebarPanel):
     10        Turn off filtering for Global Breakpoints elements.
     11
     12        * UserInterface/Views/NavigationSidebarPanel.js:
     13        (WebInspector.NavigationSidebarPanel.prototype.suppressFilteringOnTreeElements):
     14        Allow filtering to be turned off for specific tree elements.
     15        (WebInspector.NavigationSidebarPanel.prototype.applyFiltersToTreeElement):
     16        Make element visible if filtering suppressed.
     17        (WebInspector.NavigationSidebarPanel.prototype._checkForEmptyFilterResults):
     18        Visible elements with filtering disabled aren't considered when
     19        showing/hiding the empty content placeholder.
     20
    1212015-12-07  Brian Burg  <bburg@apple.com>
    222
  • trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js

    r192936 r193771  
    123123        this._globalBreakpointsFolderTreeElement.expand();
    124124
     125        this.suppressFilteringOnTreeElements([this._globalBreakpointsFolderTreeElement, this._allExceptionsBreakpointTreeElement, this._allUncaughtExceptionsBreakpointTreeElement]);
     126
    125127        var breakpointsRow = new WebInspector.DetailsSectionRow;
    126128        breakpointsRow.element.appendChild(this._breakpointsContentTreeOutline.element);
  • trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js

    r192936 r193771  
    178178    }
    179179
     180    suppressFilteringOnTreeElements(treeElements)
     181    {
     182        console.assert(Array.isArray(treeElements), "TreeElements should be an array.");
     183
     184        for (let treeElement of treeElements)
     185            treeElement[WebInspector.NavigationSidebarPanel.SuppressFilteringSymbol] = true;
     186
     187        this._updateFilter();
     188    }
     189
    180190    treeElementForRepresentedObject(representedObject)
    181191    {
     
    386396        }
    387397
    388         if (matchTextFilter(filterableData.text) && this.matchTreeElementAgainstFilterFunctions(treeElement, flags) && this.matchTreeElementAgainstCustomFilters(treeElement, flags)) {
     398        let suppressFiltering = treeElement[WebInspector.NavigationSidebarPanel.SuppressFilteringSymbol];
     399
     400        if (suppressFiltering || (matchTextFilter(filterableData.text) && this.matchTreeElementAgainstFilterFunctions(treeElement, flags) && this.matchTreeElementAgainstCustomFilters(treeElement, flags))) {
    389401            // Make this element visible since it matches.
    390402            makeVisible();
     
    499511        var currentTreeElement = this._contentTreeOutline.children[0];
    500512        while (currentTreeElement) {
    501             if (!currentTreeElement.hidden) {
     513            if (!currentTreeElement.hidden && !currentTreeElement[WebInspector.NavigationSidebarPanel.SuppressFilteringSymbol]) {
    502514                // Not hidden, so hide any empty content message.
    503515                this.hideEmptyContentPlaceholder();
     
    718730};
    719731
     732WebInspector.NavigationSidebarPanel.SuppressFilteringSymbol = Symbol("supresss-filtering");
    720733WebInspector.NavigationSidebarPanel.WasExpandedDuringFilteringSymbol = Symbol("was-expanded-during-filtering");
    721734
Note: See TracChangeset for help on using the changeset viewer.