From dcfae4beb06eafd10026807684f0299b1fcb0b3f Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Tue, 14 Aug 2018 13:02:10 +0000 Subject: [PATCH] fix #2181 @1.5 --- inc/ws/Util/class.ws.tools.php | 2 +- inc/ws/Util/html5/master/class.ws.html5.compiler.php | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/inc/ws/Util/class.ws.tools.php b/inc/ws/Util/class.ws.tools.php index 12aa2d542..597656dd2 100644 --- a/inc/ws/Util/class.ws.tools.php +++ b/inc/ws/Util/class.ws.tools.php @@ -175,7 +175,7 @@ class wsTools { if ($optimize) { - $cmd = "timeout -s 1 10 /usr/local/bin/svgcleaner --allow-bigger-file --paths-coordinates-precision 3 --copy-on-error --stdout $original"; + $cmd = "timeout -s 1 20 /usr/local/bin/svgcleaner --allow-bigger-file --paths-coordinates-precision 3 --copy-on-error --stdout $original"; $svg = `$cmd`; if ($svg == '') { $svg = file_get_contents($original); diff --git a/inc/ws/Util/html5/master/class.ws.html5.compiler.php b/inc/ws/Util/html5/master/class.ws.html5.compiler.php index da513a1c2..72215cc39 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -3,7 +3,6 @@ class wsHTML5Compiler { public static $resolutions = array(150, 300); - public $maxRes = 300; public $jsFiles = array( 'js/libs/modernizr/modernizr.min.js', @@ -213,6 +212,7 @@ class wsHTML5Compiler $this->daoBook = new wsDAOBook($core->con); $this->book = $this->daoBook->selectById($book_id); $this->pages = $this->daoBook->getPagesOfBook($book_id); + $this->maxRes = min(300, $this->book->parametres->maxResolution); $daoTheme = new wsDAOTheme($core->con); @@ -1816,7 +1816,6 @@ class wsHTML5Compiler } - public function unzipFile($file, $moveAssets = false, $baseDir = null) { $fdir = is_null($baseDir) ? 'data/links/' . str_replace('.', '_', $file) : $baseDir; -- 2.39.5