From 0dfbeccf1b353650cfb6c4c36298b32f981e8bc7 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Mon, 29 Jul 2013 14:20:23 +0000 Subject: [PATCH] --- inc/ws/Controlleur/class.ws.services.php | 7 ++++++- inc/ws/Util/html5/class.ws.html5.compiler.php | 4 +++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/inc/ws/Controlleur/class.ws.services.php b/inc/ws/Controlleur/class.ws.services.php index 1f68c41f3..64e979fd0 100644 --- a/inc/ws/Controlleur/class.ws.services.php +++ b/inc/ws/Controlleur/class.ws.services.php @@ -587,6 +587,7 @@ class wsServices extends cubeFlashGateway { $vroot = WS_COLLECTIONS . '/versions/' . $id . '/' . $version . '/' . $os . '/'; $publications = array(); + $langs = array(); foreach ($composition as $k => $g) { foreach ($g->publications as $l => $p) { @@ -605,10 +606,14 @@ class wsServices extends cubeFlashGateway { $couvertures[$p->id] = base64_encode(file_get_contents($couv)); $composition[$k]->publications[$l]->width = $book->parametres->width; $composition[$k]->publications[$l]->height = $book->parametres->height; + $composition[$k]->publications[$l]->lang = $book->lang; + $langs[] = $book->lang; } } - $d = array('id' => $id, 'time' => $version, 'datas' => $composition, 'couvertures' => $couvertures); + $langs = array_unique($langs); + + $d = array('id' => $id, 'langs' => $langs, 'time' => $version, 'datas' => $composition, 'couvertures' => $couvertures); $d = array_merge($d, $this->_getManifest($publications, '/fluidbook/collections/versions/' . $id . '/' . $version . '/' . $os, $books)); $dao = new wsDAOCollection($core->con); diff --git a/inc/ws/Util/html5/class.ws.html5.compiler.php b/inc/ws/Util/html5/class.ws.html5.compiler.php index cea8b7449..83438b1d6 100644 --- a/inc/ws/Util/html5/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/class.ws.html5.compiler.php @@ -144,13 +144,14 @@ class wsHTML5Compiler { protected $appcache; protected $home; protected $widget = true; + protected $multiApp = false; function __construct($book_id, $version = 'stable', $phonegap = false, $phonegapVersion = 'latest', $dir = null, $standalone = false, $appcache = false, $home = false) { global $core; $this->phonegapVersion = self::getPhonegapVersion($phonegapVersion); $this->appcache = $appcache; - $this->home = $home; + $this->multiApp = $this->home = $home; if ($version == 'stable') { $this->assets = WS_COMPILE_ASSETS . '/_html5prod'; @@ -829,6 +830,7 @@ class wsHTML5Compiler { if ($this->home) { $this->config->home = '%apphome%'; } + $this->config->multiApp = $this->multiApp; foreach ($this->additionalConfig as $k => $v) { $this->config->$k = $v; } -- 2.39.5