From 54cbefa9f306666629d3864e3215e4a17bf5d477 Mon Sep 17 00:00:00 2001 From: Giovanni LB Date: Tue, 6 Jun 2023 12:32:35 -0300 Subject: [PATCH] Fixed scalebar for Navi Change-Id: I5d644f43eac16c86535012286dff972e3afbcb3b --- plugin/att/ui/index.html | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/plugin/att/ui/index.html b/plugin/att/ui/index.html index 5faf62919e..7dc12e15f8 100644 --- a/plugin/att/ui/index.html +++ b/plugin/att/ui/index.html @@ -205,8 +205,12 @@ var current_SM = 0 var current_WV = 0 var filename_data = {} + var clock_scale = 1 fetch("filenames.json", {cache: "no-store"}).then(response => response.json()).then(data => { + try { + clock_scale = data.gfxv === 'navi' ? 3 : 1 + } catch { clock_scale = 1 } filename_data = data.wave_filenames wave_cu_index = {}; @@ -229,8 +233,7 @@ FetchNamesAndGather(wv) return } - - //FetchNamesAndGather(0) // !!!! + //FetchNamesAndGather(0) }) function OpenSIMDView(se_index) { @@ -737,7 +740,7 @@ const scaleX = d3.scaleLinear() .domain([START_TIME, START_TIME + data.duration + MARGIN]) .range([MARGIN, WIDTH-MARGIN]) - const toX = (x) => { return Math.ceil(scaleX(x)) } + const toX = (x) => { return Math.ceil(scaleX(x)*clock_scale) } const STATE_COLOR = { 0: ["EMPTY", "#ffffff"],