$res = [150, 300];
} else if ($this->maxRes <= 150) {
$res = [$this->maxRes];
- }
+ }
if ($this->widget) {
$res = array_merge(array(36), $res);
if ($this->book->parametres->scorm_enable) {
$this->book->parametres->seoVersion = false;
}
+ if ($this->book->parametres->embedAllLibraries) {
+ $this->addVideoJs();
+ }
$this->writeStats();
$this->writeSecure();
$this->log('Copied assets');
protected function writeIndex()
{
+
+
$iv = $this->getIndexVars();
$this->log('Got index vars');
foreach ($iv as $k => $v) {
$config = $this->writeConfig();
$this->vdir->file_put_contents('data/datas.js', $config);
+
$finals = $this->jsLibs;
if ($this->book->parametres->PDFRenderer === 'pdfjs') {
$this->vdir->copyDirectory(WS_COMPILE_ASSETS . '/pdfjs-legacy', 'pdfjs');
}
+ if (stripos($this->book->parametres->PDFRenderer, 'pdfjs') !== false) {
+ $css = '.openFile,.rotateCw,.rotateCcw,.rotateCcw + .horizontalToolbarSeparator{display:none !important;}' . $this->book->parametres->PDFJSCSS;
+ $this->vdir->file_put_contents('pdfjs/web/viewer.css', file_get_contents(WS_COMPILE_ASSETS . '/' . $this->book->parametres->PDFRenderer . '/web/viewer.css') . $css);
+ }
+
if ($this->book->parametres->scorm_enable) {
$finals['scorm'] = array();
$finals['scorm'][] = 'js/libs/scorm/apiwrapper.js';