From 304a9ab03d6d0edcfa17880a9b4ba416110b8efb Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Tue, 2 May 2017 13:58:35 +0000 Subject: [PATCH] done #1344 @1 --- inc/ws/Controlleur/class.ws.maintenance.php | 4 +-- inc/ws/Metier/class.ws.book.parametres.php | 33 ++++++++++--------- inc/ws/Util/html5/class.ws.html5.compiler.php | 1 + inc/ws/Util/html5/class.ws.html5.links.php | 3 -- 4 files changed, 21 insertions(+), 20 deletions(-) diff --git a/inc/ws/Controlleur/class.ws.maintenance.php b/inc/ws/Controlleur/class.ws.maintenance.php index 25478665b..c4bddbe67 100644 --- a/inc/ws/Controlleur/class.ws.maintenance.php +++ b/inc/ws/Controlleur/class.ws.maintenance.php @@ -863,7 +863,7 @@ class wsMaintenance { $localDir = $playerDir . 'local/'; $git = new CubeIT_CommandLine_Git($branchesDir . 'fluidbook-html5'); echo '
';
-		echo $git->executeCmd('pull --all');
+		echo $git->executeCmd('fetch --all');
 		$git = new CubeIT_CommandLine_Git($branchesDir . 'fluidbook-html5');
 		$b = $git->executeCmd('branch -r');
 		echo $b;
@@ -894,7 +894,7 @@ class wsMaintenance {
 				mkdir($localDir . $b, 0777, true);
 			}
 			$git = new CubeIT_CommandLine_Git($branchesDir . $b);
-			echo $git->executeCmd('pull');
+			echo $git->executeCmd('reset --hard origin/' . $b);
 		}
 		echo '
