Skip to content

Commit

Permalink
[object-stats] Visualizer: Reset on Isolate change
Browse files Browse the repository at this point in the history
No-try: true
Bug: v8:7266
Change-Id: Ia3a0142488765d36485287d0bf4ffa1e2cc635b2
Reviewed-on: https://chromium-review.googlesource.com/883141
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50826}
  • Loading branch information
mlippautz authored and Commit Bot committed Jan 24, 2018
1 parent ee4afcb commit 1f7d86c
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tools/heap-stats/details-selection.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,16 @@ class DetailsSelection extends HTMLElement {
}

dataChanged() {
this.clearUI();
this.selection = {categories: {}};
this.resetUI(true);
this.populateSelect(
'#isolate-select', Object.keys(this.data).map(v => [v, v]));
this.handleIsolateChange();
}

clearUI() {
this.selection = {categories: {}};
removeAllChildren(this.isolateSelect);
resetUI(resetIsolateSelect) {
if (resetIsolateSelect) removeAllChildren(this.isolateSelect);

removeAllChildren(this.datasetSelect);
removeAllChildren(this.gcSelect);
this.clearCategories();
Expand All @@ -116,7 +117,7 @@ class DetailsSelection extends HTMLElement {
this.selection.isolate = null;
return;
}

this.resetUI(false);
this.populateSelect(
'#dataset-select',
this.data[this.selection.isolate].data_sets.entries(), 'live');
Expand Down

0 comments on commit 1f7d86c

Please sign in to comment.