This is an automated email from the ASF dual-hosted git repository. solomax pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/openmeetings.git
commit f659f1b14a265ebbd01d61795fa53dc00320252f Author: Maxim Solodovnik <solomax...@gmail.com> AuthorDate: Wed May 18 21:35:02 2022 +0700 [OPENMEETINGS-2732] fabric.js --- openmeetings-web/src/main/front/wb/package.json | 2 +- openmeetings-web/src/main/front/wb/src/wb.js | 7 ------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/openmeetings-web/src/main/front/wb/package.json b/openmeetings-web/src/main/front/wb/package.json index b2ce35f75..e84874c63 100644 --- a/openmeetings-web/src/main/front/wb/package.json +++ b/openmeetings-web/src/main/front/wb/package.json @@ -18,7 +18,7 @@ "tinyify": "^3.0.0" }, "dependencies": { - "fabric": "^4.6.0", + "fabric": "^5.2.1", "mathjax-full": "^3.2.0" } } diff --git a/openmeetings-web/src/main/front/wb/src/wb.js b/openmeetings-web/src/main/front/wb/src/wb.js index f979e328d..adbff2fe6 100644 --- a/openmeetings-web/src/main/front/wb/src/wb.js +++ b/openmeetings-web/src/main/front/wb/src/wb.js @@ -84,10 +84,6 @@ module.exports = class Wb { } function _createObject(arr, handler) { fabric.util.enlivenObjects(arr, function(objects) { - self.eachCanvas(function(canvas) { - canvas.renderOnAddRemove = false; - }); - for (let i = 0; i < objects.length; ++i) { const _o = objects[i]; _o.loaded = true; @@ -95,7 +91,6 @@ module.exports = class Wb { } self.eachCanvas(function(canvas) { - canvas.renderOnAddRemove = true; canvas.requestRenderAll(); }); }); @@ -473,14 +468,12 @@ module.exports = class Wb { this.clearSlide = (_sl) => { if (canvases.length > _sl) { const canvas = canvases[_sl]; - canvas.renderOnAddRemove = false; let arr = canvas.getObjects(); while (arr.length > 0) { canvas.remove(arr[arr.length - 1]); arr = canvas.getObjects(); } $('.room-block .wb-block .wb-video.slide-' + _sl).remove(); - canvas.renderOnAddRemove = true; canvas.requestRenderAll(); } };