]> _ Git - cubeextranet.git/commitdiff
(no commit message)
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 23 Jan 2013 16:18:06 +0000 (16:18 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 23 Jan 2013 16:18:06 +0000 (16:18 +0000)
fluidbook/icones/share/share-facebook-.png [deleted file]
fluidbook/icones/share/share-facebook.png [new file with mode: 0644]
inc/config.inc.php
inc/ws/Controlleur/class.ws.flash.php
inc/ws/Controlleur/class.ws.services.php
inc/ws/DAO/class.ws.dao.book.php
inc/ws/Metier/class.ws.book.parametres.php
inc/ws/Metier/class.ws.icone.php
inc/ws/Util/class.ws.secure.swf.php

diff --git a/fluidbook/icones/share/share-facebook-.png b/fluidbook/icones/share/share-facebook-.png
deleted file mode 100644 (file)
index e2dfc97..0000000
Binary files a/fluidbook/icones/share/share-facebook-.png and /dev/null differ
diff --git a/fluidbook/icones/share/share-facebook.png b/fluidbook/icones/share/share-facebook.png
new file mode 100644 (file)
index 0000000..e2dfc97
Binary files /dev/null and b/fluidbook/icones/share/share-facebook.png differ
index a74dd106aa51d271ae0c614f4297f005837fa7ec..a7a9d78ac99a7b81adb857c8d5f3e772313c77f4 100644 (file)
@@ -10,7 +10,7 @@ define('SITE_PATH', WEBROOT . '/');
 define('FONT_PATH', ROOT . '/fluidbook/fonts/');\r
 define('FTPROOT', '/home/extranet/ftp/');\r
 define('WINDOWS', false);\r
-define('CONVERTER_PATH', '/bin:/usr/bin:/usr/local/bin:/home/extranet/www/fluidbook/tools:/usr/local/flex:/usr/local/secureSWF:/usr/local/scour:/home/extranet/node_modules/uglify-js/bin:/usr/local/ImageMagick/bin');\r
+define('CONVERTER_PATH', '/home/extranet/www/fluidbook/tools:/usr/local/flex:/usr/local/scour');\r
 define('MXMLC_PATH', '/usr/local/flex/bin/mxmlc');\r
 define('MXMLC_PATH_3', '/usr/local/flex_sdk_3.6/bin/mxmlc');\r
 define('AS3_SOURCES', '/home/as/sources/as/as3');\r
index ab79954a87bc718f752d4aad0a0f476df0d47e78..2c4e0be0498bb0134f9d48808eb2586f9bad0f55 100644 (file)
@@ -613,6 +613,13 @@ class wsFlash extends cubeFlashGateway {
                $res .= "\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 .= $total . "\n";\r
+               $res .= "\n";\r
+               $res .= '<b>'.__('Taille moyenne des pages') . '</b> : ' . "\n";\r
+               $res .= $average . "\n";\r
+               $res .= "\n";\r
                $this->xml->addChild('infos', $res);\r
        }\r
 \r
index 450aee9cb386c53e68f4ed42a08cdf01a780b46e..844cc6b51809bce40eae27c991f2ea0d156e1e0e 100644 (file)
@@ -95,8 +95,8 @@ class wsServices extends cubeFlashGateway {
                        if ($total > 1) {\r
                                $s = ' (' . ($i + 1) . '/' . $total . ')';\r
                        }\r
-                       \r
-                       \r
+\r
+\r
 \r
                        // Send the email\r
                        $mail = new cubeMail();\r
@@ -172,6 +172,19 @@ class wsServices extends cubeFlashGateway {
                exit;\r
        }\r
 \r
+       public function googleplusShare() {\r
+               http::redirect('https://plus.google.com/share?url=' . urlencode($this->args['url']) . "&sgp=1");\r
+               exit;\r
+       }\r
+\r
+       public function linkedinShare() {\r
+               http::redirect('https://www.linkedin.com/cws/share?url=' . urlencode($this->args['url']) . '&isFramed=true&_ts=' . microtime(true));\r
+       }\r
+\r
+       public function viadeoShare() {\r
+               http::redirect('http://www.viadeo.com/shareit/share/?url=' . urlencode($this->args['url']));\r
+       }\r
+\r
        public function twitterShare() {\r
                $url = $this->shortenURL($this->args['url'], $this->args['id']);\r
 \r
index 1b12c79a90883bcb54d20371fa143da9fb86d16a..485a782ef6bb5bc6c428bb198af6d4edf8f9b9a8 100644 (file)
@@ -1158,6 +1158,11 @@ class wsDAOBook extends commonDAO {
                foreach (wsIcone::$files as $file) {\r
                        $flex->addBitmap($iconsRoot . 'nav-' . $file . '.png', 'nav_' . $file);\r
                }\r
+               // Share icons\r
+               $iconsRoot = WS_ICONS . '/share/';\r
+               foreach (wsIcone::$share as $file) {\r
+                       $flex->addBitmap($iconsRoot . 'share-' . $file . '.png', 'share_' . $file);\r
+               }\r
 \r
                // Multilang\r
                if (trim($book->parametres->multilang) != '') {\r
index 9984044246ba6f3001d627bfaec11c8602a11ae9..36bc8713bc597ea4951eedd2d5000c32327d42be 100644 (file)
@@ -46,25 +46,31 @@ class wsBookParametres extends wsParametres {
                        'fieldsnames' => array('version', 'title', 'url_link', 'signature'));\r
                // .\r
                // .\r
-               $this->fields['friend'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Envoyer à un ami'));\r
+               \r
                $this->fields['email_title'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __("Titre de l'email") . ' "' . __('Envoyer à un ami') . '"', 'hint' => __('Laisser vide pour utiliser la valeur par défaut'));\r
                $this->fields['email_body'] = array('type' => 'textarea', 'default' => '', 'editable' => true, 'label' => __("Corps de l'email") . ' "' . __('Envoyer à un ami') . '"', 'hint' => __('Laisser vide pour utiliser la valeur par défaut'));\r
                $this->fields['email_editable'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __("Permettre au lecteur de modifier le corps de l'email"));\r
                $this->fields['askAcknowledge'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __("Demander au destinataire un accusé de réception"), 'grade' => 3);\r
-               $this->fields['facebook'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Facebook'));\r
-               $this->fields['facebook_title'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __("Titre facebook"), 'hint' => __('Titre proposé sur la fonction de partage facebook (par défaut, titre de la publication)'));\r
-               $this->fields['facebook_description'] = array('type' => 'textarea', 'default' => '', 'editable' => true, 'label' => __("Description facebook"), 'grade' => 1, 'hint' => __('Description proposée sur la fonction de partage facebook (par défaut, vide)'));\r
+\r
+               $this->fields['facebook_title'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __("Titre du contenu partagé"), 'hint' => __('Titre proposé sur les fonction de partage (par défaut, titre de la publication)'));\r
+               $this->fields['facebook_description'] = array('type' => 'textarea', 'default' => '', 'editable' => true, 'label' => __("Description du contenu partagé"), 'grade' => 1, 'hint' => __('Description proposée sur les fonctions de partage (par défaut, vide)'));\r
+               $this->fields['twitter_description'] = array('type' => 'textarea', 'default' => '%title% : %short%', 'editable' => true, 'label' => __("Contenu Partage court"), 'hint' => __('Contenu du partagé sur les partages courts'));\r
                $this->fields['facebook_image'] = array('type' => 'freefile', 'default' => '', 'editable' => true,\r
                        'label' => __('Miniature affichée'), 'fileFilter' => $imageFilter);\r
+               \r
+               $this->fields['friend'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('E-mail'));\r
+               $this->fields['facebook'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Facebook'));\r
                $this->fields['twitter'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Twitter'));\r
-               $this->fields['twitter_description'] = array('type' => 'textarea', 'default' => '%title% : %short%', 'editable' => true, 'label' => __("Contenu Twitter"), 'hint' => __('Contenu du Twit'));\r
+               $this->fields['googleplus'] = array('type' => 'boolean', 'default' => true, 'editable' => true, 'label' => __('Google +'));\r
+               $this->fields['linkedin'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('LinkedIn'));\r
+               $this->fields['viadeo'] = array('type' => 'boolean', 'default' => false, 'editable' => true, 'label' => __('Viadeo'));\r
                $this->fields['customSharer'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __("Classe personnalisée de partage"), 'grade' => 5);\r
                $this->fields['friendWidth'] = array('type' => 'integer', 'default' => 319, 'editable' => true, 'label' => __('Largeur du menu'), 'grade' => 5);\r
                $this->fields['friendHeight'] = array('type' => 'integer', 'default' => 500, 'editable' => true, 'label' => __('Largeur du menu'), 'grade' => 5);\r
                $this->forms['share'] = array('label' => __('Fonctions de partage'),\r
-                       'fieldsnames' => array('friend', 'email_title', 'email_body', 'email_editable', 'askAcknowledge', '|',\r
-                               'facebook', 'facebook_title', 'facebook_description', 'facebook_image', '|',\r
-                               'twitter', 'twitter_description', '|', 'customSharer', '|', 'friendWidth', 'friendHeight'));\r
+                       'fieldsnames' => array('email_title', 'email_body', 'email_editable', 'askAcknowledge', '|',\r
+                               'facebook_title', 'facebook_description', 'facebook_image', 'twitter_description', '|',\r
+                               'friend', 'facebook', 'twitter', 'googleplus', 'linkedin', 'viadeo', '|', 'customSharer', '|', 'friendWidth', 'friendHeight'));\r
                // .\r
                $this->fields['pages'] = array('type' => 'integer', 'default' => '', 'editable' => false, 'label' => __('Nombre de pages'));\r
                $this->fields['width'] = array('type' => 'float', 'default' => '', 'editable' => false, 'label' => __('Largeur'));\r
index 6485c51ed15531d8fc929addebbbc795cb9111b6..c8cabb9f98caacac8f8782a7ed3c1e27df112b10 100644 (file)
@@ -5,7 +5,8 @@ class wsIcone extends cubeMetier {
        public $icone_id;\r
        public $nom;\r
        public $date;\r
-       public static $files = array('index', 'normal', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'normalscreen', 'save', 'archives', 'help', '2d', '3d', 'soundon', 'soundoff', 'basket', 'previous', 'home', 'email', 'facebook', 'twitter');\r
+       public static $files = array('index', 'normal', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'normalscreen', 'save', 'archives', 'help', '2d', '3d', 'soundon', 'soundoff', 'basket', 'previous', 'home');\r
+       public static $share = array('email', 'facebook', 'twitter', 'googleplus', 'linkedin', 'viadeo');\r
        public static $display = array('index', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'save', '3d', 'soundon', 'help');\r
 \r
        public function makeImage() {\r
@@ -37,7 +38,9 @@ class wsIcone extends cubeMetier {
                $height = $h;\r
 \r
                $im = imagecreatetruecolor($w, $h);\r
-               imagelayereffect($im, IMG_EFFECT_REPLACE);\r
+               if (function_exists('imagelayereffect')) {\r
+                       imagelayereffect($im, IMG_EFFECT_REPLACE);\r
+               }\r
                $color = imagecolorallocatealpha($im, 255, 255, 255, 127);\r
                imagefill($im, 0, 0, $color);\r
                imagesavealpha($im, true);\r
index e01891ff5078ccde30c60bb037e6986929e4384e..7478902cbb6a5f9b65ca80fef43d6e7a33e99cba 100644 (file)
@@ -81,7 +81,7 @@ class wsSecureSWF {
 \r
        protected static function protectFiles()\r
        {\r
-               $secureSWF = new cubeCommandLine('secureSWF', null, true);\r
+               $secureSWF = new cubeCommandLine('sudo secureSWF', null, true);\r
                $secureSWF->setPath(CONVERTER_PATH);\r
                $secureSWF->setManualArg(self::$configLocal);\r
                $secureSWF->setManualArg(self::$protected);\r