$res .= '<table class="max">';
$res .= '<tr><td class="min nowrap">' . __('Activity') . '</td><td>' . form::field(array('settings[activity]', 'activity'), 20, 64, $collection->settings['activity']) . '</td></tr>';
$res .= '<tr><td class="min nowrap">' . __('Build') . '</td><td>' . form::field(array('settings[build]', 'build'), 10, 64, $collection->settings['build']) . '</td></tr>';
- $res .= '<tr><td class="min nowrap">' . __('Android License Key') . '</td><td>' . form::textArea(array('settings[license_key]', 'license_key'),50,3, $collection->settings['license_key']) . '</td></tr>';
+ $res .= '<tr><td class="min nowrap">' . __('Android License Key') . '</td><td>' . form::textArea(array('settings[license_key]', 'license_key'), 50, 3, $collection->settings['license_key']) . '</td></tr>';
$res .= '<tr><td class="min nowrap">' . __('Version') . '</td><td>' . form::field(array('settings[version]', 'version'), 10, 64, $collection->settings['version']) . '</td></tr>';
$res .= '<tr><td class="min nowrap">' . __('Orientation') . '</td><td>' . form::combo(array('settings[orientation]', 'orientation'), array(__('Portrait et Paysage') => 'unspecified', __('Portrait') => 'portrait', __('Paysage') => 'landscape'), $collection->settings['orientation']) . '</td></tr>';
$res .= '<tr><td class="min nowrap">' . __('Full offline') . '</td><td>' . form::checkbox(array('settings[offline]', 'offline'), 1, $collection->settings['offline']) . '</td></tr>';
$dao = new wsDAOBook($core->con);
$e = explode('_', $args[0]);
- $dao->compile($e[0], 'html5');
if (count($e) == 2 || $e[2] <= TIME - 15) {
$e[2] = TIME;
}
$book_id = $e[0];
+ $dao->compile($e[0], 'html5', false, true, true);
$hash = $e[1];
self::commonHTML5Viewer($book_id, $hash, 'u');
}
}
}
- public function compile($book_id, $version = 'all', $complete = false, $force = false) {
+ public function compile($book_id, $version = 'all', $complete = false, $force = false, $dev = false) {
if (is_null($book_id) || !$book_id) {
return;
}
$html5 = $html5 && !$this->isUpToDate($book, 'html5');
} else {
$v1 = false;
- $html5 = false;
+ $html5 = true;
$v2 = true;
}
}
if ($html5) {
fb(time(), 'Compile HTML5');
- $res .= $this->compileHTML5($book_id, $book);
+ $res .= $this->compileHTML5($book_id, $book, $dev);
$this->touchCompile($book_id, 'html5');
}
if ($v1 || $v2) {
}
}
- public function compileHTML5($book_id, $book) {
- $htmlCompiler = wsHTML5Compiler::factory($book_id, $book->parametres->mobileLVersion);
+ public function compileHTML5($book_id, $book, $dev = false) {
+ $version = $book->parametres->mobileLVersion;
+ if ($dev) {
+ $version = 'dev';
+ }
+
+ $htmlCompiler = wsHTML5Compiler::factory($book_id, $version);
$htmlCompiler->compile();
}