if ($platform === 'windows') {
$p = 'windows-x32';
$exe = 'workshop';
- $version='0.50.2';
+ $version = '0.50.2';
} else if ($platform === 'mac') {
$p = 'mac-x64';
$exe = 'Fluidbook Workshop';
- $version='0.50.2';
+ $version = '0.50.2';
}
$path = ROOT . '/desktop';
$cl->setArg('title', 'Fluidbook Workshop');
$cl->setArg('output-dir', $outpath);
$cl->setArg('nw-version', $version);
- $cl->setArg('sdk-build');
+ //$cl->setArg('sdk-build');
$cl->setArg('main', 'index.html');
$cl->setArg('package-json');
//$cl->setArg('name', 'FluidbookWorkshop.exe');
}
}
- public static function themeParams(){
- $parent=new wsTheme();
- $t=new wsThemeParametres($parent);
+ public static function themeParams()
+ {
+ $parent = new wsTheme();
+ $t = new wsThemeParametres($parent);
$t->generateV3Form(false);
}
+
+ public static function processPage($args)
+ {
+ global $core;
+
+ $book_id = $args[0];
+ $page = $args[1];
+
+ $daoBook = new wsDAOBook($core->con);
+ $book = $daoBook->selectById($book_id);
+
+ $files = [
+ ['jpg', '300', true, true, 'html'],
+ ['jpg', '150', true, true, 'html'],
+ ['jpg', '150', false, true, 'html'],
+ ['jpg', '150', false, true, 'html'],
+ ['swf', '150', true, true, ''],
+ ['svg', '150', true, false, 'html'],
+ ['svg', '300', true, false, 'html'],
+ ['svg', '150', true, true, 'html'],
+ ['svg', '200', true, true, 'html'],
+ ];
+
+
+ foreach ($files as $file) {
+ $book->getFile($page, $file[0], $file[1], $file[2], $file[3], $file[4], true);
+ }
+
+ }
}
$this->fields['mobileIconVector'] = array('type' => 'boolean', 'default' => true, 'editable' => false, 'label' => __('Utiliser les icĂ´nes vectorielles'));
// $this->forms['mobile'] = array('label' => __('Version HTML5'),
// 'fieldsnames' => array('alwaysHTML5', 'html5priority', 'flashBlockedWait', 'mobileIconVector', 'mobileServerConfig'));
+ $this->fields['externalArchivesBack'] = array('type' => 'freefile', 'default' => '', 'editable' => true,
+ 'label' => __('Image de fond'), 'grade' => 3, 'fileFilter' => $imageFilter);
+ $this->fields['archivesLink'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Lien'), 'grade' => 5);
/** **/
$this->fields['version'] = array('type' => 'combo', 'default' => '2', 'editable' => true, 'label' => __('Version'), 'datas' => array('1' => '1', '2' => '2'), 'grade' => 3);
//.
$this->fields['externalArchives'] = array('type' => 'freefile', 'default' => '', 'editable' => true,
'label' => __('Archives'), 'grade' => 3, 'fileFilter' => $imageFilter);
- $this->fields['externalArchivesBack'] = array('type' => 'freefile', 'default' => '', 'editable' => true,
- 'label' => __('Image de fond'), 'grade' => 3, 'fileFilter' => $imageFilter);
- $this->fields['archivesLink'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Lien'), 'grade' => 5);
$this->fields['archivesLabel'] = array('type' => 'text', 'default' => '', 'editable' => true, 'label' => __('Label'), 'grade' => 5);
-
$this->forms['archives'] = array('label' => __('Archives'),
- 'fieldsnames' => array('externalArchives', 'externalArchivesBack', '|', 'archivesLink', 'archivesLabel'));
+ 'fieldsnames' => array('externalArchives', 'archivesLabel'));
// .
$this->fields['form'] = array('type' => 'combo', 'default' => '', 'editable' => true, 'grade' => 5, 'label' => __('Formulaire'), 'datas' =>
array(__('Aucun') => '',
return $this->$varname;\r
}\r
\r
- public function getFile($page, $format = 'jpg', $resolution = 150, $withText = true, $withGraphics = true, $version = 'html')\r
+ public function getFile($page, $format = 'jpg', $resolution = 150, $withText = true, $withGraphics = true, $version = 'html',$force=false)\r
{\r
$p = wsDAOBook::getDocumentPage($this->book_id, $page);\r
if (!isset($this->_docs[$p['document_id']])) {\r
$this->_docs[$p['document_id']] = $dao->selectById($p['document_id']);\r
}\r
$doc = $this->_docs[$p['document_id']];\r
- return $doc->getFile($p['document_page'], $format, $resolution, $withText, $withGraphics, $version);\r
+ return $doc->getFile($p['document_page'], $format, $resolution, $withText, $withGraphics, $version,$force);\r
}\r
\r
public function getThumbFile($page, $format)\r
$file .= '-' . $resolution;
}
$file .= '.svg';
- $reffile = $this->makeSVGFile($page);
+ $reffile = $this->makeSVGFile($page, $force);
$minsize = 100;
} else if ($format === 'png' || $format === 'jpg') {
$prefix = $withText ? 't' : 'h';