From b328adb177be54b7e41dadc2fe50b14e4a5f2500 Mon Sep 17 00:00:00 2001 From: Kai Lauterbach Date: Fri, 5 May 2023 10:45:56 +0200 Subject: [PATCH] Added table update of timing editor --- firmware/data/bottom.js | 5 +---- firmware/html/bottom.js | 10 +++++----- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/firmware/data/bottom.js b/firmware/data/bottom.js index e619d89..fe6a7d6 100644 --- a/firmware/data/bottom.js +++ b/firmware/data/bottom.js @@ -1,5 +1,4 @@ function addTabListener() { -console.log("Try to add tab listener"); try { var tabMain = document.getElementById("tab-lights"); var tabConfig = document.getElementById("tab-config"); @@ -8,7 +7,6 @@ var amain = document.getElementById("tab-a-lights"); var acfg = document.getElementById("tab-a-config"); var atde = document.getElementById("tab-a-tde"); amain.addEventListener("click", function() { -console.log("Switch to main lights tab"); tabMain.classList.add("visible"); tabConfig.classList.remove("visible"); tabTDE.classList.remove("visible"); @@ -17,7 +15,6 @@ acfg.classList.remove("pure-button-primary"); atde.classList.remove("pure-button-primary"); }); acfg.addEventListener("click", function() { -console.log("Switch to config tab"); tabMain.classList.remove("visible"); tabConfig.classList.add("visible"); tabTDE.classList.remove("visible"); @@ -26,13 +23,13 @@ acfg.classList.add("pure-button-primary"); atde.classList.remove("pure-button-primary"); }); atde.addEventListener("click", function() { -console.log("Switch to TDE tab"); tabMain.classList.remove("visible"); tabConfig.classList.remove("visible"); tabTDE.classList.add("visible"); amain.classList.remove("pure-button-primary"); acfg.classList.remove("pure-button-primary"); atde.classList.add("pure-button-primary"); +createTable(); }); } catch (error) { console.log("Error: load listener of the tab action listener management: " + error.message); diff --git a/firmware/html/bottom.js b/firmware/html/bottom.js index b5e3b31..38d3db1 100644 --- a/firmware/html/bottom.js +++ b/firmware/html/bottom.js @@ -1,5 +1,5 @@ function addTabListener() { - console.log("Try to add tab listener"); + //console.log("Try to add tab listener"); try { var tabMain = document.getElementById("tab-lights"); var tabConfig = document.getElementById("tab-config"); @@ -11,7 +11,7 @@ function addTabListener() { amain.addEventListener("click", function() { - console.log("Switch to main lights tab"); + //console.log("Switch to main lights tab"); tabMain.classList.add("visible"); tabConfig.classList.remove("visible"); tabTDE.classList.remove("visible"); @@ -22,7 +22,7 @@ function addTabListener() { }); acfg.addEventListener("click", function() { - console.log("Switch to config tab"); + //console.log("Switch to config tab"); tabMain.classList.remove("visible"); tabConfig.classList.add("visible"); tabTDE.classList.remove("visible"); @@ -33,7 +33,7 @@ function addTabListener() { }); atde.addEventListener("click", function() { - console.log("Switch to TDE tab"); + //console.log("Switch to TDE tab"); tabMain.classList.remove("visible"); tabConfig.classList.remove("visible"); tabTDE.classList.add("visible"); @@ -42,7 +42,7 @@ function addTabListener() { acfg.classList.remove("pure-button-primary"); atde.classList.add("pure-button-primary"); - //createTable(); // recreate the table on timing data editor tab + createTable(); // recreate the table on timing data editor tab }); } catch (error) { console.log("Error: load listener of the tab action listener management: " + error.message);