]> _ Git - fluidbook-toolbox.git/commitdiff
wait #7275 @6:00
authorsoufiane <soufiane@cubedesigners.com>
Thu, 30 Jan 2025 10:14:21 +0000 (11:14 +0100)
committersoufiane <soufiane@cubedesigners.com>
Thu, 30 Jan 2025 10:14:21 +0000 (11:14 +0100)
resources/linkeditor/js/linkeditor.links.js
resources/linkeditor/js/linkeditor.previewLinks.js
resources/linkeditor/js/linkeditor.undo.js

index e0b963dd3b143afe981451b2e29111f80a4ed81f..93ed768fef0cbc7a183f2307864b6ba21f966102 100644 (file)
@@ -1294,6 +1294,7 @@ LinkeditorLinks.prototype = {
             $this.addLink(link, false);
             LINKS[link.uid] = link;
             existingUIDs.push(link.uid);
+            $this.linkeditor.previewLinks.updatePreview(link)
         });
         // Search for missing links and delete them
         var pages = this.linkeditor.getCurrentPages();
index 180d1cf1e703a86f3d96c0b5a69cc684dca24df2..8003366c7360293ab5ec834bc8ec63b13f5acbf2 100644 (file)
@@ -168,7 +168,6 @@ LinkeditorPreviewLinks.prototype = {
              *
              */
             this.createPreviewLayerHTML($("#linkeditor-layer-links"),$this.linkData.uid)
-            this.setTransformOrigin($this.linkData)
             /*if (animZoom.length > 0) {
                 $("#linkeditor-layer-links [data-id-preview=" + $this.linkData.uid + "] .preview").addClass("img")
 
@@ -220,6 +219,7 @@ LinkeditorPreviewLinks.prototype = {
                 $("#linkeditor-layer-links [data-id-preview=" + $this.linkData.uid + "] .preview").removeClass("img")
             /*}*/
         }
+        this.setTransformOrigin($this.linkData)
 
         const z = this.linkeditor.zoom.normalizeZoom(this.linkeditor.zoom.getZoom())
         if(z) {
index c59b1b3717c8f47efdb61be10702d718723caffc..bbbbf24e156948e724d59f7187fee1fb6ea602b0 100644 (file)
@@ -104,7 +104,6 @@ LinkeditorUndo.prototype = {
         //console.log('undo : current index', index, 'states length', this.states[this.linkeditor.getCurrentPage()].length);
 
         this.updateIconsStates();
-        this.linkeditor.links.setPreview();
     },
 
     redo: function () {
@@ -124,7 +123,6 @@ LinkeditorUndo.prototype = {
         //console.log('redo : current index', index, 'states length', this.states[this.linkeditor.getCurrentPage()].length);
 
         this.updateIconsStates();
-        this.linkeditor.links.setPreview();
     }
 }