core-pdf PDF Core Upload PDF files to assign to Layouts fa fa-file-pdf-o \Xibo\Widget\PdfProvider pdf 1 1 0 html 60 Valid Extensions The Extensions allowed on files uploaded using this module. Comma Separated. pdf Duration is per page The duration specified is per page otherwise it is per document. Not supported on Tizen and webOS Displays. ]]> = pdfDoc.numPages) { pageNum = 0; } pageNum++; queueRenderPage(pageNum); } /** * Back to first page */ function onFirstPage() { pageNum = 1; queueRenderPage(pageNum); } /** * Asynchronously downloads PDF. */ pdfjsLib.getDocument({url: url, isEvalSupported: false}).promise.then(function(pdfDoc_) { pdfDoc = pdfDoc_; pdfLoaded = true; var startInterval = function(interval) { // Set a timer setInterval(function() { onNextPage(); }, interval * 1000); }; // Initial/first page rendering renderPage(pageNum); if (properties.durationIsPerItem) { // Set new widget duration by number of pages xiboIC.setWidgetDuration( (properties.duration * pdfDoc.numPages), { done: function() { // Callback after the request // Start interval ( the defined duration ) startInterval(properties.duration); }, error: function() { // If the call fails, keep the defalt behaviour startInterval(properties.duration / pdfDoc.numPages); } } ); } else { // Start interval ( total duration divided by the number of pages ) startInterval(properties.duration / pdfDoc.numPages); } }); // Render page on window resize window.addEventListener('resize', function(event) { if(pdfLoaded) { onFirstPage(); } }, true); ]]>