'; file_put_contents(WS_CACHE . '/activebranches', json_encode($branches)); diff --git a/inc/ws/Metier/class.ws.book.parametres.php b/inc/ws/Metier/class.ws.book.parametres.php index 86db50ccf..95c58ea83 100644 --- a/inc/ws/Metier/class.ws.book.parametres.php +++ b/inc/ws/Metier/class.ws.book.parametres.php @@ -42,12 +42,28 @@ class wsBookParametres extends wsParametres { $soundFilter->name = __('Fichier sonore') . ' (*.mp3, *.wav)'; $soundFilter->extensions = '*.mp3;*.wav'; + $branches = array('master : git (stable)' => 'stable', + 'master : local (dev)' => 'dev'); + $gitbranches = json_decode(file_get_contents(WS_CACHE . '/activebranches')); + foreach ($gitbranches as $b) { + if ($b == 'master') { + continue; + } + $branches[$b . ' : git'] = $b . '|git'; + $branches[$b . ' : local'] = $b . '|local'; + } + + $this->fields['mobileLVersion'] = array('type' => 'combo', 'default' => 'stable', 'editable' => true, + 'label' => __('Version logicielle'), 'grade' => 1, + 'datas' => $branches + ); + $this->fields['version'] = array('type' => 'combo', 'default' => '2', 'editable' => true, 'label' => __('Version'), 'datas' => array('1' => '1', '2' => '2'), 'grade' => 3); $this->fields['title'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __("Titre de la publication"), 'embed' => false); $this->fields['url_link'] = array('type' => 'text', 'default' => 'http://', 'editable' => true, 'label' => __("URL du lien de retour au site")); $this->fields['signature'] = array('type' => 'combo', 'default' => '1', 'editable' => true, 'label' => __('Signature'), 'grade' => 3, 'datas' => wsDroits::getSignatures()); $this->forms['important'] = array('label' => __('Description de la publication'), - 'fieldsnames' => array('version', 'title', 'url_link', 'signature')); + 'fieldsnames' => array('version', 'mobileLVersion', 'title', 'url_link', 'signature')); // . // . @@ -322,19 +338,6 @@ class wsBookParametres extends wsParametres { $this->fields['navOrderH'] = array('type' => 'textarea', 'default' => '', 'editable' => true, 'label' => __('Ordre des icônes dans la nav') . ' (' . __('Si différente') . ')', 'grade' => 3); - $branches = array('master : git (stable)' => 'stable', - 'master : local (dev)' => 'dev'); - $gitbranches = json_decode(file_get_contents(WS_CACHE . '/activebranches')); - foreach ($gitbranches as $b) { - $branches[$b . ' : git'] = $b . '|git'; - $branches[$b . ' : local'] = $b . '|local'; - } - - $this->fields['mobileLVersion'] = array('type' => 'combo', 'default' => 'stable', 'editable' => true, - 'label' => __('Version logicielle'), 'grade' => 1, - 'datas' => $branches - ); - $this->fields['mobileTransitions'] = array('type' => 'combo', 'default' => 'flip', 'editable' => true, 'label' => __('Transitions entre les pages'), 'grade' => 3, 'datas' => array(__('Aucune transition') => 'none', __('Glisser') => 'slide', @@ -361,7 +364,7 @@ class wsBookParametres extends wsParametres { $this->fields['mobileIgnoreBackgroundLinks'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Ignorer les liens de background')); $this->forms['mobile'] = array('label' => __('Version mobile'), - 'fieldsnames' => array('alwaysHTML5', 'html5priority', 'mobileLVersion', 'mobileVersion', 'mobileNavigationType', '|', 'mobileNavScale', '|', 'mobileTransitions', 'mobileTransitionDuration', "mobileLinksRevealAnim", '|', 'navOrderH', '|', 'mobileIconVector', 'mobileServerConfig', 'mobilePlugins', '|', 'mobileVideosPath', '|', 'mobileExtraXSpace', '|', 'mobileIgnoreBackgroundLinks')); + 'fieldsnames' => array('alwaysHTML5', 'html5priority', 'mobileVersion', 'mobileNavigationType', '|', 'mobileNavScale', '|', 'mobileTransitions', 'mobileTransitionDuration', "mobileLinksRevealAnim", '|', 'navOrderH', '|', 'mobileIconVector', 'mobileServerConfig', 'mobilePlugins', '|', 'mobileVideosPath', '|', 'mobileExtraXSpace', '|', 'mobileIgnoreBackgroundLinks')); $this->fields['phonegapId'] = array('type' => 'text', 'default' => 'com.fluidbook.phonegap.$id', 'editable' => true, 'label' => __("Identifiant de l'identifiant"), 'grade' => 5, 'hint' => __('De la forme') . ' com.fluidbook.phonegap.xxxxx'); diff --git a/inc/ws/Util/html5/class.ws.html5.compiler.php b/inc/ws/Util/html5/class.ws.html5.compiler.php index 124f9860e..7568c4c31 100644 --- a/inc/ws/Util/html5/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/class.ws.html5.compiler.php @@ -1145,6 +1145,7 @@ class wsHTML5Compiler { $offsetLeft2 = $offsetLeft * 2; $offsetTop = round(($this->optimalHeight - $cssHeight) / 2, 3); $navTop = ($cssHeight - 40 - 100) / 2; + $leftOfRightPage=(floor($cssWidth)-1).'px'; $res[] = '.portrait #pages,.portrait .doublePage.page,.page,.doublePage._3d,#shadow>div{width:' . $w . ';max-width:' . $w . ';height:' . $h . ';max-height:' . $h . '}'; diff --git a/inc/ws/Util/html5/class.ws.html5.links.php b/inc/ws/Util/html5/class.ws.html5.links.php index adc0138f7..63c76a44b 100644 --- a/inc/ws/Util/html5/class.ws.html5.links.php +++ b/inc/ws/Util/html5/class.ws.html5.links.php @@ -93,9 +93,6 @@ class wsHTML5Link { return new basketLink($id, $init, $compiler); case 13: // zoom area - if ($compiler->version == 'stable') { - return null; - } return new zoomLink($id, $init, $compiler); case 14: return new colorLink($id, $init, $compiler); -- 2.39.5