| Index: tracing/tracing/value/ui/histogram_set_table.html
|
| diff --git a/tracing/tracing/value/ui/histogram_set_table.html b/tracing/tracing/value/ui/histogram_set_table.html
|
| index 1d97ca6ace9f0048c17d8c0feeacf7c790b18e73..58f3a0e87c5d2ddc28cfab7b303dc55e1ccdfcea 100644
|
| --- a/tracing/tracing/value/ui/histogram_set_table.html
|
| +++ b/tracing/tracing/value/ui/histogram_set_table.html
|
| @@ -195,23 +195,24 @@ tr.exportTo('tr.v.ui', function() {
|
| if (tableRowsDirty) {
|
| await this.progress_('Filtering rows...');
|
|
|
| - let filteredHistograms = this.viewState.showAll ?
|
| - this.histograms : this.sourceHistograms_;
|
| + const filteredHistogramNames = new Set();
|
| + let query;
|
| if (this.viewState.searchQuery) {
|
| - let query = undefined;
|
| try {
|
| query = new RegExp(this.viewState.searchQuery);
|
| } catch (e) {
|
| }
|
| - if (query !== undefined) {
|
| - filteredHistograms = new tr.v.HistogramSet(
|
| - [...filteredHistograms].filter(
|
| - hist => hist.name.match(query)));
|
| + }
|
| + for (const hist of this.viewState.showAll ?
|
| + this.histograms : this.sourceHistograms_) {
|
| + if (query === undefined ||
|
| + hist.name.match(query)) {
|
| + filteredHistogramNames.add(hist.name);
|
| }
|
| }
|
|
|
| const filteredHierarchies = tr.v.HistogramSetHierarchy.filter(
|
| - this.hierarchies_, filteredHistograms);
|
| + this.hierarchies_, filteredHistogramNames);
|
|
|
| // Wait to set this.$.table.tableRows until we're ready for it to build
|
| // DOM. When tableRows are set on it, tr-ui-b-table calls
|
| @@ -219,7 +220,7 @@ tr.exportTo('tr.v.ui', function() {
|
| // but that can happen in between the next await, which is too early.
|
| this.tableRows_ = filteredHierarchies.map(hierarchy =>
|
| new tr.v.ui.HistogramSetTableRow(
|
| - hierarchy, this.$.table, this.viewState));
|
| + hierarchy, this.$.table, this.histograms, this.viewState));
|
|
|
| tr.b.Timing.instant('histogram-set-table', 'rootRowCount',
|
| this.tableRows_.length);
|
|
|