From 8d71e9838d288183dec0afbf387f601b1b8beac6 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Tue, 3 May 2022 15:54:03 +0000 Subject: [PATCH] wait #5262 @0.25 --- inc/ws/Metier/class.ws.book.parametres.php | 3 ++- inc/ws/Util/html5/master/class.ws.html5.compiler.php | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/inc/ws/Metier/class.ws.book.parametres.php b/inc/ws/Metier/class.ws.book.parametres.php index 9da5a797e..4d1cd2553 100644 --- a/inc/ws/Metier/class.ws.book.parametres.php +++ b/inc/ws/Metier/class.ws.book.parametres.php @@ -275,6 +275,7 @@ class wsBookParametres extends wsParametres __('Tourner (souple)') => 'flip3d') ); $this->fields['mobileTransitionDuration'] = array('type' => 'float', 'default' => 0.5, 'editable' => true, 'label' => __('Durée de la transition')); + $this->fields['mobileTransitionDurationSlide'] = array('type' => 'float', 'default' => 0, 'editable' => true, 'label' => __('Durée de la transition (fade, slide)'), 'hint' => __('Laisser à zéro pour utiliser la valeur générale')); $this->fields['mobileNavigationType'] = array('type' => 'combo', 'default' => 'book', 'editable' => true, 'label' => __('Mode de navigation'), 'grade' => 5, 'datas' => array(__('Normal (automatique)') => 'book', __('Normal (double page)') => 'landscape', @@ -304,7 +305,7 @@ class wsBookParametres extends wsParametres $this->forms['3d_mode'] = array('label' => __('Options de visualisation'), - 'fieldsnames' => array('mobileNavigationType', '|', 'mobileTransitions', 'mobileTransitionDuration', '|', 'forceWhiteBackground', 'rasterizePages', 'vectorPages', 'visualisationMode', 'antialiasReading', 'correctCenter', 'pagesBaseAngle', 'centerBook', '|', 'extraXSpace', 'mobileExtraXSpace', 'extraYSpace', '|', 'viewMode', '|', 'dynamicBackgroundColor', '|', 'svgToCanvas', 'svgToCanvasUpscale', 'svgTextMethod', 'textsThickness', 'textsThicknessPages', '|', 'imageFormat', 'maxResolution', 'JPEGQuality')); + 'fieldsnames' => array('mobileNavigationType', '|', 'mobileTransitions', 'mobileTransitionDuration', 'mobileTransitionDurationSlide', '|', 'forceWhiteBackground', 'rasterizePages', 'vectorPages', 'visualisationMode', 'antialiasReading', 'correctCenter', 'pagesBaseAngle', 'centerBook', '|', 'extraXSpace', 'mobileExtraXSpace', 'extraYSpace', '|', 'viewMode', '|', 'dynamicBackgroundColor', '|', 'svgToCanvas', 'svgToCanvasUpscale', 'svgTextMethod', 'textsThickness', 'textsThicknessPages', '|', 'imageFormat', 'maxResolution', 'JPEGQuality')); $this->fields['rasterizeOnSafari'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Ecraser les pages pour Safari (Mac OS)'), 'grade' => 1); $this->fields['performance3DMode'] = array('type' => 'combo', 'datas' => [__('Tester la machine') => 'auto', 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 906f2a876..35159e8f8 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -2042,7 +2042,7 @@ height="0" width="0" style="display:none;visibility:hidden"> $ofile = $this->wdir . '/' . $linkData['to']; $dfile = $this->wdir . '/' . $linkData['to'] . '.svg'; if (!file_exists($dfile) || filemtime($dfile) < filemtime($ofile)) { - $cmd="pdftocairo -svg -f 1 -l 1 $ofile $dfile"; + $cmd = "pdftocairo -svg -f 1 -l 1 $ofile $dfile"; `$cmd`; } $linkData['type'] = 6; @@ -2825,6 +2825,7 @@ height="0" width="0" style="display:none;visibility:hidden"> $this->lessVariables['edge-right-offset'] = 0; $this->lessVariables['edges-opacity'] = 1; + $this->lessVariables['audioplayer-background-color'] = wsHTML5::colorToCSS($this->theme->parametres->audioplayerBackgroundColor ?: $this->theme->parametres->couleurL); $this->lessVariables['audioplayer-icon-color'] = wsHTML5::colorToCSS($this->theme->parametres->audioplayerIconColor); $this->config->audioplayerStrokeColor = $this->lessVariables['audioplayer-stroke-color'] = wsHTML5::colorToCSS($this->theme->parametres->audioplayerStrokeColor ?: $this->theme->parametres->couleurL); @@ -2833,6 +2834,9 @@ height="0" width="0" style="display:none;visibility:hidden"> $this->lessVariables['display-page-number'] = $this->_lessBoolean($this->theme->parametres->displayPageNumber); $this->lessVariables['page-transition-duration'] = $this->book->parametres->mobileTransitionDuration . 's'; + $this->config->mobileTransitionDurationSlide = ($this->book->parametres->mobileTransitionDurationSlide ?: $this->book->parametres->mobileTransitionDuration); + $this->lessVariables['page-transition-slide-duration'] = $this->config->mobileTransitionDurationSlide . 's'; + $corrText = $this->isMobileFirst() ? 0 : 4; $this->log('CSS 3'); -- 2.39.5