]> _ Git - cubeextranet.git/commitdiff
wait #5139 @1.5
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 2 Mar 2022 17:52:39 +0000 (17:52 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 2 Mar 2022 17:52:39 +0000 (17:52 +0000)
inc/ws/Util/html5/master/class.ws.html5.compiler.php
inc/ws/Util/html5/master/class.ws.html5.links.php

index ada06e070d0267a22e90272916a178ec2f2406a1..2e614bfd0e03d3cdee341cfcb3687deced4d331a 100644 (file)
@@ -2153,7 +2153,7 @@ height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
                 continue;
             }
             $link = wsHTML5Link::getInstance($this->base62($i), $linkData, $this);
-            if (is_null($link)) {
+            if (is_null($link) || $link->ignore()) {
                 continue;
             }
 
index 2aed7f2dd1cf5478be65987a4a01cfd4b1f68ba6..3394519da959dc37e19eaf244c9c4a699dd304c2 100644 (file)
@@ -291,6 +291,11 @@ class wsHTML5Link
         return dechex(rand(0, pow(16, 10)));
     }
 
+    public function ignore()
+    {
+        return false;
+    }
+
     public function getSurface()
     {
         return $this->width * $this->height;
@@ -480,6 +485,16 @@ class wsHTML5Link
         $this->init();
     }
 
+    public function isOutsidePage()
+    {
+        if ($this->top > $this->compiler->height) {
+            return true;
+        }
+        if ($this->left > $this->compiler->width) {
+            return true;
+        }
+    }
+
     /**
      * @param int $initialOrder
      */
@@ -2690,6 +2705,11 @@ class zoomLink extends normalLink
     protected $maxzoom_default = 2;
     protected $_groups = null;
 
+    public function ignore()
+    {
+        return parent::ignore() || $this->isOutsidePage();
+    }
+
     public function getGroups()
     {
         if (null === $this->_groups) {