]> _ Git - cubeextranet.git/commitdiff
(no commit message)
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Mon, 14 Oct 2013 16:12:34 +0000 (16:12 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Mon, 14 Oct 2013 16:12:34 +0000 (16:12 +0000)
inc/ws/Controlleur/class.ws.url.php
inc/ws/Util/class.ws.links.php
inc/ws/Util/html5/class.ws.html5.compiler.php
inc/ws/Util/html5/class.ws.html5.links.php

index 693078716cbfa7fc6496fbd2ef3924519deaf9ed..05ca9ec553159c4be94e97b0ca6b49fc88dfbb83 100644 (file)
@@ -642,7 +642,7 @@ class wsUrl {
                $res .= commonPage::bf();\r
 \r
                $res .= commonPage::bh();\r
-               $res .= cubeLang::translationForm(array(__('Version Flash') => PLAYER_SOURCES, __('Version HTML5') => WS_COMPILE_ASSETS . '/_html5', __('Application') => WS_COMPILE_ASSETS . '/_html5app'), $lang_id, null, 'liste', array(), '<a href="#" class="submit">' . $core->typo->Ajouter(__('Enregistrer')) . '</a>', $lang->traductions);\r
+               $res .= cubeLang::translationForm(array(__('Version Flash') => PLAYER_SOURCES, __('Version HTML5') => WS_COMPILE_ASSETS . '/_html5', __('Compilateur HTML5') => ROOT . '/inc/ws/Util/html5', __('Application') => WS_COMPILE_ASSETS . '/_html5app'), $lang_id, null, 'liste', array(), '<a href="#" class="submit">' . $core->typo->Ajouter(__('Enregistrer')) . '</a>', $lang->traductions);\r
                $res .= commonPage::bf();\r
                $res .= '</form>';\r
                return $res;\r
index 10da61d61abc4514db48bc049c457bc36e6df502..912911c4f4e3be5c65474b54903cf924a8c99c12 100644 (file)
@@ -14,7 +14,7 @@ class wsLinks {
 
        public static function linksToExcel($links, $rulers, $pages = null) {
                $cols = array(
-                       'page' => __('Page de la publication'), 'left' => __('x'), 'top' => __('y'), 'width' => __('Largeur'), 'height' => __('Hauteur'),
+                       'page' => __('Page de la publication'), 'left' => __('x'), 'top' => __('y'), 'width' => __('Largeur'), 'height' => __('Hauteur'), 'rot' => __('Rotation'),
                        'type' => __('Type'), 'to' => __('Destination'), 'target' => __('Cible'),
                        'infobulle' => __('Infobulle'), 'numerotation' => __('Numérotation'),
                        'display_area' => __('Activer la surbrillance'),
@@ -207,6 +207,9 @@ class wsLinks {
                                        $link = (array) $link;
                                        $link['page'] = $p;
                                        $link['id'] = $i;
+                                       if (!isset($link['rot'])) {
+                                               $link['rot'] = 0;
+                                       }
                                        $links[] = $link;
                                }
                        }
index 04ad4fcc268332823c208645a4f1b5a85df5cd26..c5f06d5f0de8e663d5ef15d9c3b6823082df8fb9 100644 (file)
@@ -14,8 +14,8 @@ class wsHTML5Compiler {
                        return new wsHTML5Compiler($book_id, 'stable', $phonegap, $phonegapVersion, $dir, $standalone, $appcache, $home);
                } else {
                        return new wsHTML5CompilerDev($book_id, 'dev', $phonegap, $phonegapVersion, $dir, $standalone, $appcache, $home);
-               } 
-       } 
+               }
+       }
 
        protected static $resolutions = array(150, 300);
        protected $maxRes = 300;
@@ -477,12 +477,9 @@ class wsHTML5Compiler {
                $cache = '';
                if ($this->appcache) {
                        $cache = ' manifest="cache.appcache"';
-               } 
-                       
-               $script = '';
-               if ($this->phonegap) {
-                       //$script .= '<script type="text/javascript" charset="utf-8" src="data/cordova.js"></script>' . "\n";
                }
+
+               $script = '';
                $script .= '<script type="text/javascript" charset="utf-8" src="data/datas.js"></script>' . "\n";
                $script .= '<script type="text/javascript" charset="utf-8" src="data/fluidbook.js"></script>' . "\n";
                $script .= '<script type="text/javascript" charset="utf-8" src="data/search.js"></script>' . "\n";
@@ -496,6 +493,7 @@ class wsHTML5Compiler {
                }
 
                $print = $this->writePrint();
+               $message = sprintf($this->__('Your browser is not up to date and is not able to run this publication. %sLearn more%s'), '<a href="http://www.whatbrowser.org/intl/' . $this->config->defaultLang . '/" target="_blank">', '</a>');
 
                $splash = '';
                if ($this->theme->parametres->logoLoader) {
@@ -506,13 +504,12 @@ class wsHTML5Compiler {
                        }
                }
 
-               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'pagesContents', 'description', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor');
+               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'pagesContents', 'description', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor', 'message');
                foreach ($vars as $v) {
                        $html = str_replace('<!-- $' . $v . ' -->', $$v, $html);
                }
 
                $scripts = array();
-               //$scripts[] = '<script type="text/javascript" charset="utf-8" src="http://argo.fluidbook.com:8234/target/target-script-min.js#fb_html5_' . $this->book_id . '"></script>';
                foreach ($this->debugJsFiles as $js) {
                        $scripts[] = '<script type="text/javascript" charset="utf-8" src="' . $js . '"></script>';
                }
@@ -535,13 +532,13 @@ class wsHTML5Compiler {
 
                $thtml = $uhtml;
 
-               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'pagesContents', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor');
+               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'pagesContents', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor', 'message');
                foreach ($vars as $v) {
                        $uhtml = str_replace('<!-- $' . $v . ' -->', $$v, $uhtml);
                }
 
                $script.="\n\t\t" . '<script type="text/javascript" charset="utf-8">window.tester = true;</script>';
-               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'print', 'hiddenContents', 'splash');
+               $vars = array('titre', 'credits', 'ga', 'style', 'script', 'print', 'hiddenContents', 'splash', 'message');
                foreach ($vars as $v) {
                        $thtml = str_replace('<!-- $' . $v . ' -->', $$v, $thtml);
                }
@@ -591,6 +588,14 @@ class wsHTML5Compiler {
                $this->config->filesInfos[$key] = $infos;
        }
 
+       protected function __($str) {
+               if (isset($this->config->l10n['default']->$str)) {
+                       return $this->config->l10n['default']->$str;
+               } else {
+                       return $str;
+               }
+       }
+
        protected function writeLangs() {
                global $core;
                $daoLang = new wsDAOLang($core->con);
index ca9dfa691a233cb26ca26c4054d9b07895c4aa86..b367dca783b83e0493bc8319c5dfdb596e228b66 100644 (file)
@@ -23,6 +23,7 @@ class wsHTML5Link {
        public $display_area;
        public $infobulle;
        public $id;
+       public $rot;
 
        /**
         *
@@ -214,6 +215,10 @@ class wsHTML5Link {
                $css = '#l_' . $this->id . '{';
                $css.='left:' . $this->left * $this->getCssScale() . 'px;top:' . $this->top * $this->getCssScale() . 'px;';
                $css.='width:' . $this->width * $this->getCssScale() . 'px;height:' . $this->height * $this->getCssScale() . 'px;';
+               if ($this->rot) {
+                       $css.= wsHTML5Compiler::writeCSSUA('transform', 'rotate(' . $this->rot . 'deg)');
+                       $css.= wsHTML5Compiler::writeCSSUA('transform-origin', '0% 0%');
+               }
                $css.=$this->getCSS();
                $css.='}';
                return $css;
@@ -675,6 +680,10 @@ class inpesPopinLink extends htmlMultimediaLink {
                $css = '#l_' . $this->id . '{';
                $css.='left:' . $this->left * $this->getCssScale() . 'px;top:' . $this->top * $this->getCssScale() . 'px;';
                $css.='width:' . $this->width * $this->getCssScale() . 'px;height:' . $this->height * $this->getCssScale() . 'px;';
+               if ($this->rot) {
+                       $css.= wsHTML5Compiler::writeCSSUA('transform', 'rotate(' . $this->rot . 'deg)');
+                       $css.= wsHTML5Compiler::writeCSSUA('transform-origin', '0% 0%');
+               }
                $css.=$this->getCSS();
                $css.='}';
                return $css;