Commit 06bc3387 authored by Zeynep Cankara's avatar Zeynep Cankara Committed by Commit Bot

[system-analyzer] Fix chunk positions and update panels via FocusEvent

This CL fixes the chunk locations on timeline-tracks.
The App updates the Ic panel upon receiving FocusEvent with
an entry of ICLogEvent.

Bug: v8:10644

Change-Id: I4d09851c154196cc6cb1544a275ed33c8ae8a8af
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2354814
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Reviewed-by: 's avatarCamillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69399}
parent 8e8f4c83
...@@ -100,7 +100,8 @@ class App { ...@@ -100,7 +100,8 @@ class App {
this.#view.mapPanel.map = entry; this.#view.mapPanel.map = entry;
} }
selectICLogEvent(entry) { selectICLogEvent(entry) {
console.log("IC Entry selection"); this.#state.ic = entry;
this.#view.icPanel.filteredEntries = [entry];
} }
selectSourcePositionEvent(sourcePositions) { selectSourcePositionEvent(sourcePositions) {
console.log("source positions: ", sourcePositions); console.log("source positions: ", sourcePositions);
......
...@@ -219,7 +219,7 @@ defineCustomElement('./timeline/timeline-track', (templateText) => ...@@ -219,7 +219,7 @@ defineCustomElement('./timeline/timeline-track', (templateText) =>
if (chunk.isEmpty()) continue; if (chunk.isEmpty()) continue;
let node = this.div(); let node = this.div();
node.className = 'chunk'; node.className = 'chunk';
node.style.left = (i * kChunkWidth) + 'px'; node.style.left = (chunks[i].start * this.#timeToPixel) + 'px';
node.style.height = height + 'px'; node.style.height = height + 'px';
node.chunk = chunk; node.chunk = chunk;
node.addEventListener('mousemove', e => this.handleChunkMouseMove(e)); node.addEventListener('mousemove', e => this.handleChunkMouseMove(e));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment