/******************************************************************************************** Cufon font render ********************************************************************************************/ /* * Copyright (c) 2009 Simo Kinnunen. * Licensed under the MIT license. * * @version 1.09i */ var Cufon=(function(){var m=function(){return m.replace.apply(null,arguments)};var x=m.DOM={ready:(function(){var C=false,E={loaded:1,complete:1};var B=[],D=function(){if(C){return}C=true;for(var F;F=B.shift();F()){}};if(document.addEventListener){document.addEventListener("DOMContentLoaded",D,false);window.addEventListener("pageshow",D,false)}if(!window.opera&&document.readyState){(function(){E[document.readyState]?D():setTimeout(arguments.callee,10)})()}if(document.readyState&&document.createStyleSheet){(function(){try{document.body.doScroll("left");D()}catch(F){setTimeout(arguments.callee,1)}})()}q(window,"load",D);return function(F){if(!arguments.length){D()}else{C?F():B.push(F)}}})(),root:function(){return document.documentElement||document.body}};var n=m.CSS={Size:function(C,B){this.value=parseFloat(C);this.unit=String(C).match(/[a-z%]*$/)[0]||"px";this.convert=function(D){return D/B*this.value};this.convertFrom=function(D){return D/this.value*B};this.toString=function(){return this.value+this.unit}},addClass:function(C,B){var D=C.className;C.className=D+(D&&" ")+B;return C},color:j(function(C){var B={};B.color=C.replace(/^rgba\((.*?),\s*([\d.]+)\)/,function(E,D,F){B.opacity=parseFloat(F);return"rgb("+D+")"});return B}),fontStretch:j(function(B){if(typeof B=="number"){return B}if(/%$/.test(B)){return parseFloat(B)/100}return{"ultra-condensed":0.5,"extra-condensed":0.625,condensed:0.75,"semi-condensed":0.875,"semi-expanded":1.125,expanded:1.25,"extra-expanded":1.5,"ultra-expanded":2}[B]||1}),getStyle:function(C){var B=document.defaultView;if(B&&B.getComputedStyle){return new a(B.getComputedStyle(C,null))}if(C.currentStyle){return new a(C.currentStyle)}return new a(C.style)},gradient:j(function(F){var G={id:F,type:F.match(/^-([a-z]+)-gradient\(/)[1],stops:[]},C=F.substr(F.indexOf("(")).match(/([\d.]+=)?(#[a-f0-9]+|[a-z]+\(.*?\)|[a-z]+)/ig);for(var E=0,B=C.length,D;E0){E=" "+E}}else{if(B400}if(I==500){I=400}for(var J in G){if(!k(G,J)){continue}J=parseInt(J,10);if(!F||JD){D=J}K.push(J)}if(ID){I=D}K.sort(function(M,L){return(E?(M>=I&&L>=I)?ML:(M<=I&&L<=I)?M>L:Mcufoncanvas{text-indent:0;}@media screen{cvml\\:shape,cvml\\:rect,cvml\\:fill,cvml\\:shadow{behavior:url(#default#VML);display:block;antialias:true;position:absolute;}cufoncanvas{position:absolute;text-align:left;}cufon{display:inline-block;position:relative;vertical-align:'+(h?"middle":"text-bottom")+";}cufon cufontext{position:absolute;left:-10000in;font-size:1px;}a cufon{cursor:pointer}}@media print{cufon cufoncanvas{display:none;}}").replace(/;/g,"!important;"));function c(i,j){return a(i,/(?:em|ex|%)$|^[a-z-]+$/i.test(j)?"1em":j)}function a(l,m){if(m==="0"){return 0}if(/px$/i.test(m)){return parseFloat(m)}var k=l.style.left,j=l.runtimeStyle.left;l.runtimeStyle.left=l.currentStyle.left;l.style.left=m.replace("%","em");var i=l.style.pixelLeft;l.style.left=k;l.runtimeStyle.left=j;return i}function f(l,k,j,n){var i="computed"+n,m=k[i];if(isNaN(m)){m=k.get(n);k[i]=m=(m=="normal")?0:~~j.convertFrom(a(l,m))}return m}var g={};function d(p){var q=p.id;if(!g[q]){var n=p.stops,o=document.createElement("cvml:fill"),i=[];o.type="gradient";o.angle=180;o.focus="0";o.method="sigma";o.color=n[0][1];for(var m=1,l=n.length-1;mO){O=K}if(I>N){N=I}if(K »'].join('')),over=function(){var $$=$(this),menu=getMenu($$);clearTimeout(menu.sfTimer);$$.showSuperfishUl().siblings().hideSuperfishUl()},out=function(){var $$=$(this),menu=getMenu($$),o=sf.op;clearTimeout(menu.sfTimer);menu.sfTimer=setTimeout(function(){o.retainPath=($.inArray($$[0],o.$path)>-1);$$.hideSuperfishUl();if(o.$path.length&&$$.parents(['li.',o.hoverClass].join('')).length<1){over.call(o.$path)}},o.delay)},getMenu=function($menu){var menu=$menu.parents(['ul.',c.menuClass,':first'].join(''))[0];sf.op=sf.o[menu.serial];return menu},addArrow=function($a){$a.addClass(c.anchorClass).append($arrow.clone())};return this.each(function(){var s=this.serial=sf.o.length;var o=$.extend({},sf.defaults,op);o.$path=$('li.'+o.pathClass,this).slice(0,o.pathLevels).each(function(){$(this).addClass([o.hoverClass,c.bcClass].join(' ')).filter('li:has(ul)').removeClass(o.pathClass)});sf.o[s]=sf.op=o;$('li:has(ul)',this)[($.fn.hoverIntent&&!o.disableHI)?'hoverIntent':'hover'](over,out).each(function(){if(o.autoArrows)addArrow($('>a:first-child',this))}).not('.'+c.bcClass).hideSuperfishUl();var $a=$('a',this);$a.each(function(i){var $li=$a.eq(i).parents('li');$a.eq(i).focus(function(){over.call($li)}).blur(function(){out.call($li)})});o.onInit.call(this)}).each(function(){var menuClasses=[c.menuClass];if(sf.op.dropShadows&&!($.browser.msie&&$.browser.version<7))menuClasses.push(c.shadowClass);$(this).addClass(menuClasses.join(' '))})};var sf=$.fn.superfish;sf.o=[];sf.op={};sf.IE7fix=function(){var o=sf.op;if($.browser.msie&&$.browser.version>6&&o.dropShadows&&o.animation.opacity!=undefined)this.toggleClass(sf.c.shadowClass+'-off')};sf.c={bcClass:'sf-breadcrumb',menuClass:'sf-js-enabled',anchorClass:'sf-with-ul',arrowClass:'sf-sub-indicator',shadowClass:'sf-shadow'};sf.defaults={hoverClass:'sfHover',pathClass:'overideThisToUse',pathLevels:1,delay:800,animation:{opacity:'show'},speed:'normal',autoArrows:true,dropShadows:true,disableHI:false,onInit:function(){},onBeforeShow:function(){},onShow:function(){},onHide:function(){}};$.fn.extend({hideSuperfishUl:function(){var o=sf.op,not=(o.retainPath===true)?o.$path:'';o.retainPath=false;var $ul=$(['li.',o.hoverClass].join(''),this).add(this).not(not).removeClass(o.hoverClass).find('>ul').hide().css('visibility','hidden');o.onHide.call($ul);return this},showSuperfishUl:function(){var o=sf.op,sh=sf.c.shadowClass+'-off',$ul=this.addClass(o.hoverClass).find('>ul:hidden').css('visibility','visible');sf.IE7fix.call($ul);o.onBeforeShow.call($ul);$ul.animate(o.animation,o.speed,function(){sf.IE7fix.call($ul);o.onShow.call($ul)});return this}})})(jQuery); ;(function($){$.fn.supersubs=function(options){var opts=$.extend({},$.fn.supersubs.defaults,options);return this.each(function(){var $$=$(this);var o=$.meta?$.extend({},opts,$$.data()):opts;var fontsize=$('').css({'padding':0,'position':'absolute','top':'-999em','width':'auto'}).appendTo($$).width();$('#menu-fontsize').remove();$ULs=$$.find('ul');$ULs.each(function(i){var $ul=$ULs.eq(i);var $LIs=$ul.children();var $As=$LIs.children('a');var liFloat=$LIs.css('white-space','nowrap').css('float');var emWidth=$ul.add($LIs).add($As).css({'float':'none','width':'auto'}).end().end()[0].clientWidth/fontsize;emWidth+=o.extraWidth;if(emWidth>o.maxWidth){emWidth=o.maxWidth}else if(emWidthul',this);var offsetDirection=$childUl.css('left')!==undefined?'left':'right';$childUl.css(offsetDirection,emWidth)})})})};$.fn.supersubs.defaults={minWidth:9,maxWidth:25,extraWidth:0}})(jQuery); /******************************************************************************************** PrettyPhoto Lightbox ********************************************************************************************/ (function($){$.prettyPhoto={version:'3.1.6'};$.fn.prettyPhoto=function(pp_settings){pp_settings=jQuery.extend({animation_speed:'fast',slideshow:5000,autoplay_slideshow:false,opacity:0.80,show_title:true,allow_resize:true,default_width:500,default_height:344,counter_separator_label:'/',theme:'pp_default',horizontal_padding:20,hideflash:false,wmode:'opaque',autoplay:true,modal:false,deeplinking:true,overlay_gallery:true,keyboard_shortcuts:true,changepicturecallback:function(){},callback:function(){},ie6_fallback:true,markup:'
\
 
\
\
\
\
\
\
\
\
\
\
\
\ Expand \
\ next \ previous \
\
\
\
\ Previous \

0/0

\ Next \
\

\
{pp_social}
\ Close \
\
\
\
\
\
\
\
\
\
\
\
\
',gallery_markup:'',image_markup:'',flash_markup:'',quicktime_markup:'',iframe_markup:'',inline_markup:'
{content}
',custom_markup:'',social_tools:''},pp_settings);var matchedObjects=this,percentBased=false,pp_dimensions,pp_open,pp_contentHeight,pp_contentWidth,pp_containerHeight,pp_containerWidth,windowHeight=$(window).height(),windowWidth=$(window).width(),pp_slideshow;doresize=true,scroll_pos=_get_scroll();$(window).unbind('resize.prettyphoto').bind('resize.prettyphoto',function(){_center_overlay();_resize_overlay();});if(pp_settings.keyboard_shortcuts){$(document).unbind('keydown.prettyphoto').bind('keydown.prettyphoto',function(e){if(typeof $pp_pic_holder!='undefined'){if($pp_pic_holder.is(':visible')){switch(e.keyCode){case 37:$.prettyPhoto.changePage('previous');e.preventDefault();break;case 39:$.prettyPhoto.changePage('next');e.preventDefault();break;case 27:if(!settings.modal) $.prettyPhoto.close();e.preventDefault();break;};};};});};$.prettyPhoto.initialize=function(){settings=pp_settings;if(settings.theme=='pp_default')settings.horizontal_padding=16;if(settings.ie6_fallback&&$.browser.msie&&parseInt($.browser.version)==6)settings.theme="light_square";theRel=$(this).attr('data-rel');galleryRegExp=/\[(?:.*)\]/;isSet=(galleryRegExp.exec(theRel))?true:false;pp_images=(isSet)?jQuery.map(matchedObjects,function(n,i){if($(n).attr('data-rel').indexOf(theRel)!=-1)return $(n).attr('href');}):$.makeArray($(this).attr('href'));pp_titles=(isSet)?jQuery.map(matchedObjects,function(n,i){if($(n).attr('data-rel').indexOf(theRel)!=-1)return($(n).find('img').attr('alt'))?$(n).find('img').attr('alt'):"";}):$.makeArray($(this).find('img').attr('alt'));pp_descriptions=(isSet)?jQuery.map(matchedObjects,function(n,i){if($(n).attr('data-rel').indexOf(theRel)!=-1)return($(n).attr('title'))?$(n).attr('title'):"";}):$.makeArray($(this).attr('title'));if(pp_images.length>30)settings.overlay_gallery=false;set_position=jQuery.inArray($(this).attr('href'),pp_images);rel_index=(isSet)?set_position:$("a[data-rel^='"+theRel+"']").index($(this));_build_overlay(this);if(settings.allow_resize) $(window).bind('scroll.prettyphoto',function(){_center_overlay();});$.prettyPhoto.open();return false;} $.prettyPhoto.open=function(event){if(typeof settings=="undefined"){settings=pp_settings;if($.browser.msie&&$.browser.version==6)settings.theme="light_square";pp_images=$.makeArray(arguments[0]);pp_titles=(arguments[1])?$.makeArray(arguments[1]):$.makeArray("");pp_descriptions=(arguments[2])?$.makeArray(arguments[2]):$.makeArray("");isSet=(pp_images.length>1)?true:false;set_position=0;_build_overlay(event.target);} if($.browser.msie&&$.browser.version==6)$('select').css('visibility','hidden');if(settings.hideflash)$('object,embed,iframe[src*=youtube],iframe[src*=vimeo]').css('visibility','hidden');_checkPosition($(pp_images).size());$('.pp_loaderIcon').show();if(settings.deeplinking) setHashtag();if(settings.social_tools){facebook_like_link=settings.social_tools.replace('{location_href}',encodeURIComponent(location.href));$pp_pic_holder.find('.pp_social').html(facebook_like_link);} if($ppt.is(':hidden'))$ppt.css('opacity',0).show();$pp_overlay.show().fadeTo(settings.animation_speed,settings.opacity);$pp_pic_holder.find('.currentTextHolder').text((set_position+1)+settings.counter_separator_label+$(pp_images).size());if(pp_descriptions[set_position]!=""){$pp_pic_holder.find('.pp_description').show().html(unescape(pp_descriptions[set_position]));}else{$pp_pic_holder.find('.pp_description').hide();} movie_width=(parseFloat(getParam('width',pp_images[set_position])))?getParam('width',pp_images[set_position]):settings.default_width.toString();movie_height=(parseFloat(getParam('height',pp_images[set_position])))?getParam('height',pp_images[set_position]):settings.default_height.toString();percentBased=false;if(movie_height.indexOf('%')!=-1){movie_height=parseFloat(($(window).height()*parseFloat(movie_height)/100)-150);percentBased=true;} if(movie_width.indexOf('%')!=-1){movie_width=parseFloat(($(window).width()*parseFloat(movie_width)/100)-150);percentBased=true;} $pp_pic_holder.fadeIn(function(){(settings.show_title&&pp_titles[set_position]!=""&&typeof pp_titles[set_position]!="undefined")?$ppt.html(unescape(pp_titles[set_position])):$ppt.html(' ');imgPreloader="";skipInjection=false;switch(_getFileType(pp_images[set_position])){case'image':imgPreloader=new Image();nextImage=new Image();if(isSet&&set_position<$(pp_images).size()-1)nextImage.src=pp_images[set_position+1];prevImage=new Image();if(isSet&&pp_images[set_position-1])prevImage.src=pp_images[set_position-1];$pp_pic_holder.find('#pp_full_res')[0].innerHTML=settings.image_markup.replace(/{path}/g,pp_images[set_position]);imgPreloader.onload=function(){pp_dimensions=_fitToViewport(imgPreloader.width,imgPreloader.height);_showContent();};imgPreloader.onerror=function(){alert('Image cannot be loaded. Make sure the path is correct and image exist.');$.prettyPhoto.close();};imgPreloader.src=pp_images[set_position];break;case'youtube':pp_dimensions=_fitToViewport(movie_width,movie_height);movie_id=getParam('v',pp_images[set_position]);if(movie_id==""){movie_id=pp_images[set_position].split('youtu.be/');movie_id=movie_id[1];if(movie_id.indexOf('?')>0) movie_id=movie_id.substr(0,movie_id.indexOf('?'));if(movie_id.indexOf('&')>0) movie_id=movie_id.substr(0,movie_id.indexOf('&'));} movie='http://www.youtube.com/embed/'+movie_id;(getParam('rel',pp_images[set_position]))?movie+="?rel="+getParam('rel',pp_images[set_position]):movie+="?rel=1";if(settings.autoplay)movie+="&autoplay=1";toInject=settings.iframe_markup.replace(/{width}/g,pp_dimensions['width']).replace(/{height}/g,pp_dimensions['height']).replace(/{wmode}/g,settings.wmode).replace(/{path}/g,movie);break;case'vimeo':pp_dimensions=_fitToViewport(movie_width,movie_height);movie_id=pp_images[set_position];var regExp=/http:\/\/(www\.)?vimeo.com\/(\d+)/;var match=movie_id.match(regExp);movie='http://player.vimeo.com/video/'+match[2]+'?title=0&byline=0&portrait=0';if(settings.autoplay)movie+="&autoplay=1;";vimeo_width=pp_dimensions['width']+'/embed/?moog_width='+pp_dimensions['width'];toInject=settings.iframe_markup.replace(/{width}/g,vimeo_width).replace(/{height}/g,pp_dimensions['height']).replace(/{path}/g,movie);break;case'quicktime':pp_dimensions=_fitToViewport(movie_width,movie_height);pp_dimensions['height']+=15;pp_dimensions['contentHeight']+=15;pp_dimensions['containerHeight']+=15;toInject=settings.quicktime_markup.replace(/{width}/g,pp_dimensions['width']).replace(/{height}/g,pp_dimensions['height']).replace(/{wmode}/g,settings.wmode).replace(/{path}/g,pp_images[set_position]).replace(/{autoplay}/g,settings.autoplay);break;case'flash':pp_dimensions=_fitToViewport(movie_width,movie_height);flash_vars=pp_images[set_position];flash_vars=flash_vars.substring(pp_images[set_position].indexOf('flashvars')+10,pp_images[set_position].length);filename=pp_images[set_position];filename=filename.substring(0,filename.indexOf('?'));toInject=settings.flash_markup.replace(/{width}/g,pp_dimensions['width']).replace(/{height}/g,pp_dimensions['height']).replace(/{wmode}/g,settings.wmode).replace(/{path}/g,filename+'?'+flash_vars);break;case'iframe':pp_dimensions=_fitToViewport(movie_width,movie_height);frame_url=pp_images[set_position];frame_url=frame_url.substr(0,frame_url.indexOf('iframe')-1);toInject=settings.iframe_markup.replace(/{width}/g,pp_dimensions['width']).replace(/{height}/g,pp_dimensions['height']).replace(/{path}/g,frame_url);break;case'ajax':doresize=false;pp_dimensions=_fitToViewport(movie_width,movie_height);doresize=true;skipInjection=true;$.get(pp_images[set_position],function(responseHTML){toInject=settings.inline_markup.replace(/{content}/g,responseHTML);$pp_pic_holder.find('#pp_full_res')[0].innerHTML=toInject;_showContent();});break;case'custom':pp_dimensions=_fitToViewport(movie_width,movie_height);toInject=settings.custom_markup;break;case'inline':myClone=$(pp_images[set_position]).clone().append('
').css({'width':settings.default_width}).wrapInner('
').appendTo($('body')).show();doresize=false;pp_dimensions=_fitToViewport($(myClone).width(),$(myClone).height());doresize=true;$(myClone).remove();toInject=settings.inline_markup.replace(/{content}/g,$(pp_images[set_position]).html());break;};if(!imgPreloader&&!skipInjection){$pp_pic_holder.find('#pp_full_res')[0].innerHTML=toInject;_showContent();};});return false;};$.prettyPhoto.changePage=function(direction){currentGalleryPage=0;if(direction=='previous'){set_position--;if(set_position<0)set_position=$(pp_images).size()-1;}else if(direction=='next'){set_position++;if(set_position>$(pp_images).size()-1)set_position=0;}else{set_position=direction;};rel_index=set_position;if(!doresize)doresize=true;$('.pp_contract').removeClass('pp_contract').addClass('pp_expand');_hideContent(function(){$.prettyPhoto.open();});};$.prettyPhoto.changeGalleryPage=function(direction){if(direction=='next'){currentGalleryPage++;if(currentGalleryPage>totalPage)currentGalleryPage=0;}else if(direction=='previous'){currentGalleryPage--;if(currentGalleryPage<0)currentGalleryPage=totalPage;}else{currentGalleryPage=direction;};slide_speed=(direction=='next'||direction=='previous')?settings.animation_speed:0;slide_to=currentGalleryPage*(itemsPerPage*itemWidth);$pp_gallery.find('ul').animate({left:-slide_to},slide_speed);};$.prettyPhoto.startSlideshow=function(){if(typeof pp_slideshow=='undefined'){$pp_pic_holder.find('.pp_play').unbind('click').removeClass('pp_play').addClass('pp_pause').click(function(){$.prettyPhoto.stopSlideshow();return false;});pp_slideshow=setInterval($.prettyPhoto.startSlideshow,settings.slideshow);}else{$.prettyPhoto.changePage('next');};} $.prettyPhoto.stopSlideshow=function(){$pp_pic_holder.find('.pp_pause').unbind('click').removeClass('pp_pause').addClass('pp_play').addClass('no-underline').click(function(){$.prettyPhoto.startSlideshow();return false;});clearInterval(pp_slideshow);pp_slideshow=undefined;} $.prettyPhoto.close=function(){if($pp_overlay.is(":animated"))return;$.prettyPhoto.stopSlideshow();$pp_pic_holder.stop().find('object,embed').css('visibility','hidden');$('div.pp_pic_holder,div.ppt,.pp_fade').fadeOut(settings.animation_speed,function(){$(this).remove();});$pp_overlay.fadeOut(settings.animation_speed,function(){if($.browser.msie&&$.browser.version==6)$('select').css('visibility','visible');if(settings.hideflash)$('object,embed,iframe[src*=youtube],iframe[src*=vimeo]').css('visibility','visible');$(this).remove();$(window).unbind('scroll.prettyphoto');clearHashtag();settings.callback();doresize=true;pp_open=false;delete settings;});};function _showContent(){$('.pp_loaderIcon').hide();projectedTop=scroll_pos['scrollTop']+((windowHeight/2)-(pp_dimensions['containerHeight']/2));if(projectedTop<0)projectedTop=0;$ppt.fadeTo(settings.animation_speed,1);$pp_pic_holder.find('.pp_content').animate({height:pp_dimensions['contentHeight'],width:pp_dimensions['contentWidth']},settings.animation_speed);$pp_pic_holder.animate({'top':projectedTop,'left':(windowWidth/2)-(pp_dimensions['containerWidth']/2),width:pp_dimensions['containerWidth']},settings.animation_speed,function(){$pp_pic_holder.find('.pp_hoverContainer,#fullResImage').height(pp_dimensions['height']).width(pp_dimensions['width']);$pp_pic_holder.find('.pp_fade').fadeIn(settings.animation_speed);if(isSet&&_getFileType(pp_images[set_position])=="image"){$pp_pic_holder.find('.pp_hoverContainer').show();}else{$pp_pic_holder.find('.pp_hoverContainer').hide();} if(pp_dimensions['resized']){$('a.pp_expand,a.pp_contract').show();}else{$('a.pp_expand').hide();} if(settings.autoplay_slideshow&&!pp_slideshow&&!pp_open)$.prettyPhoto.startSlideshow();settings.changepicturecallback();pp_open=true;});_insert_gallery();};function _hideContent(callback){$pp_pic_holder.find('#pp_full_res object,#pp_full_res embed').css('visibility','hidden');$pp_pic_holder.find('.pp_fade').fadeOut(settings.animation_speed,function(){$('.pp_loaderIcon').show();callback();});};function _checkPosition(setCount){(setCount>1)?$('.pp_nav').show():$('.pp_nav').hide();};function _fitToViewport(width,height){resized=false;_getDimensions(width,height);imageWidth=width,imageHeight=height;if(((pp_containerWidth>windowWidth)||(pp_containerHeight>windowHeight))&&doresize&&settings.allow_resize&&!percentBased){resized=true,fitting=false;while(!fitting){if((pp_containerWidth>windowWidth)){imageWidth=(windowWidth-200);imageHeight=(height/width)*imageWidth;}else if((pp_containerHeight>windowHeight)){imageHeight=(windowHeight-200);imageWidth=(width/height)*imageHeight;}else{fitting=true;};pp_containerHeight=imageHeight,pp_containerWidth=imageWidth;};_getDimensions(imageWidth,imageHeight);if((pp_containerWidth>windowWidth)||(pp_containerHeight>windowHeight)){_fitToViewport(pp_containerWidth,pp_containerHeight)};};return{width:Math.floor(imageWidth),height:Math.floor(imageHeight),containerHeight:Math.floor(pp_containerHeight),containerWidth:Math.floor(pp_containerWidth)+(settings.horizontal_padding*2),contentHeight:Math.floor(pp_contentHeight),contentWidth:Math.floor(pp_contentWidth),resized:resized};};function _getDimensions(width,height){width=parseFloat(width);height=parseFloat(height);$pp_details=$pp_pic_holder.find('.pp_details');$pp_details.width(width);detailsHeight=parseFloat($pp_details.css('marginTop'))+parseFloat($pp_details.css('marginBottom'));$pp_details=$pp_details.clone().addClass(settings.theme).width(width).appendTo($('body')).css({'position':'absolute','top':-10000});detailsHeight+=$pp_details.height();detailsHeight=(detailsHeight<=34)?36:detailsHeight;if($.browser.msie&&$.browser.version==7)detailsHeight+=8;$pp_details.remove();$pp_title=$pp_pic_holder.find('.ppt');$pp_title.width(width);titleHeight=parseFloat($pp_title.css('marginTop'))+parseFloat($pp_title.css('marginBottom'));$pp_title=$pp_title.clone().appendTo($('body')).css({'position':'absolute','top':-10000});titleHeight+=$pp_title.height();$pp_title.remove();pp_contentHeight=height+detailsHeight;pp_contentWidth=width;pp_containerHeight=pp_contentHeight+titleHeight+$pp_pic_holder.find('.pp_top').height()+$pp_pic_holder.find('.pp_bottom').height();pp_containerWidth=width;} function _getFileType(itemSrc){if(itemSrc.match(/youtube\.com\/watch/i)||itemSrc.match(/youtu\.be/i)){return'youtube';}else if(itemSrc.match(/vimeo\.com/i)){return'vimeo';}else if(itemSrc.match(/\b.mov\b/i)){return'quicktime';}else if(itemSrc.match(/\b.swf\b/i)){return'flash';}else if(itemSrc.match(/\biframe=true\b/i)){return'iframe';}else if(itemSrc.match(/\bajax=true\b/i)){return'ajax';}else if(itemSrc.match(/\bcustom=true\b/i)){return'custom';}else if(itemSrc.substr(0,1)=='#'){return'inline';}else{return'image';};};function _center_overlay(){if(doresize&&typeof $pp_pic_holder!='undefined'){scroll_pos=_get_scroll();contentHeight=$pp_pic_holder.height(),contentwidth=$pp_pic_holder.width();projectedTop=(windowHeight/2)+scroll_pos['scrollTop']-(contentHeight/2);if(projectedTop<0)projectedTop=0;if(contentHeight>windowHeight) return;$pp_pic_holder.css({'top':projectedTop,'left':(windowWidth/2)+scroll_pos['scrollLeft']-(contentwidth/2)});};};function _get_scroll(){if(self.pageYOffset){return{scrollTop:self.pageYOffset,scrollLeft:self.pageXOffset};}else if(document.documentElement&&document.documentElement.scrollTop){return{scrollTop:document.documentElement.scrollTop,scrollLeft:document.documentElement.scrollLeft};}else if(document.body){return{scrollTop:document.body.scrollTop,scrollLeft:document.body.scrollLeft};};};function _resize_overlay(){windowHeight=$(window).height(),windowWidth=$(window).width();if(typeof $pp_overlay!="undefined")$pp_overlay.height($(document).height()).width(windowWidth);};function _insert_gallery(){if(isSet&&settings.overlay_gallery&&_getFileType(pp_images[set_position])=="image"&&(settings.ie6_fallback&&!($.browser.msie&&parseInt($.browser.version)==6))){itemWidth=52+5;navWidth=(settings.theme=="facebook"||settings.theme=="pp_default")?50:30;itemsPerPage=Math.floor((pp_dimensions['containerWidth']-100-navWidth)/itemWidth);itemsPerPage=(itemsPerPage";};toInject=settings.gallery_markup.replace(/{gallery}/g,toInject);$pp_pic_holder.find('#pp_full_res').after(toInject);$pp_gallery=$('.pp_pic_holder .pp_gallery'),$pp_gallery_li=$pp_gallery.find('li');$pp_gallery.find('.pp_arrow_next').click(function(){$.prettyPhoto.changeGalleryPage('next');$.prettyPhoto.stopSlideshow();return false;});$pp_gallery.find('.pp_arrow_previous').click(function(){$.prettyPhoto.changeGalleryPage('previous');$.prettyPhoto.stopSlideshow();return false;});$pp_pic_holder.find('.pp_content').hover(function(){$pp_pic_holder.find('.pp_gallery:not(.disabled)').fadeIn();},function(){$pp_pic_holder.find('.pp_gallery:not(.disabled)').fadeOut();});itemWidth=52+5;$pp_gallery_li.each(function(i){$(this).find('a').click(function(){$.prettyPhoto.changePage(i);$.prettyPhoto.stopSlideshow();return false;});});};if(settings.slideshow){$pp_pic_holder.find('.pp_nav').prepend('Play') $pp_pic_holder.find('.pp_nav .pp_play').click(function(){$.prettyPhoto.startSlideshow();return false;});} $pp_pic_holder.attr('class','pp_pic_holder '+settings.theme);$pp_overlay.css({'opacity':0,'height':$(document).height(),'width':$(window).width()}).bind('click',function(){if(!settings.modal)$.prettyPhoto.close();});$('a.pp_close').bind('click',function(){$.prettyPhoto.close();return false;});$('a.pp_expand').bind('click',function(e){if($(this).hasClass('pp_expand')){$(this).removeClass('pp_expand').addClass('pp_contract');doresize=false;}else{$(this).removeClass('pp_contract').addClass('pp_expand');doresize=true;};_hideContent(function(){$.prettyPhoto.open();});return false;});$pp_pic_holder.find('.pp_previous, .pp_nav .pp_arrow_previous').bind('click',function(){$.prettyPhoto.changePage('previous');$.prettyPhoto.stopSlideshow();return false;});$pp_pic_holder.find('.pp_next, .pp_nav .pp_arrow_next').bind('click',function(){$.prettyPhoto.changePage('next');$.prettyPhoto.stopSlideshow();return false;});_center_overlay();};if(!pp_alreadyInitialized&&getHashtag()){pp_alreadyInitialized=true;hashIndex=getHashtag();hashRel=hashIndex;hashIndex=hashIndex.substring(hashIndex.indexOf('/')+1,hashIndex.length-1);hashRel=hashRel.substring(0,hashRel.indexOf('/'));setTimeout(function(){$("a[data-rel^='"+hashRel+"']:eq("+hashIndex+")").trigger('click');},50);} return this.unbind('click.prettyphoto').bind('click.prettyphoto',$.prettyPhoto.initialize);};function getHashtag(){return false;};function setHashtag(){return;};function clearHashtag(){return false;} function getParam(name,url){name=name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");var regexS="[\\?&]"+name+"=([^&#]*)";var regex=new RegExp(regexS);var results=regex.exec(url);return(results==null)?"":results[1];}})(jQuery);var pp_alreadyInitialized=false; /******************************************************************************************** jQuery Cycle Plugin ********************************************************************************************/ /*! * jQuery Cycle Plugin (with Transition Definitions) * Examples and documentation at: http://jquery.malsup.com/cycle/ * Copyright (c) 2007-2010 M. Alsup * Version: 2.9999.5 (10-APR-2012) * Dual licensed under the MIT and GPL licenses. * http://jquery.malsup.com/license.html * Requires: jQuery v1.3.2 or later */ (function(c,d){var b="2.9999.5";if(c.support===d){c.support={opacity:!(c.browser.msie)}}function g(t){if(c.fn.cycle.debug){f(t)}}function f(){if(window.console&&console.log){console.log("[cycle] "+Array.prototype.join.call(arguments," "))}}c.expr[":"].paused=function(s){return s.cyclePause};c.fn.cycle=function(t,s){var u={s:this.selector,c:this.context};if(this.length===0&&t!="stop"){if(!c.isReady&&u.s){f("DOM not ready, queuing slideshow");c(function(){c(u.s,u.c).cycle(t,s)});return this}f("terminating; zero elements found by selector"+(c.isReady?"":" (DOM not ready)"));return this}return this.each(function(){var y=l(this,t,s);if(y===false){return}y.updateActivePagerLink=y.updateActivePagerLink||c.fn.cycle.updateActivePagerLink;if(this.cycleTimeout){clearTimeout(this.cycleTimeout)}this.cycleTimeout=this.cyclePause=0;this.cycleStop=0;var z=c(this);var A=y.slideExpr?c(y.slideExpr,this):z.children();var w=A.get();if(w.length<1){f("terminating; too few slides: "+w.length);return}var v=q(z,A,w,y,u);if(v===false){return}var x=v.continuous?10:m(w[v.currSlide],w[v.nextSlide],v,!v.backwards);if(x){x+=(v.delay||0);if(x<10){x=10}g("first timeout: "+x);this.cycleTimeout=setTimeout(function(){n(w,v,0,!y.backwards)},x)}})};function k(s,v,u){var w=c(s).data("cycle.opts");var t=!!s.cyclePause;if(t&&w.paused){w.paused(s,w,v,u)}else{if(!t&&w.resumed){w.resumed(s,w,v,u)}}}function l(s,v,t){if(s.cycleStop===d){s.cycleStop=0}if(v===d||v===null){v={}}if(v.constructor==String){switch(v){case"destroy":case"stop":var x=c(s).data("cycle.opts");if(!x){return false}s.cycleStop++;if(s.cycleTimeout){clearTimeout(s.cycleTimeout)}s.cycleTimeout=0;if(x.elements){c(x.elements).stop()}c(s).removeData("cycle.opts");if(v=="destroy"){r(s,x)}return false;case"toggle":s.cyclePause=(s.cyclePause===1)?0:1;w(s.cyclePause,t,s);k(s);return false;case"pause":s.cyclePause=1;k(s);return false;case"resume":s.cyclePause=0;w(false,t,s);k(s);return false;case"prev":case"next":x=c(s).data("cycle.opts");if(!x){f('options not found, "prev/next" ignored');return false}c.fn.cycle[v](x);return false;default:v={fx:v}}return v}else{if(v.constructor==Number){var u=v;v=c(s).data("cycle.opts");if(!v){f("options not found, can not advance slide");return false}if(u<0||u>=v.elements.length){f("invalid slide index: "+u);return false}v.nextSlide=u;if(s.cycleTimeout){clearTimeout(s.cycleTimeout);s.cycleTimeout=0}if(typeof t=="string"){v.oneTimeFx=t}n(v.elements,v,1,u>=v.currSlide);return false}}return v;function w(z,A,y){if(!z&&A===true){var B=c(y).data("cycle.opts");if(!B){f("options not found, can not resume");return false}if(y.cycleTimeout){clearTimeout(y.cycleTimeout);y.cycleTimeout=0}n(B.elements,B,1,!B.backwards)}}}function e(s,t){if(!c.support.opacity&&t.cleartype&&s.style.filter){try{s.style.removeAttribute("filter")}catch(u){}}}function r(s,t){if(t.next){c(t.next).unbind(t.prevNextEvent)}if(t.prev){c(t.prev).unbind(t.prevNextEvent)}if(t.pager||t.pagerAnchorBuilder){c.each(t.pagerAnchors||[],function(){this.unbind().remove()})}t.pagerAnchors=null;c(s).unbind("mouseenter.cycle mouseleave.cycle");if(t.destroy){t.destroy(t)}}function q(C,Q,z,y,J){var s;var H=c.extend({},c.fn.cycle.defaults,y||{},c.metadata?C.metadata():c.meta?C.data():{});var F=c.isFunction(C.data)?C.data(H.metaAttr):null;if(F){H=c.extend(H,F)}if(H.autostop){H.countdown=H.autostopCount||z.length}var u=C[0];C.data("cycle.opts",H);H.$cont=C;H.stopCount=u.cycleStop;H.elements=z;H.before=H.before?[H.before]:[];H.after=H.after?[H.after]:[];if(!c.support.opacity&&H.cleartype){H.after.push(function(){e(this,H)})}if(H.continuous){H.after.push(function(){n(z,H,0,!H.backwards)})}i(H);if(!c.support.opacity&&H.cleartype&&!H.cleartypeNoBg){a(Q)}if(C.css("position")=="static"){C.css("position","relative")}if(H.width){C.width(H.width)}if(H.height&&H.height!="auto"){C.height(H.height)}if(H.startingSlide!==d){H.startingSlide=parseInt(H.startingSlide,10);if(H.startingSlide>=z.length||H.startSlide<0){H.startingSlide=0}else{s=true}}else{if(H.backwards){H.startingSlide=z.length-1}else{H.startingSlide=0}}if(H.random){H.randomMap=[];for(var O=0;O=z.length){H.startingSlide=0}}H.currSlide=H.startingSlide||0;var B=H.startingSlide;Q.css({position:"absolute",top:0,left:0}).hide().each(function(w){var S;if(H.backwards){S=B?w<=B?z.length+(w-B):B-w:z.length-w}else{S=B?w>=B?z.length-(w-B):B-w:z.length-w}c(this).css("z-index",S)});c(z[B]).css("opacity",1).show();e(z[B],H);if(H.fit){if(!H.aspect){if(H.width){Q.width(H.width)}if(H.height&&H.height!="auto"){Q.height(H.height)}}else{Q.each(function(){var S=c(this);var w=(H.aspect===true)?S.width()/S.height():H.aspect;if(H.width&&S.width()!=H.width){S.width(H.width);S.height(H.width/w)}if(H.height&&S.height()A?E:A;G=P>G?P:G}if(A>0&&G>0){C.css({width:A+"px",height:G+"px"})}}var x=false;if(H.pause){C.bind("mouseenter.cycle",function(){x=true;this.cyclePause++;k(u,true)}).bind("mouseleave.cycle",function(){if(x){this.cyclePause--}k(u,true)})}if(o(H)===false){return false}var v=false;y.requeueAttempts=y.requeueAttempts||0;Q.each(function(){var U=c(this);this.cycleH=(H.fit&&H.height)?H.height:(U.height()||this.offsetHeight||this.height||U.attr("height")||0);this.cycleW=(H.fit&&H.width)?H.width:(U.width()||this.offsetWidth||this.width||U.attr("width")||0);if(U.is("img")){var S=(c.browser.msie&&this.cycleW==28&&this.cycleH==30&&!this.complete);var V=(c.browser.mozilla&&this.cycleW==34&&this.cycleH==19&&!this.complete);var T=(c.browser.opera&&((this.cycleW==42&&this.cycleH==19)||(this.cycleW==37&&this.cycleH==17))&&!this.complete);var w=(this.cycleH===0&&this.cycleW===0&&!this.complete);if(S||V||T||w){if(J.s&&H.requeueOnImageNotLoaded&&++y.requeueAttempts<100){f(y.requeueAttempts," - img slide not loaded, requeuing slideshow: ",this.src,this.cycleW,this.cycleH);setTimeout(function(){c(J.s,J.c).cycle(y)},H.requeueTimeout);v=true;return false}else{f("could not determine size of image: "+this.src,this.cycleW,this.cycleH)}}}return true});if(v){return false}H.cssBefore=H.cssBefore||{};H.cssAfter=H.cssAfter||{};H.cssFirst=H.cssFirst||{};H.animIn=H.animIn||{};H.animOut=H.animOut||{};Q.not(":eq("+B+")").css(H.cssBefore);c(Q[B]).css(H.cssFirst);if(H.timeout){H.timeout=parseInt(H.timeout,10);if(H.speed.constructor==String){H.speed=c.fx.speeds[H.speed]||parseInt(H.speed,10)}if(!H.sync){H.speed=H.speed/2}var K=H.fx=="none"?0:H.fx=="shuffle"?500:250;while((H.timeout-H.speed)=(z.length-1)?0:H.startingSlide+1}}if(!H.multiFx){var N=c.fn.cycle.transitions[H.fx];if(c.isFunction(N)){N(C,Q,H)}else{if(H.fx!="custom"&&!H.multiFx){f("unknown transition: "+H.fx,"; slideshow terminating");return false}}}var D=Q[B];if(!H.skipInitializationCallbacks){if(H.before.length){H.before[0].apply(D,[D,D,H,true])}if(H.after.length){H.after[0].apply(D,[D,D,H,true])}}if(H.next){c(H.next).bind(H.prevNextEvent,function(){return h(H,1)})}if(H.prev){c(H.prev).bind(H.prevNextEvent,function(){return h(H,0)})}if(H.pager||H.pagerAnchorBuilder){p(z,H)}j(H,z);return H}function i(s){s.original={before:[],after:[]};s.original.cssBefore=c.extend({},s.cssBefore);s.original.cssAfter=c.extend({},s.cssAfter);s.original.animIn=c.extend({},s.animIn);s.original.animOut=c.extend({},s.animOut);c.each(s.before,function(){s.original.before.push(this)});c.each(s.after,function(){s.original.after.push(this)})}function o(y){var w,u,t=c.fn.cycle.transitions;if(y.fx.indexOf(",")>0){y.multiFx=true;y.fxs=y.fx.replace(/\s*/g,"").split(",");for(w=0;w=s.fxs.length)){s.lastFx=0}else{if(!A&&(s.lastFx===d||--s.lastFx<0)){s.lastFx=s.fxs.length-1}}w=s.fxs[s.lastFx]}if(s.oneTimeFx){w=s.oneTimeFx;s.oneTimeFx=null}c.fn.cycle.resetState(s,w);if(s.before.length){c.each(s.before,function(E,F){if(v.cycleStop!=s.stopCount){return}F.apply(B,[D,B,s,A])})}var t=function(){s.busy=0;c.each(s.after,function(E,F){if(v.cycleStop!=s.stopCount){return}F.apply(B,[D,B,s,A])});if(!v.cycleStop){C()}};g("tx firing("+w+"); currSlide: "+s.currSlide+"; nextSlide: "+s.nextSlide);s.busy=1;if(s.fxFn){s.fxFn(D,B,s,t,A,x&&s.fastOnEvent)}else{if(c.isFunction(c.fn.cycle[s.fx])){c.fn.cycle[s.fx](D,B,s,t,A,x&&s.fastOnEvent)}else{c.fn.cycle.custom(D,B,s,t,A,x&&s.fastOnEvent)}}}else{C()}if(z||s.nextSlide==s.currSlide){var u;s.lastSlide=s.currSlide;if(s.random){s.currSlide=s.nextSlide;if(++s.randomIndex==y.length){s.randomIndex=0;s.randomMap.sort(function(F,E){return Math.random()-0.5})}s.nextSlide=s.randomMap[s.randomIndex];if(s.nextSlide==s.currSlide){s.nextSlide=(s.currSlide==s.slideCount-1)?0:s.currSlide+1}}else{if(s.backwards){u=(s.nextSlide-1)<0;if(u&&s.bounce){s.backwards=!s.backwards;s.nextSlide=1;s.currSlide=0}else{s.nextSlide=u?(y.length-1):s.nextSlide-1;s.currSlide=u?0:s.nextSlide+1}}else{u=(s.nextSlide+1)==y.length;if(u&&s.bounce){s.backwards=!s.backwards;s.nextSlide=y.length-2;s.currSlide=y.length-1}else{s.nextSlide=u?0:s.nextSlide+1;s.currSlide=u?y.length-1:s.nextSlide-1}}}}if(z&&s.pager){s.updateActivePagerLink(s.pager,s.currSlide,s.activePagerClass)}function C(){var E=0,F=s.timeout;if(s.timeout&&!s.continuous){E=m(y[s.currSlide],y[s.nextSlide],s,A);if(s.fx=="shuffle"){E-=s.speedOut}}else{if(s.continuous&&v.cyclePause){E=10}}if(E>0){v.cycleTimeout=setTimeout(function(){n(y,s,0,!s.backwards)},E)}}}c.fn.cycle.updateActivePagerLink=function(s,u,t){c(s).each(function(){c(this).children().removeClass(t).eq(u).addClass(t)})};function m(x,v,w,u){if(w.timeoutFn){var s=w.timeoutFn.call(x,x,v,w,u);while(w.fx!="none"&&(s-w.speed)<250){s+=w.speed}g("calculated timeout: "+s+"; speed: "+w.speed);if(s!==false){return s}}return w.timeout}c.fn.cycle.next=function(s){h(s,1)};c.fn.cycle.prev=function(s){h(s,0)};function h(v,u){var y=u?1:-1;var t=v.elements;var x=v.$cont[0],w=x.cycleTimeout;if(w){clearTimeout(w);x.cycleTimeout=0}if(v.random&&y<0){v.randomIndex--;if(--v.randomIndex==-2){v.randomIndex=t.length-2}else{if(v.randomIndex==-1){v.randomIndex=t.length-1}}v.nextSlide=v.randomMap[v.randomIndex]}else{if(v.random){v.nextSlide=v.randomMap[v.randomIndex]}else{v.nextSlide=v.currSlide+y;if(v.nextSlide<0){if(v.nowrap){return false}v.nextSlide=t.length-1}else{if(v.nextSlide>=t.length){if(v.nowrap){return false}v.nextSlide=0}}}}var s=v.onPrevNextEvent||v.prevNextClick;if(c.isFunction(s)){s(y>0,v.nextSlide,t[v.nextSlide])}n(t,v,1,u);return false}function p(t,u){var s=c(u.pager);c.each(t,function(v,w){c.fn.cycle.createPagerAnchor(v,w,s,t,u)});u.updateActivePagerLink(u.pager,u.startingSlide,u.activePagerClass)}c.fn.cycle.createPagerAnchor=function(x,u,z,w,t){var A;if(c.isFunction(t.pagerAnchorBuilder)){A=t.pagerAnchorBuilder(x,u);g("pagerAnchorBuilder("+x+", el) returned: "+A)}else{A=''+(x+1)+""}if(!A){return}var v=c(A);if(v.parents("body").length===0){var y=[];if(z.length>1){z.each(function(){var D=v.clone(true);c(this).append(D);y.push(D[0])});v=c(y)}else{v.appendTo(z)}}t.pagerAnchors=t.pagerAnchors||[];t.pagerAnchors.push(v);var B=function(G){G.preventDefault();t.nextSlide=x;var F=t.$cont[0],E=F.cycleTimeout;if(E){clearTimeout(E);F.cycleTimeout=0}var D=t.onPagerEvent||t.pagerClick;if(c.isFunction(D)){D(t.nextSlide,w[t.nextSlide])}n(w,t,1,t.currSlides?w-s:v.slideCount-s}else{t=w=0){var x=w.match(/\d+/g);return"#"+t(x[0])+t(x[1])+t(x[2])}if(w&&w!="transparent"){return w}}return"#ffffff"}u.each(function(){c(this).css("background-color",s(this))})}c.fn.cycle.commonReset=function(y,v,x,t,u,s){c(x.elements).not(y).hide();if(typeof x.cssBefore.opacity=="undefined"){x.cssBefore.opacity=1}x.cssBefore.display="block";if(x.slideResize&&t!==false&&v.cycleW>0){x.cssBefore.width=v.cycleW}if(x.slideResize&&u!==false&&v.cycleH>0){x.cssBefore.height=v.cycleH}x.cssAfter=x.cssAfter||{};x.cssAfter.display="none";c(y).css("zIndex",x.slideCount+(s===true?1:0));c(v).css("zIndex",x.slideCount+(s===true?0:1))};c.fn.cycle.custom=function(E,y,s,v,x,t){var D=c(E),z=c(y);var u=s.speedIn,C=s.speedOut,w=s.easeIn,B=s.easeOut;z.css(s.cssBefore);if(t){if(typeof t=="number"){u=C=t}else{u=C=1}w=B=null}var A=function(){z.animate(s.animIn,u,w,function(){v()})};D.animate(s.animOut,C,B,function(){D.css(s.cssAfter);if(!s.sync){A()}});if(s.sync){A()}};c.fn.cycle.transitions={fade:function(t,u,s){u.not(":eq("+s.currSlide+")").css("opacity",0);s.before.push(function(x,v,w){c.fn.cycle.commonReset(x,v,w);w.cssBefore.opacity=0});s.animIn={opacity:1};s.animOut={opacity:0};s.cssBefore={top:0,left:0}}};c.fn.cycle.ver=function(){return b};c.fn.cycle.defaults={activePagerClass:"activeSlide",after:null,allowPagerClickBubble:false,animIn:null,animOut:null,aspect:false,autostop:0,autostopCount:0,backwards:false,before:null,center:null,cleartype:!c.support.opacity,cleartypeNoBg:false,containerResize:1,continuous:0,cssAfter:null,cssBefore:null,delay:0,easeIn:null,easeOut:null,easing:null,end:null,fastOnEvent:0,fit:0,fx:"fade",fxFn:null,height:"auto",manualTrump:true,metaAttr:"cycle",next:null,nowrap:0,onPagerEvent:null,onPrevNextEvent:null,pager:null,pagerAnchorBuilder:null,pagerEvent:"click.cycle",pause:0,pauseOnPagerHover:0,prev:null,prevNextEvent:"click.cycle",random:0,randomizeEffects:1,requeueOnImageNotLoaded:true,requeueTimeout:250,rev:0,shuffle:null,skipInitializationCallbacks:false,slideExpr:null,slideResize:1,speed:1000,speedIn:null,speedOut:null,startingSlide:d,sync:1,timeout:4000,timeoutFn:null,updateActivePagerLink:null,width:null}})(jQuery); /*! * jQuery Cycle Plugin Transition Definitions * This script is a plugin for the jQuery Cycle Plugin * Examples and documentation at: http://malsup.com/jquery/cycle/ * Copyright (c) 2007-2010 M. Alsup * Version: 2.73 * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html */ (function(a){a.fn.cycle.transitions.none=function(c,d,b){b.fxFn=function(g,e,f,h){a(e).show();a(g).hide();h()}};a.fn.cycle.transitions.fadeout=function(c,d,b){d.not(":eq("+b.currSlide+")").css({display:"block",opacity:1});b.before.push(function(k,i,j,f,g,e){a(k).css("zIndex",j.slideCount+(e!==true?1:0));a(i).css("zIndex",j.slideCount+(e!==true?0:1))});b.animIn.opacity=1;b.animOut.opacity=0;b.cssBefore.opacity=1;b.cssBefore.display="block";b.cssAfter.zIndex=0};a.fn.cycle.transitions.scrollUp=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssBefore.top=b;c.cssBefore.left=0;c.cssFirst.top=0;c.animIn.top=0;c.animOut.top=-b};a.fn.cycle.transitions.scrollDown=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssFirst.top=0;c.cssBefore.top=-b;c.cssBefore.left=0;c.animIn.top=0;c.animOut.top=b};a.fn.cycle.transitions.scrollLeft=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=0-b};a.fn.cycle.transitions.scrollRight=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=-b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=b};a.fn.cycle.transitions.scrollHorz=function(c,d,b){c.css("overflow","hidden").width();b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.left=e?(f.cycleW-1):(1-f.cycleW);g.animOut.left=e?-h.cycleW:h.cycleW});b.cssFirst.left=0;b.cssBefore.top=0;b.animIn.left=0;b.animOut.top=0};a.fn.cycle.transitions.scrollVert=function(c,d,b){c.css("overflow","hidden");b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.top=e?(1-f.cycleH):(f.cycleH-1);g.animOut.top=e?h.cycleH:-h.cycleH});b.cssFirst.top=0;b.cssBefore.left=0;b.animIn.top=0;b.animOut.left=0};a.fn.cycle.transitions.slideX=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,false,true);f.animIn.width=e.cycleW});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.width=0;b.animIn.width="show";b.animOut.width=0};a.fn.cycle.transitions.slideY=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,true,false);f.animIn.height=e.cycleH});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.height=0;b.animIn.height="show";b.animOut.height=0};a.fn.cycle.transitions.shuffle=function(e,f,d){var c,b=e.css("overflow","visible").width();f.css({left:0,top:0});d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h,true,true,true)});if(!d.speedAdjusted){d.speed=d.speed/2;d.speedAdjusted=true}d.random=0;d.shuffle=d.shuffle||{left:-b,top:15};d.els=[];for(c=0;c=config.min_move_x){cancelTouch();if(dx>0){config.wipeLeft()}else{config.wipeRight()}}else if(Math.abs(dy)>=config.min_move_y){cancelTouch();if(dy>0){config.wipeDown()}else{config.wipeUp()}}}}function onTouchStart(e){if(e.touches.length==1){startX=e.touches[0].pageX;startY=e.touches[0].pageY;isMoving=true;this.addEventListener('touchmove',onTouchMove,false)}}if('ontouchstart'in document.documentElement){this.addEventListener('touchstart',onTouchStart,false)}});return this}})(jQuery); /******************************************************************************************** Quicksand (portfolio dynamic filtering) ********************************************************************************************/ (function(a){a.fn.quicksand=function(f,b){var e={duration:750,easing:"swing",attribute:"data-id",adjustHeight:"auto",useScaling:true,enhancement:function(g){},selector:"> *",dx:0,dy:0};a.extend(e,b);if(a.browser.msie||(typeof(a.fn.scale)=="undefined")){e.useScaling=false}var c;if(typeof(arguments[1])=="function"){var c=arguments[1]}else{if(typeof(arguments[2]=="function")){var c=arguments[2]}}return this.each(function(u){var z;var x=[];var j=a(f).clone();var y=a(this);var h=a(this).css("height");var o;var k=false;var l=a(y).offset();var m=[];var w=a(this).find(e.selector);if(a.browser.msie&&a.browser.version.substr(0,1)<7){y.html("").append(j);return}var n=0;var r=function(){if(!n){n=1;$toDelete=y.find("> *");y.prepend(s.find("> *"));$toDelete.remove();if(k){y.css("height",o)}e.enhancement(y);if(typeof c=="function"){c.call(this)}}};var v=y.offsetParent();var t=v.offset();if(v.css("position")=="relative"){if(v.get(0).nodeName.toLowerCase()=="body"){}else{t.top+=(parseFloat(v.css("border-top-width"))||0);t.left+=(parseFloat(v.css("border-left-width"))||0)}}else{t.top-=(parseFloat(v.css("border-top-width"))||0);t.left-=(parseFloat(v.css("border-left-width"))||0);t.top-=(parseFloat(v.css("margin-top"))||0);t.left-=(parseFloat(v.css("margin-left"))||0)}if(isNaN(t.left)){t.left=0}if(isNaN(t.top)){t.top=0}t.left-=e.dx;t.top-=e.dy;y.css("height",a(this).height());w.each(function(A){m[A]=a(this).offset()});a(this).stop();var q=0;var p=0;w.each(function(A){a(this).stop();var B=a(this).get(0);if(B.style.position=="absolute"){q=-e.dx;p=-e.dy}else{q=e.dx;p=e.dy}B.style.position="absolute";B.style.margin="0";B.style.top=(m[A].top-parseFloat(B.style.marginTop)-t.top+p)+"px";B.style.left=(m[A].left-parseFloat(B.style.marginLeft)-t.left+q)+"px"});var s=a(y).clone();var g=s.get(0);g.innerHTML="";g.setAttribute("id","");g.style.height="auto";g.style.width=y.width()+"px";s.append(j);s.insertBefore(y);s.css("opacity",0);g.style.zIndex=-1;g.style.margin="0";g.style.position="absolute";g.style.top=l.top-t.top+"px";g.style.left=l.left-t.left+"px";if(e.adjustHeight==="dynamic"){y.animate({height:s.height()},e.duration,e.easing)}else{if(e.adjustHeight==="auto"){o=s.height();if(parseFloat(h)x

';head.appendChild(div.childNodes[1])}if(options){$.extend(settings,options)}return this.each(function(){var selectors=["iframe[src*='player.vimeo.com']","iframe[src*='youtube.com']","iframe[src*='youtube-nocookie.com']","iframe[src*='kickstarter.com'][src*='video.html']","object","embed"];if(settings.customSelector){selectors.push(settings.customSelector)}var $allVideos=$(this).find(selectors.join(','));$allVideos=$allVideos.not("object object");$allVideos.each(function(){var $this=$(this);if(this.tagName.toLowerCase()==='embed'&&$this.parent('object').length||$this.parent('.fluid-width-video-wrapper').length){return}var height=(this.tagName.toLowerCase()==='object'||($this.attr('height')&&!isNaN(parseInt($this.attr('height'),10))))?parseInt($this.attr('height'),10):$this.height(),width=!isNaN(parseInt($this.attr('width'),10))?parseInt($this.attr('width'),10):$this.width(),aspectRatio=height/width;if(!$this.attr('id')){var videoID='fitvid'+Math.floor(Math.random()*999999);$this.attr('id',videoID)}$this.wrap('
').parent('.fluid-width-video-wrapper').css('padding-top',(aspectRatio*100)+"%");$this.removeAttr('height').removeAttr('width')})})}})(window.jQuery||window.Zepto); /******************************************************************************************** jQuery Masonry v2.0.111015 ********************************************************************************************/ (function(a,b,c){var d=b.event,e;d.special.smartresize={setup:function(){b(this).bind("resize",d.special.smartresize.handler)},teardown:function(){b(this).unbind("resize",d.special.smartresize.handler)},handler:function(a,b){var c=this,d=arguments;a.type="smartresize",e&&clearTimeout(e),e=setTimeout(function(){jQuery.event.handle.apply(c,d)},b==="execAsap"?0:100)}},b.fn.smartresize=function(a){return a?this.bind("smartresize",a):this.trigger("smartresize",["execAsap"])},b.Mason=function(a,c){this.element=b(c),this._create(a),this._init()};var f=["position","height"];b.Mason.settings={isResizable:!0,isAnimated:!1,animationOptions:{queue:!1,duration:500},gutterWidth:0,isRTL:!1,isFitWidth:!1},b.Mason.prototype={_filterFindBricks:function(a){var b=this.options.itemSelector;return b?a.filter(b).add(a.find(b)):a},_getBricks:function(a){var b=this._filterFindBricks(a).css({position:"absolute"}).addClass("masonry-brick");return b},_create:function(c){this.options=b.extend(!0,{},b.Mason.settings,c),this.styleQueue=[],this.reloadItems();var d=this.element[0].style;this.originalStyle={};for(var e=0,g=f.length;e0){if(opts.markers[0].address){$geocoder.geocode({address:opts.markers[0].address},function(result,status){if(status==google.maps.GeocoderStatus.OK){$gmap.setCenter(result[0].geometry.location);}else{if(opts.log)console.log("Geocode was not successful for the following reason: "+status);}});} else{$gmap.setCenter(new googlemaps.LatLng(opts.markers[0].latitude,opts.markers[0].longitude));$gmap.setZoom(opts.zoom);}} else{$gmap.setCenter(new googlemaps.LatLng(opts.latitude,opts.longitude));$gmap.setZoom(opts.zoom);}}} if(opts.controls.length!=0){for(var i=0;i',html_append:'',icon:{image:"http://www.google.com/mapfiles/marker.png",shadow:"http://www.google.com/mapfiles/shadow50.png",iconsize:[20,34],shadowsize:[37,34],iconanchor:[9,34],infowindowanchor:[9,2]}}})(jQuery); } window.onload = unisphere_gmap; /******************************************************************************************** jQuery.browser ********************************************************************************************/ (function(){var e,t;jQuery.uaMatch=function(e){e=e.toLowerCase();var t=/(chrome)[ \/]([\w.]+)/.exec(e)||/(webkit)[ \/]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e)||[];return{browser:t[1]||"",version:t[2]||"0"}};e=jQuery.uaMatch(navigator.userAgent);t={};if(e.browser){t[e.browser]=true;t.version=e.version}if(t.chrome){t.webkit=true}else if(t.webkit){t.safari=true}jQuery.browser=t;jQuery.sub=function(){function e(t,n){return new e.fn.init(t,n)}jQuery.extend(true,e,this);e.superclass=this;e.fn=e.prototype=this();e.fn.constructor=e;e.sub=this.sub;e.fn.init=function(r,i){if(i&&i instanceof jQuery&&!(i instanceof e)){i=e(i)}return jQuery.fn.init.call(this,r,i,t)};e.fn.init.prototype=e.fn;var t=e(document);return e}})()