Merge pull request #1241 from VipSaran/master

fix for #1209 (Reference strip using "thumbs")
This commit is contained in:
Ian Gilman 2017-07-11 11:50:47 -07:00 committed by GitHub
commit 31bee4028f
2 changed files with 13 additions and 1 deletions

View File

@ -428,9 +428,19 @@ function loadPanels( strip, viewerSize, scroll ) {
for ( i = activePanelsStart; i < activePanelsEnd && i < strip.panels.length; i++ ) { for ( i = activePanelsStart; i < activePanelsEnd && i < strip.panels.length; i++ ) {
element = strip.panels[i]; element = strip.panels[i];
if ( !element.activePanel ) { if ( !element.activePanel ) {
var miniTileSource;
var originalTileSource = strip.viewer.tileSources[i];
if (originalTileSource.referenceStripThumbnailUrl) {
miniTileSource = {
type: 'image',
url: originalTileSource.referenceStripThumbnailUrl
};
} else {
miniTileSource = originalTileSource;
}
miniViewer = new $.Viewer( { miniViewer = new $.Viewer( {
id: element.id, id: element.id,
tileSources: [strip.viewer.tileSources[i]], tileSources: [miniTileSource],
element: element, element: element,
navigatorSizeRatio: strip.sizeRatio, navigatorSizeRatio: strip.sizeRatio,
showNavigator: false, showNavigator: false,

View File

@ -60,6 +60,8 @@
* the extending classes implementation of 'configure'. * the extending classes implementation of 'configure'.
* @param {String} [options.url] * @param {String} [options.url]
* The URL for the data necessary for this TileSource. * The URL for the data necessary for this TileSource.
* @param {String} [options.referenceStripThumbnailUrl]
* The URL for the thumbnail image to be used by the reference strip
* @param {Function} [options.success] * @param {Function} [options.success]
* A function to be called upon successful creation. * A function to be called upon successful creation.
* @param {Boolean} [options.ajaxWithCredentials] * @param {Boolean} [options.ajaxWithCredentials]