]> _ Git - cubeextranet.git/commitdiff
(no commit message)
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 30 May 2013 08:38:10 +0000 (08:38 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 30 May 2013 08:38:10 +0000 (08:38 +0000)
inc/ws/Controlleur/class.ws.flash.php
swf/_src/composerLibrary.swc
swf/_src/wsComposerLibrary.fla

index 0622ce6ec9d4745a7ff3e49ddc143117972fb11a..c656e79018e388915a9e1d2b1d9f9b1b40f97b04 100644 (file)
@@ -115,7 +115,7 @@ class wsFlash extends cubeFlashGateway {
                $php->setArg('HTTP_HOST', $_SERVER['HTTP_HOST']);\r
                $php->setNohup(true);\r
                $php->execute('exec');\r
-               \r
+\r
                fb($php->commande);\r
                fb($php->output);\r
 \r
@@ -510,18 +510,32 @@ class wsFlash extends cubeFlashGateway {
                $daoTheme = new wsDAOTheme($this->con);\r
                $theme = $daoTheme->getThemeOfBook($this->args['book_id'], true);\r
 \r
-               $specials = array('backgroundImage' => 'background', 'topBar' => 'topbar', 'afterSearch' => 'aftersearch');\r
+               $specials = array('backgroundImage' => 'background', 'topBar' => 'topbar', 'afterSearch' => 'aftersearch', 'externalArchives' => 'archives');\r
 \r
                foreach ($specials as $tparam => $sname) {\r
-                       $this->_addSpecialInfos($theme, $tparam, $sname);\r
+                       $this->_addSpecialInfos($book, $theme, $tparam, $sname);\r
                }\r
        }\r
 \r
-       protected function _addSpecialInfos($theme, $param, $specialName) {\r
-               if ($theme->parametres->$param != '') {\r
-                       $themeRoot = WS_THEMES . '/' . $theme->theme_id . '/';\r
-                       $dim = getimagesize($themeRoot . $theme->parametres->$param);\r
-                       $url = 'http://' . $_SERVER['HTTP_HOST'] . WEBROOT . '/fluidbook/themes/' . $theme->theme_id . '/' . $theme->parametres->$param;\r
+       protected function _addSpecialInfos($book, $theme, $param, $specialName) {\r
+               if ($specialName == 'archives') {\r
+                       $p = $book->parametres;\r
+                       \r
+               } else {\r
+                       $p = $theme->parametres;\r
+               }\r
+\r
+\r
+               if ($p->$param != '') {\r
+                       if ($specialName != 'archives') {\r
+                               $themeRoot = WS_THEMES . '/' . $theme->theme_id . '/';\r
+                               $dim = getimagesize($themeRoot . $p->$param);\r
+                               $url = 'http://' . $_SERVER['HTTP_HOST'] . WEBROOT . '/fluidbook/themes/' . $theme->theme_id . '/' . $p->$param;\r
+                       } else {\r
+                               $bookRoot = WS_BOOKS . '/working/' . $book->book_id . '/';\r
+                               $dim = getimagesize($bookRoot . $p->$param);\r
+                               $url = 'http://' . $_SERVER['HTTP_HOST'] . WEBROOT . '/fluidbook/books/working/' . $book->book_id . '/' . $p->$param;\r
+                       }\r
 \r
                        if ($this->json) {\r
                                $p = array('width' => $dim[0], 'height' => $dim[1], 'url' => $url);\r
@@ -611,16 +625,16 @@ class wsFlash extends cubeFlashGateway {
                $size = $firstDoc->generalInfos['size'];\r
                $this->xml->addChild('width', $size[0]);\r
                $this->xml->addChild('height', $size[1]);\r
-               $res = '<b>'.__('Nombre de pages') . '</b> : ' ;\r
+               $res = '<b>' . __('Nombre de pages') . '</b> : ';\r
                $res .= $nb_pages . ' ' . __('pages') . "\n";\r
                $res .= "\n";\r
-               $res .= '<b>'.__('Dimensions') . '</b> : ' . "\n";\r
+               $res .= '<b>' . __('Dimensions') . '</b> : ' . "\n";\r
                $res .= round($size[0], 3) . ' x ' . round($size[1], 3) . ' pts' . "\n";\r
                $res .= "\n";\r
-               $res .= '<b>'.__('Taille totale des pages') . '</b> : ' . "\n";\r
+               $res .= '<b>' . __('Taille totale des pages') . '</b> : ' . "\n";\r
                $res .= $total . "\n";\r
                $res .= "\n";\r
-               $res .= '<b>'.__('Taille moyenne des pages') . '</b> : ' . "\n";\r
+               $res .= '<b>' . __('Taille moyenne des pages') . '</b> : ' . "\n";\r
                $res .= $average . "\n";\r
                $res .= "\n";\r
                $this->xml->addChild('infos', $res);\r
index c1e6f04896896d5baa83f188ab424cc630187ff6..9506104772022d420d1501d163dba9c840f41c5b 100644 (file)
Binary files a/swf/_src/composerLibrary.swc and b/swf/_src/composerLibrary.swc differ
index 44df4b220d0b001c80b93b4210ebea8671ac8744..dfd3fbd50bb224de48c148f2b02c4505eaf7fe72 100644 (file)
Binary files a/swf/_src/wsComposerLibrary.fla and b/swf/_src/wsComposerLibrary.fla differ