From dc5b35dc4363c744c6ed5a80f43604b051dff024 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Tue, 29 Jan 2013 11:00:17 +0000 Subject: [PATCH] --- .../icones/bookmarks/bookmark-left-off.svg | 15 +++++++++++++ .../icones/bookmarks/bookmark-left-on.svg | 21 +++++++++++++++++++ .../icones/bookmarks/bookmark-right-off.svg | 15 +++++++++++++ .../icones/bookmarks/bookmark-right-on.svg | 21 +++++++++++++++++++ inc/ws/DAO/class.ws.dao.book.php | 6 ------ inc/ws/Util/class.ws.tools.php | 9 ++++++-- 6 files changed, 79 insertions(+), 8 deletions(-) create mode 100644 fluidbook/icones/bookmarks/bookmark-left-off.svg create mode 100644 fluidbook/icones/bookmarks/bookmark-left-on.svg create mode 100644 fluidbook/icones/bookmarks/bookmark-right-off.svg create mode 100644 fluidbook/icones/bookmarks/bookmark-right-on.svg diff --git a/fluidbook/icones/bookmarks/bookmark-left-off.svg b/fluidbook/icones/bookmarks/bookmark-left-off.svg new file mode 100644 index 000000000..aabfc093c --- /dev/null +++ b/fluidbook/icones/bookmarks/bookmark-left-off.svg @@ -0,0 +1,15 @@ + + + + + + diff --git a/fluidbook/icones/bookmarks/bookmark-left-on.svg b/fluidbook/icones/bookmarks/bookmark-left-on.svg new file mode 100644 index 000000000..56b7415e4 --- /dev/null +++ b/fluidbook/icones/bookmarks/bookmark-left-on.svg @@ -0,0 +1,21 @@ + + + + + + + diff --git a/fluidbook/icones/bookmarks/bookmark-right-off.svg b/fluidbook/icones/bookmarks/bookmark-right-off.svg new file mode 100644 index 000000000..c9544d7af --- /dev/null +++ b/fluidbook/icones/bookmarks/bookmark-right-off.svg @@ -0,0 +1,15 @@ + + + + + + diff --git a/fluidbook/icones/bookmarks/bookmark-right-on.svg b/fluidbook/icones/bookmarks/bookmark-right-on.svg new file mode 100644 index 000000000..f45323d43 --- /dev/null +++ b/fluidbook/icones/bookmarks/bookmark-right-on.svg @@ -0,0 +1,21 @@ + + + + + + + diff --git a/inc/ws/DAO/class.ws.dao.book.php b/inc/ws/DAO/class.ws.dao.book.php index b749040a6..a577363e0 100644 --- a/inc/ws/DAO/class.ws.dao.book.php +++ b/inc/ws/DAO/class.ws.dao.book.php @@ -1283,11 +1283,9 @@ class wsDAOBook extends commonDAO { } $mini = WS_COMPILE_ASSETS . '/_widget/' . $file; - $from = max(1, $book->parametres->widgetStart); $to = min($book->parametres->widgetEnd, count($pages)); - $swfcombine = new cubeCommandLine('swfcombine'); $swfcombine->setPath(CONVERTER_PATH); $swfcombine->setArg('merge'); @@ -1300,7 +1298,6 @@ class wsDAOBook extends commonDAO { $tempswf = array(); $timg = array(); - for ($i = $from; $i <= $to; $i++) { $page = $pages[$i]; @@ -1308,11 +1305,8 @@ class wsDAOBook extends commonDAO { $tempswf[$i] = cubeFiles::tempnam(); $it = new imageTools(); - - $image = WS_DOCS . '/' . $page['document_id'] . '/html/t150-' . $page['document_page'] . '.jpg'; - try { $it->loadImage($image); $it->resize($book->parametres->widgetSize, 10000); diff --git a/inc/ws/Util/class.ws.tools.php b/inc/ws/Util/class.ws.tools.php index 06c6de7da..e65989989 100644 --- a/inc/ws/Util/class.ws.tools.php +++ b/inc/ws/Util/class.ws.tools.php @@ -30,8 +30,13 @@ class wsTools { $nav = ($e[0] != 'share'); if ($nav) { - $dirColorized = WS_ICONS . '/' . $iconSet . '/mobile/' . $color . '/'; $svgRef = WS_ICONS . '/' . $iconSet . '/mobile/' . $icon . '.svg'; + if (!file_exists($svgRef)) { + $iconSet = 1; + $svgRef = WS_ICONS . '/' . $iconSet . '/mobile/' . $icon . '.svg'; + } + + $dirColorized = WS_ICONS . '/' . $iconSet . '/mobile/' . $color . '/'; $svgColorized = $dirColorized . '/' . $icon . '.svg'; } else { $dirColorized = WS_ICONS . '/share/' . $color; @@ -62,7 +67,7 @@ class wsTools { $w = rtrim($w, 'px'); $h = rtrim($h, 'px'); // Finally rasterize it - $batik = new cubeCommandLine('/usr/local/batik/batik-rasterizer'); + $batik = new cubeCommandLine('batik-rasterizer'); $batik->setArg('d', $dirColorized); $batik->setArg('m', 'image/png'); if ($scale != 1) { -- 2.39.5