
	// Configuração Highslide no centro, fundo escuro, bordas arredondadas
	hs.showCredits = 0;
	hs.padToMinWidth = true;
	hs.graphicsDir = '/Portal/artefatos/highslide/graphics/';
	hs.align = 'center';
	hs.fadeInOut = true;
	hs.allowHeightReduction = false;
	hs.marginBottom = 100;
	hs.zIndexCounter = 3000;
	hs.outlineType = 'rounded-white';
	//hs.transitions = ['expand', 'crossfade'];
	//hs.dimmingOpacity = 0.8;
	hs.allowMultipleInstances = false;
	
	var highslideModalZoom = { 
		objectType: 'iframe', 
		dimmingOpacity: 0.75,
		transitions: ['expand', 'crossfade']
	}
	
	var highslideModal = { 
		objectType: 'iframe', 
		dimmingOpacity: 0.75,
		transitions: ['fade']
	}
	var highslideModalRss = { 
		objectType: 'iframe', 
		dimmingOpacity: 0.75,
		transitions: ['fade'],
		width: 580,
		maxWidth: 580
	}

	var galleryOptions = {
		slideshowGroup: 'gallery',
		dimmingOpacity: 0.75,
		transitions: ['expand', 'crossfade'],
		fadeInOut: true,
		wrapperClassName: 'borderless floating-caption',
		numberPosition: 'heading'
		//wrapperClassName: 'dark',
		//autoplay:true
		//align: 'center',
		//marginLeft: 100,
	};

	if (galleryOptions) hs.addSlideshow({
		slideshowGroup: 'gallery',
		interval: 5000,
		repeat: false,
		useControls: true,
		overlayOptions: {
			className: 'text-controls',
			position: 'bottom center',
			relativeTo: 'viewport',
			offsetY: -60
		},
		thumbstrip: {
			position: 'bottom center',
			mode: 'horizontal',
			relativeTo: 'viewport'
		}
		
	});

		// d39622bdfae336393e8e167d3a2a8ffe		hs.graphicsDir = './resources/highslide/graphics/';
		//hs.transitions = ['expand', 'crossfade'];
		//hs.restoreCursor = null;
		//hs.lang.restoreTitle = 'Click for next image';
		/*hs.lang = {
		   loadingText : '',
		   loadingTitle : '',
		   number: ''
		};*/
		
		// Add the slideshow providing the controlbar and the thumbstrip
		
		var inPageOptions = {
			//hs.restoreCursor = null;
			//hs.lang.restoreTitle = 'Click for next image';
			transitions: ['expand', 'crossfade'],
			slideshowGroup: 'inPageOptions',
			outlineType: null,
			fadeInOut: true,
			useControls: true,
			restoreCursor: null,
			autoplay:false,			
			repeat: true,
			allowSizeReduction: true,
			wrapperClassName: 'in-page controls-in-heading',
			useBox: true,
			width: 497,
			height: 274,
			maxWidth: 497,
			maxHeight: 274,
			targetX: 'gallery-area 10px',
			targetY: 'gallery-area 10px'
		}
		if (inPageOptions) hs.addSlideshow ({
			//fadeInOut: false,
			slideshowGroup: 'inPageOptions',
			interval: 3000,
			transitions: ['expand', 'crossfade'],
			repeat: true,			
			overlayOptions: {
				position: 'bottom right',
				offsetY: 0
			},
			thumbstrip: {
				position: 'below',
				mode: 'horizontal',
				relativeTo: 'expander'
			},
			marginBottom: 60
		});
			
			// Open the first thumb on page load
			hs.Expander.prototype.onInit = function() {
			  if (this.slideshowGroup == 'inPageOptions') hs.expandDuration = 0;
			}
			
			hs.addEventListener(window, 'load', function() {
				obj = document.getElementById('1');
				if (obj != null){obj.onclick();}
			});
			
			// Cancel the default action for image click and do next instead
			hs.Expander.prototype.onImageClick = function() {
				if (/in-page/.test(this.wrapper.className))	return hs.next();
			}

			// Under no circumstances should the static popup be closed
			hs.Expander.prototype.onBeforeClose = function() {
				if (/in-page/.test(this.wrapper.className))	return false;
			}
			// ... nor dragged
			hs.Expander.prototype.onDrag = function() {
				if (/in-page/.test(this.wrapper.className))	return false;
			}

			// Keep the position after window resize
			hs.addEventListener(window, 'resize', function() {
				var i, exp;
				hs.page = hs.getPageSize();

				for (i = 0; i < hs.expanders.length; i++) {
					exp = hs.expanders[i];
					if (exp) {
						var x = exp.x,
							y = exp.y;

						// get new thumb positions
						exp.tpos = hs.getPosition(exp.el);
						x.calcThumb();
						y.calcThumb();

						// calculate new popup position
 						x.pos = x.tpos - x.cb + x.tb;
						x.scroll = hs.page.scrollLeft;
						x.clientSize = hs.page.width;
						y.pos = y.tpos - y.cb + y.tb;
						y.scroll = hs.page.scrollTop;
						y.clientSize = hs.page.height;
						exp.justify(x, true);
						exp.justify(y, true);

						// set new left and top to wrapper and outline
						exp.moveTo(x.pos, y.pos);
					}
			}
		});