From 2e8ae4208d80fa5cd61b2c9c18f5563c374e7253 Mon Sep 17 00:00:00 2001 From: kaurjasleen240305 Date: Thu, 4 Jan 2024 19:09:26 +0530 Subject: [PATCH] setimeout done less --- js/activity.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/js/activity.js b/js/activity.js index 101991eb7d..100358516c 100644 --- a/js/activity.js +++ b/js/activity.js @@ -1230,12 +1230,14 @@ class Activity { this.blocks.setBlockScale(BLOCKSCALES[this.blockscale]); const that = this; - that.resizeDebounce = false; + setTimeout(() => { + that.resizeDebounce = false; + }, 500); } this.setSmallerLargerStatus(); } - if(typeof(this.activity)!=undefined){ + if(typeof(this.activity)!="undefined"){ this.activity.refreshCanvas(); } document.getElementById("hideContents").click(); @@ -1263,7 +1265,8 @@ class Activity { } this.setSmallerLargerStatus(); - if(typeof(this.activity)!=undefined){ + if(typeof(this.activity)!="undefined"){ + console.log(typeof(this.activity)); this.activity.refreshCanvas(); } document.getElementById("hideContents").click();