let $this = this;
var infos = this.fluidbook.settings.pdfLinks[uid];
let c = this.getCaption('', 'nocaption', 'nocaption');
- c += '<div class="content"><div class="pdf-holder"><iframe class="pdf view ' + infos.interface + '" data-width="' + infos.width + '" data-height="' + infos.height + '" data-total-height="' + infos.totalHeight + '" frameborder="0" scrolling="no" src="pdfjs/web/viewer.'+this.fluidbook.settings.htmlExtension+'?&file=../../data/links/' + infos.file + '#zoom=page-width"></iframe></div></div>';
+ c += '<div class="content"><div class="pdf-holder"><iframe class="pdf view ' + infos.interface + '" data-width="' + infos.width + '" data-height="' + infos.height + '" data-total-height="' + infos.totalHeight + '" frameborder="0" scrolling="no" src="pdfjs/web/viewer.' + this.fluidbook.settings.htmlExtension + '?&file=../../data/links/' + infos.file + '#zoom=page-width"></iframe></div></div>';
this.viewWrap(c, 'pdf', '', 'pdf');
if (callback != undefined) {
callback();
if ($(".indexViewHolder").find('.doubleThumb:not(.simple)').length > 0) {
baseWidth = 230;
}
- var indexWidth = Math.floor(w / baseWidth) * baseWidth;
+ var indexWidth = Math.max(1, Math.floor(w / baseWidth)) * baseWidth;
$(".indexViewHolder").css('width', indexWidth);
}