From c72b7e54e627cdb3b8f88b2babf5e38f5755cdd7 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Fri, 17 Dec 2010 10:11:47 +0000 Subject: [PATCH] --- inc/ws/Controlleur/class.ws.flash.php | 3 ++- inc/ws/Controlleur/class.ws.url.php | 2 +- inc/ws/Metier/class.ws.book.parametres.php | 15 +++++++++++---- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/inc/ws/Controlleur/class.ws.flash.php b/inc/ws/Controlleur/class.ws.flash.php index fe57c4c05..90e5f6a74 100644 --- a/inc/ws/Controlleur/class.ws.flash.php +++ b/inc/ws/Controlleur/class.ws.flash.php @@ -490,8 +490,9 @@ class wsFlash extends cubeFlashGateway { if (!$dao->isUpToDate($this->args['book_id'])) { $dao->compile($this->args['book_id'], 3); } + $book = $dao->selectById($this->args['book_id']); - $absoluteURL = 'http://' . $_SERVER['HTTP_HOST'] . '/fluidbook/books/final/' . $this->args['book_id'] . '/'; + $absoluteURL = 'http://' . $_SERVER['HTTP_HOST'] . '/viewer/' . $book->book_id . '_' . $book->hash . '_' . TIME . '/'; $this->xml->addChild('compiledBook', '/fluidbook/compile/index.swf?base=' . $absoluteURL); } } diff --git a/inc/ws/Controlleur/class.ws.url.php b/inc/ws/Controlleur/class.ws.url.php index 5ceb91e27..a2bfce98b 100644 --- a/inc/ws/Controlleur/class.ws.url.php +++ b/inc/ws/Controlleur/class.ws.url.php @@ -178,7 +178,7 @@ html{height:100%}' . "\n"; $res .= ''; $res .= ''; - $res .= cubeMedia::flash2($webcompile . 'index.swf?junk=' . TIME, '100%', '100%', $fv, 'fluidbook', '', 10, '#ffffff', '', true); + $res .= cubeMedia::flash2($webcompile . 'index.swf?junk=' . TIME, '100%', '100%', $fv, 'fluidbook', '', 10, '#ffffff', '', 'true','noscale','gpu',array('allowScriptAccess'=>'always')); $gacodes = array(GA); if ($book->parametres->googleAnalytics != '') { diff --git a/inc/ws/Metier/class.ws.book.parametres.php b/inc/ws/Metier/class.ws.book.parametres.php index 178c5d85e..b62a8d169 100644 --- a/inc/ws/Metier/class.ws.book.parametres.php +++ b/inc/ws/Metier/class.ws.book.parametres.php @@ -44,16 +44,23 @@ class wsBookParametres extends wsParametres { $this->fields['width'] = array('type' => 'float', 'default' => '', 'editable' => false, 'label' => __('Largeur'), 'extra' => false, 'grade' => 0); $this->fields['height'] = array('type' => 'float', 'default' => '', 'editable' => false, 'label' => __('Hauteur'), 'extra' => false, 'grade' => 0); // . - $this->fields['twoDmode'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __("Activer le mode 2D"), 'extra' => false, 'grade' => 1); + $this->fields['visualisationMode'] = array('type' => 'combo', 'default' => '3', 'editable' => true, 'label' => __("Mode de visualisation"), 'extra' => false, 'grade' => 1, + 'datas' => array(__('Mode 3D') => '0', + __('Mode 2D (caméra fixe et pages à plat)') => '1', + __("Laisser le choix à l'utilisateur (mode 3D par défaut)")=>'2', + __("Laisser le choix à l'utilisateur (mode 2D par défaut)")=>'3')); $this->fields['pagesBaseAngle'] = array('type' => 'integer', 'default' => 2, 'editable' => true, 'label' => __('Angle de base entre les pages'), 'extra' => true, grade => 1, - 'hint' => __("0 : Publication à plat") . "\n" . __('2 : Valeur par défaut'), 'min' => 0, 'max' => 20); + 'hint' => __("0 : Publication à plat") . "\n" . __('2 : Valeur par défaut')); + $this->forms['3d_mode'] = array('label' => __('Visualisation en 3D'), + 'fieldsnames' => array('visualisationMode', 'pagesBaseAngle')); + $this->fields['print'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __("Activer l'impression"), 'extra' => false, 'grade' => 1); $this->fields['search'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Activer le moteur de recherche'), 'extra' => false, 'grade' => 1); $this->fields['bookmark'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Activer les marques-pages'), 'extra' => false, 'grade' => 1); $this->fields['fullscreen'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Activer le mode plein-écran'), 'extra' => false, 'grade' => 1); $this->fields['url_link'] = array('type' => 'text', 'default' => 'http://', 'editable' => true, 'label' => __("URL du lien de retour au site"), 'extra' => false, 'grade' => 1); $this->forms['general'] = array('label' => __('Fonctionnalités générales'), - 'fieldsnames' => array('print', 'search', 'bookmark', 'fullscreen', 'twoDmode', 'pagesBaseAngle', 'pages', 'width', 'height')); + 'fieldsnames' => array('print', 'search', 'bookmark', 'fullscreen', 'pages', 'width', 'height')); // . $this->fields['first_page_nr'] = array('type' => 'integer', 'default' => 1, 'editable' => true, 'label' => __('La numérotation débute à la page'), 'extra' => false, 'grade' => 1); $this->fields['preload'] = array('type' => 'integer', 'default' => 16, 'editable' => true, 'label' => __('Nombre de pages à précharger'), 'extra' => false, 'grade' => 1); @@ -81,7 +88,7 @@ class wsBookParametres extends wsParametres { $this->fields['googleAnalytics'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Code Google Analytics'), 'size' => 10, 'extra' => true, 'grade' => 1); $this->fields['stats_score'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Affiche le score dans les statistiques'), 'extra' => false, 'grade' => 1); $this->forms['stats'] = array('label' => __('Statistiques'), - 'fieldsnames' => array('stats','googleAnalytics', 'statsWeborama')); + 'fieldsnames' => array('stats', 'googleAnalytics', 'statsWeborama')); // . $this->fields['displayChaptersAtStart'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __("Afficher le sommaire au chargement de la publication"), 'extra' => true, 'grade' => 4); $this->fields['chaptersPosition'] = array('type' => 'combo', -- 2.39.5