Index: extensions/Slim/js/jquery-ui.custom.min.js
===================================================================
--- extensions/Slim/js/jquery-ui.custom.min.js	(revision 28556)
+++ extensions/Slim/js/jquery-ui.custom.min.js	(revision 28556)
@@ -0,0 +1,6 @@
+/*! jQuery UI - v1.10.3 - 2013-10-28
+* http://jqueryui.com
+* Includes: jquery.ui.widget.js, jquery.ui.effect.js
+* Copyright 2013 jQuery Foundation and other contributors; Licensed MIT */
+
+(function(e,t){var i=0,s=Array.prototype.slice,a=e.cleanData;e.cleanData=function(t){for(var i,s=0;null!=(i=t[s]);s++)try{e(i).triggerHandler("remove")}catch(n){}a(t)},e.widget=function(i,s,a){var n,r,o,h,l={},u=i.split(".")[0];i=i.split(".")[1],n=u+"-"+i,a||(a=s,s=e.Widget),e.expr[":"][n.toLowerCase()]=function(t){return!!e.data(t,n)},e[u]=e[u]||{},r=e[u][i],o=e[u][i]=function(e,i){return this._createWidget?(arguments.length&&this._createWidget(e,i),t):new o(e,i)},e.extend(o,r,{version:a.version,_proto:e.extend({},a),_childConstructors:[]}),h=new s,h.options=e.widget.extend({},h.options),e.each(a,function(i,a){return e.isFunction(a)?(l[i]=function(){var e=function(){return s.prototype[i].apply(this,arguments)},t=function(e){return s.prototype[i].apply(this,e)};return function(){var i,s=this._super,n=this._superApply;return this._super=e,this._superApply=t,i=a.apply(this,arguments),this._super=s,this._superApply=n,i}}(),t):(l[i]=a,t)}),o.prototype=e.widget.extend(h,{widgetEventPrefix:r?h.widgetEventPrefix:i},l,{constructor:o,namespace:u,widgetName:i,widgetFullName:n}),r?(e.each(r._childConstructors,function(t,i){var s=i.prototype;e.widget(s.namespace+"."+s.widgetName,o,i._proto)}),delete r._childConstructors):s._childConstructors.push(o),e.widget.bridge(i,o)},e.widget.extend=function(i){for(var a,n,r=s.call(arguments,1),o=0,h=r.length;h>o;o++)for(a in r[o])n=r[o][a],r[o].hasOwnProperty(a)&&n!==t&&(i[a]=e.isPlainObject(n)?e.isPlainObject(i[a])?e.widget.extend({},i[a],n):e.widget.extend({},n):n);return i},e.widget.bridge=function(i,a){var n=a.prototype.widgetFullName||i;e.fn[i]=function(r){var o="string"==typeof r,h=s.call(arguments,1),l=this;return r=!o&&h.length?e.widget.extend.apply(null,[r].concat(h)):r,o?this.each(function(){var s,a=e.data(this,n);return a?e.isFunction(a[r])&&"_"!==r.charAt(0)?(s=a[r].apply(a,h),s!==a&&s!==t?(l=s&&s.jquery?l.pushStack(s.get()):s,!1):t):e.error("no such method '"+r+"' for "+i+" widget instance"):e.error("cannot call methods on "+i+" prior to initialization; "+"attempted to call method '"+r+"'")}):this.each(function(){var t=e.data(this,n);t?t.option(r||{})._init():e.data(this,n,new a(r,this))}),l}},e.Widget=function(){},e.Widget._childConstructors=[],e.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{disabled:!1,create:null},_createWidget:function(t,s){s=e(s||this.defaultElement||this)[0],this.element=e(s),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.options=e.widget.extend({},this.options,this._getCreateOptions(),t),this.bindings=e(),this.hoverable=e(),this.focusable=e(),s!==this&&(e.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(e){e.target===s&&this.destroy()}}),this.document=e(s.style?s.ownerDocument:s.document||s),this.window=e(this.document[0].defaultView||this.document[0].parentWindow)),this._create(),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:e.noop,_getCreateEventData:e.noop,_create:e.noop,_init:e.noop,destroy:function(){this._destroy(),this.element.unbind(this.eventNamespace).removeData(this.widgetName).removeData(this.widgetFullName).removeData(e.camelCase(this.widgetFullName)),this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName+"-disabled "+"ui-state-disabled"),this.bindings.unbind(this.eventNamespace),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")},_destroy:e.noop,widget:function(){return this.element},option:function(i,s){var a,n,r,o=i;if(0===arguments.length)return e.widget.extend({},this.options);if("string"==typeof i)if(o={},a=i.split("."),i=a.shift(),a.length){for(n=o[i]=e.widget.extend({},this.options[i]),r=0;a.length-1>r;r++)n[a[r]]=n[a[r]]||{},n=n[a[r]];if(i=a.pop(),s===t)return n[i]===t?null:n[i];n[i]=s}else{if(s===t)return this.options[i]===t?null:this.options[i];o[i]=s}return this._setOptions(o),this},_setOptions:function(e){var t;for(t in e)this._setOption(t,e[t]);return this},_setOption:function(e,t){return this.options[e]=t,"disabled"===e&&(this.widget().toggleClass(this.widgetFullName+"-disabled ui-state-disabled",!!t).attr("aria-disabled",t),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")),this},enable:function(){return this._setOption("disabled",!1)},disable:function(){return this._setOption("disabled",!0)},_on:function(i,s,a){var n,r=this;"boolean"!=typeof i&&(a=s,s=i,i=!1),a?(s=n=e(s),this.bindings=this.bindings.add(s)):(a=s,s=this.element,n=this.widget()),e.each(a,function(a,o){function h(){return i||r.options.disabled!==!0&&!e(this).hasClass("ui-state-disabled")?("string"==typeof o?r[o]:o).apply(r,arguments):t}"string"!=typeof o&&(h.guid=o.guid=o.guid||h.guid||e.guid++);var l=a.match(/^(\w+)\s*(.*)$/),u=l[1]+r.eventNamespace,c=l[2];c?n.delegate(c,u,h):s.bind(u,h)})},_off:function(e,t){t=(t||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.unbind(t).undelegate(t)},_delay:function(e,t){function i(){return("string"==typeof e?s[e]:e).apply(s,arguments)}var s=this;return setTimeout(i,t||0)},_hoverable:function(t){this.hoverable=this.hoverable.add(t),this._on(t,{mouseenter:function(t){e(t.currentTarget).addClass("ui-state-hover")},mouseleave:function(t){e(t.currentTarget).removeClass("ui-state-hover")}})},_focusable:function(t){this.focusable=this.focusable.add(t),this._on(t,{focusin:function(t){e(t.currentTarget).addClass("ui-state-focus")},focusout:function(t){e(t.currentTarget).removeClass("ui-state-focus")}})},_trigger:function(t,i,s){var a,n,r=this.options[t];if(s=s||{},i=e.Event(i),i.type=(t===this.widgetEventPrefix?t:this.widgetEventPrefix+t).toLowerCase(),i.target=this.element[0],n=i.originalEvent)for(a in n)a in i||(i[a]=n[a]);return this.element.trigger(i,s),!(e.isFunction(r)&&r.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},e.each({show:"fadeIn",hide:"fadeOut"},function(t,i){e.Widget.prototype["_"+t]=function(s,a,n){"string"==typeof a&&(a={effect:a});var r,o=a?a===!0||"number"==typeof a?i:a.effect||i:t;a=a||{},"number"==typeof a&&(a={duration:a}),r=!e.isEmptyObject(a),a.complete=n,a.delay&&s.delay(a.delay),r&&e.effects&&e.effects.effect[o]?s[t](a):o!==t&&s[o]?s[o](a.duration,a.easing,n):s.queue(function(i){e(this)[t](),n&&n.call(s[0]),i()})}})})(jQuery);(function(e,t){var i="ui-effects-";e.effects={effect:{}},function(e,t){function i(e,t,i){var s=c[t.type]||{};return null==e?i||!t.def?null:t.def:(e=s.floor?~~e:parseFloat(e),isNaN(e)?t.def:s.mod?(e+s.mod)%s.mod:0>e?0:e>s.max?s.max:e)}function s(i){var s=l(),a=s._rgba=[];return i=i.toLowerCase(),f(h,function(e,n){var r,o=n.re.exec(i),h=o&&n.parse(o),l=n.space||"rgba";return h?(r=s[l](h),s[u[l].cache]=r[u[l].cache],a=s._rgba=r._rgba,!1):t}),a.length?("0,0,0,0"===a.join()&&e.extend(a,n.transparent),s):n[i]}function a(e,t,i){return i=(i+1)%1,1>6*i?e+6*(t-e)*i:1>2*i?t:2>3*i?e+6*(t-e)*(2/3-i):e}var n,r="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",o=/^([\-+])=\s*(\d+\.?\d*)/,h=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(e){return[e[1],e[2],e[3],e[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(e){return[2.55*e[1],2.55*e[2],2.55*e[3],e[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(e){return[parseInt(e[1],16),parseInt(e[2],16),parseInt(e[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(e){return[parseInt(e[1]+e[1],16),parseInt(e[2]+e[2],16),parseInt(e[3]+e[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(e){return[e[1],e[2]/100,e[3]/100,e[4]]}}],l=e.Color=function(t,i,s,a){return new e.Color.fn.parse(t,i,s,a)},u={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},c={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=e("<p>")[0],f=e.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(u,function(e,t){t.cache="_"+e,t.props.alpha={idx:3,type:"percent",def:1}}),l.fn=e.extend(l.prototype,{parse:function(a,r,o,h){if(a===t)return this._rgba=[null,null,null,null],this;(a.jquery||a.nodeType)&&(a=e(a).css(r),r=t);var c=this,d=e.type(a),p=this._rgba=[];return r!==t&&(a=[a,r,o,h],d="array"),"string"===d?this.parse(s(a)||n._default):"array"===d?(f(u.rgba.props,function(e,t){p[t.idx]=i(a[t.idx],t)}),this):"object"===d?(a instanceof l?f(u,function(e,t){a[t.cache]&&(c[t.cache]=a[t.cache].slice())}):f(u,function(t,s){var n=s.cache;f(s.props,function(e,t){if(!c[n]&&s.to){if("alpha"===e||null==a[e])return;c[n]=s.to(c._rgba)}c[n][t.idx]=i(a[e],t,!0)}),c[n]&&0>e.inArray(null,c[n].slice(0,3))&&(c[n][3]=1,s.from&&(c._rgba=s.from(c[n])))}),this):t},is:function(e){var i=l(e),s=!0,a=this;return f(u,function(e,n){var r,o=i[n.cache];return o&&(r=a[n.cache]||n.to&&n.to(a._rgba)||[],f(n.props,function(e,i){return null!=o[i.idx]?s=o[i.idx]===r[i.idx]:t})),s}),s},_space:function(){var e=[],t=this;return f(u,function(i,s){t[s.cache]&&e.push(i)}),e.pop()},transition:function(e,t){var s=l(e),a=s._space(),n=u[a],r=0===this.alpha()?l("transparent"):this,o=r[n.cache]||n.to(r._rgba),h=o.slice();return s=s[n.cache],f(n.props,function(e,a){var n=a.idx,r=o[n],l=s[n],u=c[a.type]||{};null!==l&&(null===r?h[n]=l:(u.mod&&(l-r>u.mod/2?r+=u.mod:r-l>u.mod/2&&(r-=u.mod)),h[n]=i((l-r)*t+r,a)))}),this[a](h)},blend:function(t){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),a=l(t)._rgba;return l(e.map(i,function(e,t){return(1-s)*a[t]+s*e}))},toRgbaString:function(){var t="rgba(",i=e.map(this._rgba,function(e,t){return null==e?t>2?1:0:e});return 1===i[3]&&(i.pop(),t="rgb("),t+i.join()+")"},toHslaString:function(){var t="hsla(",i=e.map(this.hsla(),function(e,t){return null==e&&(e=t>2?1:0),t&&3>t&&(e=Math.round(100*e)+"%"),e});return 1===i[3]&&(i.pop(),t="hsl("),t+i.join()+")"},toHexString:function(t){var i=this._rgba.slice(),s=i.pop();return t&&i.push(~~(255*s)),"#"+e.map(i,function(e){return e=(e||0).toString(16),1===e.length?"0"+e:e}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,u.hsla.to=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t,i,s=e[0]/255,a=e[1]/255,n=e[2]/255,r=e[3],o=Math.max(s,a,n),h=Math.min(s,a,n),l=o-h,u=o+h,c=.5*u;return t=h===o?0:s===o?60*(a-n)/l+360:a===o?60*(n-s)/l+120:60*(s-a)/l+240,i=0===l?0:.5>=c?l/u:l/(2-u),[Math.round(t)%360,i,c,null==r?1:r]},u.hsla.from=function(e){if(null==e[0]||null==e[1]||null==e[2])return[null,null,null,e[3]];var t=e[0]/360,i=e[1],s=e[2],n=e[3],r=.5>=s?s*(1+i):s+i-s*i,o=2*s-r;return[Math.round(255*a(o,r,t+1/3)),Math.round(255*a(o,r,t)),Math.round(255*a(o,r,t-1/3)),n]},f(u,function(s,a){var n=a.props,r=a.cache,h=a.to,u=a.from;l.fn[s]=function(s){if(h&&!this[r]&&(this[r]=h(this._rgba)),s===t)return this[r].slice();var a,o=e.type(s),c="array"===o||"object"===o?s:arguments,d=this[r].slice();return f(n,function(e,t){var s=c["object"===o?e:t.idx];null==s&&(s=d[t.idx]),d[t.idx]=i(s,t)}),u?(a=l(u(d)),a[r]=d,a):l(d)},f(n,function(t,i){l.fn[t]||(l.fn[t]=function(a){var n,r=e.type(a),h="alpha"===t?this._hsla?"hsla":"rgba":s,l=this[h](),u=l[i.idx];return"undefined"===r?u:("function"===r&&(a=a.call(this,u),r=e.type(a)),null==a&&i.empty?this:("string"===r&&(n=o.exec(a),n&&(a=u+parseFloat(n[2])*("+"===n[1]?1:-1))),l[i.idx]=a,this[h](l)))})})}),l.hook=function(t){var i=t.split(" ");f(i,function(t,i){e.cssHooks[i]={set:function(t,a){var n,r,o="";if("transparent"!==a&&("string"!==e.type(a)||(n=s(a)))){if(a=l(n||a),!d.rgba&&1!==a._rgba[3]){for(r="backgroundColor"===i?t.parentNode:t;(""===o||"transparent"===o)&&r&&r.style;)try{o=e.css(r,"backgroundColor"),r=r.parentNode}catch(h){}a=a.blend(o&&"transparent"!==o?o:"_default")}a=a.toRgbaString()}try{t.style[i]=a}catch(h){}}},e.fx.step[i]=function(t){t.colorInit||(t.start=l(t.elem,i),t.end=l(t.end),t.colorInit=!0),e.cssHooks[i].set(t.elem,t.start.transition(t.end,t.pos))}})},l.hook(r),e.cssHooks.borderColor={expand:function(e){var t={};return f(["Top","Right","Bottom","Left"],function(i,s){t["border"+s+"Color"]=e}),t}},n=e.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(jQuery),function(){function i(t){var i,s,a=t.ownerDocument.defaultView?t.ownerDocument.defaultView.getComputedStyle(t,null):t.currentStyle,n={};if(a&&a.length&&a[0]&&a[a[0]])for(s=a.length;s--;)i=a[s],"string"==typeof a[i]&&(n[e.camelCase(i)]=a[i]);else for(i in a)"string"==typeof a[i]&&(n[i]=a[i]);return n}function s(t,i){var s,a,r={};for(s in i)a=i[s],t[s]!==a&&(n[s]||(e.fx.step[s]||!isNaN(parseFloat(a)))&&(r[s]=a));return r}var a=["add","remove","toggle"],n={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};e.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(t,i){e.fx.step[i]=function(e){("none"!==e.end&&!e.setAttr||1===e.pos&&!e.setAttr)&&(jQuery.style(e.elem,i,e.end),e.setAttr=!0)}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),e.effects.animateClass=function(t,n,r,o){var h=e.speed(n,r,o);return this.queue(function(){var n,r=e(this),o=r.attr("class")||"",l=h.children?r.find("*").addBack():r;l=l.map(function(){var t=e(this);return{el:t,start:i(this)}}),n=function(){e.each(a,function(e,i){t[i]&&r[i+"Class"](t[i])})},n(),l=l.map(function(){return this.end=i(this.el[0]),this.diff=s(this.start,this.end),this}),r.attr("class",o),l=l.map(function(){var t=this,i=e.Deferred(),s=e.extend({},h,{queue:!1,complete:function(){i.resolve(t)}});return this.el.animate(this.diff,s),i.promise()}),e.when.apply(e,l.get()).done(function(){n(),e.each(arguments,function(){var t=this.el;e.each(this.diff,function(e){t.css(e,"")})}),h.complete.call(r[0])})})},e.fn.extend({addClass:function(t){return function(i,s,a,n){return s?e.effects.animateClass.call(this,{add:i},s,a,n):t.apply(this,arguments)}}(e.fn.addClass),removeClass:function(t){return function(i,s,a,n){return arguments.length>1?e.effects.animateClass.call(this,{remove:i},s,a,n):t.apply(this,arguments)}}(e.fn.removeClass),toggleClass:function(i){return function(s,a,n,r,o){return"boolean"==typeof a||a===t?n?e.effects.animateClass.call(this,a?{add:s}:{remove:s},n,r,o):i.apply(this,arguments):e.effects.animateClass.call(this,{toggle:s},a,n,r)}}(e.fn.toggleClass),switchClass:function(t,i,s,a,n){return e.effects.animateClass.call(this,{add:i,remove:t},s,a,n)}})}(),function(){function s(t,i,s,a){return e.isPlainObject(t)&&(i=t,t=t.effect),t={effect:t},null==i&&(i={}),e.isFunction(i)&&(a=i,s=null,i={}),("number"==typeof i||e.fx.speeds[i])&&(a=s,s=i,i={}),e.isFunction(s)&&(a=s,s=null),i&&e.extend(t,i),s=s||i.duration,t.duration=e.fx.off?0:"number"==typeof s?s:s in e.fx.speeds?e.fx.speeds[s]:e.fx.speeds._default,t.complete=a||i.complete,t}function a(t){return!t||"number"==typeof t||e.fx.speeds[t]?!0:"string"!=typeof t||e.effects.effect[t]?e.isFunction(t)?!0:"object"!=typeof t||t.effect?!1:!0:!0}e.extend(e.effects,{version:"1.10.3",save:function(e,t){for(var s=0;t.length>s;s++)null!==t[s]&&e.data(i+t[s],e[0].style[t[s]])},restore:function(e,s){var a,n;for(n=0;s.length>n;n++)null!==s[n]&&(a=e.data(i+s[n]),a===t&&(a=""),e.css(s[n],a))},setMode:function(e,t){return"toggle"===t&&(t=e.is(":hidden")?"show":"hide"),t},getBaseline:function(e,t){var i,s;switch(e[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=e[0]/t.height}switch(e[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=e[1]/t.width}return{x:s,y:i}},createWrapper:function(t){if(t.parent().is(".ui-effects-wrapper"))return t.parent();var i={width:t.outerWidth(!0),height:t.outerHeight(!0),"float":t.css("float")},s=e("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),a={width:t.width(),height:t.height()},n=document.activeElement;try{n.id}catch(r){n=document.body}return t.wrap(s),(t[0]===n||e.contains(t[0],n))&&e(n).focus(),s=t.parent(),"static"===t.css("position")?(s.css({position:"relative"}),t.css({position:"relative"})):(e.extend(i,{position:t.css("position"),zIndex:t.css("z-index")}),e.each(["top","left","bottom","right"],function(e,s){i[s]=t.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),t.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),t.css(a),s.css(i).show()},removeWrapper:function(t){var i=document.activeElement;return t.parent().is(".ui-effects-wrapper")&&(t.parent().replaceWith(t),(t[0]===i||e.contains(t[0],i))&&e(i).focus()),t},setTransition:function(t,i,s,a){return a=a||{},e.each(i,function(e,i){var n=t.cssUnit(i);n[0]>0&&(a[i]=n[0]*s+n[1])}),a}}),e.fn.extend({effect:function(){function t(t){function s(){e.isFunction(n)&&n.call(a[0]),e.isFunction(t)&&t()}var a=e(this),n=i.complete,o=i.mode;(a.is(":hidden")?"hide"===o:"show"===o)?(a[o](),s()):r.call(a[0],i,s)}var i=s.apply(this,arguments),a=i.mode,n=i.queue,r=e.effects.effect[i.effect];return e.fx.off||!r?a?this[a](i.duration,i.complete):this.each(function(){i.complete&&i.complete.call(this)}):n===!1?this.each(t):this.queue(n||"fx",t)},show:function(e){return function(t){if(a(t))return e.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="show",this.effect.call(this,i)}}(e.fn.show),hide:function(e){return function(t){if(a(t))return e.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="hide",this.effect.call(this,i)}}(e.fn.hide),toggle:function(e){return function(t){if(a(t)||"boolean"==typeof t)return e.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="toggle",this.effect.call(this,i)}}(e.fn.toggle),cssUnit:function(t){var i=this.css(t),s=[];return e.each(["em","px","%","pt"],function(e,t){i.indexOf(t)>0&&(s=[parseFloat(i),t])}),s}})}(),function(){var t={};e.each(["Quad","Cubic","Quart","Quint","Expo"],function(e,i){t[i]=function(t){return Math.pow(t,e+2)}}),e.extend(t,{Sine:function(e){return 1-Math.cos(e*Math.PI/2)},Circ:function(e){return 1-Math.sqrt(1-e*e)},Elastic:function(e){return 0===e||1===e?e:-Math.pow(2,8*(e-1))*Math.sin((80*(e-1)-7.5)*Math.PI/15)},Back:function(e){return e*e*(3*e-2)},Bounce:function(e){for(var t,i=4;((t=Math.pow(2,--i))-1)/11>e;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*t-2)/22-e,2)}}),e.each(t,function(t,i){e.easing["easeIn"+t]=i,e.easing["easeOut"+t]=function(e){return 1-i(1-e)},e.easing["easeInOut"+t]=function(e){return.5>e?i(2*e)/2:1-i(-2*e+2)/2}})}()})(jQuery);
Index: extensions/Slim/js/jquery.fancybox.js
===================================================================
--- extensions/Slim/js/jquery.fancybox.js	(revision 28556)
+++ extensions/Slim/js/jquery.fancybox.js	(revision 28556)
@@ -0,0 +1,2020 @@
+/*!
+ * fancyBox - jQuery Plugin
+ * version: 2.1.5 (Fri, 14 Jun 2013)
+ * @requires jQuery v1.6 or later
+ *
+ * Examples at http://fancyapps.com/fancybox/
+ * License: www.fancyapps.com/fancybox/#license
+ *
+ * Copyright 2012 Janis Skarnelis - janis@fancyapps.com
+ *
+ */
+
+(function (window, document, $, undefined) {
+	"use strict";
+
+	var H = $("html"),
+		W = $(window),
+		D = $(document),
+		F = $.fancybox = function () {
+			F.open.apply( this, arguments );
+		},
+		IE =  navigator.userAgent.match(/msie/i),
+		didUpdate	= null,
+		isTouch		= document.createTouch !== undefined,
+
+		isQuery	= function(obj) {
+			return obj && obj.hasOwnProperty && obj instanceof $;
+		},
+		isString = function(str) {
+			return str && $.type(str) === "string";
+		},
+		isPercentage = function(str) {
+			return isString(str) && str.indexOf('%') > 0;
+		},
+		isScrollable = function(el) {
+			return (el && !(el.style.overflow && el.style.overflow === 'hidden') && ((el.clientWidth && el.scrollWidth > el.clientWidth) || (el.clientHeight && el.scrollHeight > el.clientHeight)));
+		},
+		getScalar = function(orig, dim) {
+			var value = parseInt(orig, 10) || 0;
+
+			if (dim && isPercentage(orig)) {
+				value = F.getViewport()[ dim ] / 100 * value;
+			}
+
+			return Math.ceil(value);
+		},
+		getValue = function(value, dim) {
+			return getScalar(value, dim) + 'px';
+		};
+
+	$.extend(F, {
+		// The current version of fancyBox
+		version: '2.1.5',
+
+		defaults: {
+			padding : 15,
+			margin  : 20,
+
+			width     : 800,
+			height    : 600,
+			minWidth  : 100,
+			minHeight : 100,
+			maxWidth  : 9999,
+			maxHeight : 9999,
+			pixelRatio: 1, // Set to 2 for retina display support
+
+			autoSize   : true,
+			autoHeight : false,
+			autoWidth  : false,
+
+			autoResize  : true,
+			autoCenter  : !isTouch,
+			fitToView   : true,
+			aspectRatio : false,
+			topRatio    : 0.5,
+			leftRatio   : 0.5,
+
+			scrolling : 'auto', // 'auto', 'yes' or 'no'
+			wrapCSS   : '',
+
+			arrows     : true,
+			closeBtn   : true,
+			closeClick : false,
+			nextClick  : false,
+			mouseWheel : true,
+			autoPlay   : false,
+			playSpeed  : 3000,
+			preload    : 3,
+			modal      : false,
+			loop       : true,
+
+			ajax  : {
+				dataType : 'html',
+				headers  : { 'X-fancyBox': true }
+			},
+			iframe : {
+				scrolling : 'auto',
+				preload   : true
+			},
+			swf : {
+				wmode: 'transparent',
+				allowfullscreen   : 'true',
+				allowscriptaccess : 'always'
+			},
+
+			keys  : {
+				next : {
+					13 : 'left', // enter
+					34 : 'up',   // page down
+					39 : 'left', // right arrow
+					40 : 'up'    // down arrow
+				},
+				prev : {
+					8  : 'right',  // backspace
+					33 : 'down',   // page up
+					37 : 'right',  // left arrow
+					38 : 'down'    // up arrow
+				},
+				close  : [27], // escape key
+				play   : [32], // space - start/stop slideshow
+				toggle : [70]  // letter "f" - toggle fullscreen
+			},
+
+			direction : {
+				next : 'left',
+				prev : 'right'
+			},
+
+			scrollOutside  : true,
+
+			// Override some properties
+			index   : 0,
+			type    : null,
+			href    : null,
+			content : null,
+			title   : null,
+
+			// HTML templates
+			tpl: {
+				wrap     : '<div class="fancybox-wrap" tabIndex="-1"><div class="fancybox-skin"><div class="fancybox-outer"><div class="fancybox-inner"></div></div></div></div>',
+				image    : '<img class="fancybox-image" src="{href}" alt="" />',
+				iframe   : '<iframe id="fancybox-frame{rnd}" name="fancybox-frame{rnd}" class="fancybox-iframe" frameborder="0" vspace="0" hspace="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen' + (IE ? ' allowtransparency="true"' : '') + '></iframe>',
+				error    : '<p class="fancybox-error">The requested content cannot be loaded.<br/>Please try again later.</p>',
+				closeBtn : '<a title="Close" class="fancybox-item fancybox-close" href="javascript:;"></a>',
+				next     : '<a title="Next" class="fancybox-nav fancybox-next" href="javascript:;"><span></span></a>',
+				prev     : '<a title="Previous" class="fancybox-nav fancybox-prev" href="javascript:;"><span></span></a>'
+			},
+
+			// Properties for each animation type
+			// Opening fancyBox
+			openEffect  : 'fade', // 'elastic', 'fade' or 'none'
+			openSpeed   : 250,
+			openEasing  : 'swing',
+			openOpacity : true,
+			openMethod  : 'zoomIn',
+
+			// Closing fancyBox
+			closeEffect  : 'fade', // 'elastic', 'fade' or 'none'
+			closeSpeed   : 250,
+			closeEasing  : 'swing',
+			closeOpacity : true,
+			closeMethod  : 'zoomOut',
+
+			// Changing next gallery item
+			nextEffect : 'elastic', // 'elastic', 'fade' or 'none'
+			nextSpeed  : 250,
+			nextEasing : 'swing',
+			nextMethod : 'changeIn',
+
+			// Changing previous gallery item
+			prevEffect : 'elastic', // 'elastic', 'fade' or 'none'
+			prevSpeed  : 250,
+			prevEasing : 'swing',
+			prevMethod : 'changeOut',
+
+			// Enable default helpers
+			helpers : {
+				overlay : true,
+				title   : true
+			},
+
+			// Callbacks
+			onCancel     : $.noop, // If canceling
+			beforeLoad   : $.noop, // Before loading
+			afterLoad    : $.noop, // After loading
+			beforeShow   : $.noop, // Before changing in current item
+			afterShow    : $.noop, // After opening
+			beforeChange : $.noop, // Before changing gallery item
+			beforeClose  : $.noop, // Before closing
+			afterClose   : $.noop  // After closing
+		},
+
+		//Current state
+		group    : {}, // Selected group
+		opts     : {}, // Group options
+		previous : null,  // Previous element
+		coming   : null,  // Element being loaded
+		current  : null,  // Currently loaded element
+		isActive : false, // Is activated
+		isOpen   : false, // Is currently open
+		isOpened : false, // Have been fully opened at least once
+
+		wrap  : null,
+		skin  : null,
+		outer : null,
+		inner : null,
+
+		player : {
+			timer    : null,
+			isActive : false
+		},
+
+		// Loaders
+		ajaxLoad   : null,
+		imgPreload : null,
+
+		// Some collections
+		transitions : {},
+		helpers     : {},
+
+		/*
+		 *	Static methods
+		 */
+
+		open: function (group, opts) {
+			if (!group) {
+				return;
+			}
+
+			if (!$.isPlainObject(opts)) {
+				opts = {};
+			}
+
+			// Close if already active
+			if (false === F.close(true)) {
+				return;
+			}
+
+			// Normalize group
+			if (!$.isArray(group)) {
+				group = isQuery(group) ? $(group).get() : [group];
+			}
+
+			// Recheck if the type of each element is `object` and set content type (image, ajax, etc)
+			$.each(group, function(i, element) {
+				var obj = {},
+					href,
+					title,
+					content,
+					type,
+					rez,
+					hrefParts,
+					selector;
+
+				if ($.type(element) === "object") {
+					// Check if is DOM element
+					if (element.nodeType) {
+						element = $(element);
+					}
+
+					if (isQuery(element)) {
+						obj = {
+							href    : element.data('fancybox-href') || element.attr('href'),
+							title   : element.data('fancybox-title') || element.attr('title'),
+							isDom   : true,
+							element : element
+						};
+
+						if ($.metadata) {
+							$.extend(true, obj, element.metadata());
+						}
+
+					} else {
+						obj = element;
+					}
+				}
+
+				href  = opts.href  || obj.href || (isString(element) ? element : null);
+				title = opts.title !== undefined ? opts.title : obj.title || '';
+
+				content = opts.content || obj.content;
+				type    = content ? 'html' : (opts.type  || obj.type);
+
+				if (!type && obj.isDom) {
+					type = element.data('fancybox-type');
+
+					if (!type) {
+						rez  = element.prop('class').match(/fancybox\.(\w+)/);
+						type = rez ? rez[1] : null;
+					}
+				}
+
+				if (isString(href)) {
+					// Try to guess the content type
+					if (!type) {
+						if (F.isImage(href)) {
+							type = 'image';
+
+						} else if (F.isSWF(href)) {
+							type = 'swf';
+
+						} else if (href.charAt(0) === '#') {
+							type = 'inline';
+
+						} else if (isString(element)) {
+							type    = 'html';
+							content = element;
+						}
+					}
+
+					// Split url into two pieces with source url and content selector, e.g,
+					// "/mypage.html #my_id" will load "/mypage.html" and display element having id "my_id"
+					if (type === 'ajax') {
+						hrefParts = href.split(/\s+/, 2);
+						href      = hrefParts.shift();
+						selector  = hrefParts.shift();
+					}
+				}
+
+				if (!content) {
+					if (type === 'inline') {
+						if (href) {
+							content = $( isString(href) ? href.replace(/.*(?=#[^\s]+$)/, '') : href ); //strip for ie7
+
+						} else if (obj.isDom) {
+							content = element;
+						}
+
+					} else if (type === 'html') {
+						content = href;
+
+					} else if (!type && !href && obj.isDom) {
+						type    = 'inline';
+						content = element;
+					}
+				}
+
+				$.extend(obj, {
+					href     : href,
+					type     : type,
+					content  : content,
+					title    : title,
+					selector : selector
+				});
+
+				group[ i ] = obj;
+			});
+
+			// Extend the defaults
+			F.opts = $.extend(true, {}, F.defaults, opts);
+
+			// All options are merged recursive except keys
+			if (opts.keys !== undefined) {
+				F.opts.keys = opts.keys ? $.extend({}, F.defaults.keys, opts.keys) : false;
+			}
+
+			F.group = group;
+
+			return F._start(F.opts.index);
+		},
+
+		// Cancel image loading or abort ajax request
+		cancel: function () {
+			var coming = F.coming;
+
+			if (!coming || false === F.trigger('onCancel')) {
+				return;
+			}
+
+			F.hideLoading();
+
+			if (F.ajaxLoad) {
+				F.ajaxLoad.abort();
+			}
+
+			F.ajaxLoad = null;
+
+			if (F.imgPreload) {
+				F.imgPreload.onload = F.imgPreload.onerror = null;
+			}
+
+			if (coming.wrap) {
+				coming.wrap.stop(true, true).trigger('onReset').remove();
+			}
+
+			F.coming = null;
+
+			// If the first item has been canceled, then clear everything
+			if (!F.current) {
+				F._afterZoomOut( coming );
+			}
+		},
+
+		// Start closing animation if is open; remove immediately if opening/closing
+		close: function (event) {
+			F.cancel();
+
+			if (false === F.trigger('beforeClose')) {
+				return;
+			}
+
+			F.unbindEvents();
+
+			if (!F.isActive) {
+				return;
+			}
+
+			if (!F.isOpen || event === true) {
+				$('.fancybox-wrap').stop(true).trigger('onReset').remove();
+
+				F._afterZoomOut();
+
+			} else {
+				F.isOpen = F.isOpened = false;
+				F.isClosing = true;
+
+				$('.fancybox-item, .fancybox-nav').remove();
+
+				F.wrap.stop(true, true).removeClass('fancybox-opened');
+
+				F.transitions[ F.current.closeMethod ]();
+			}
+		},
+
+		// Manage slideshow:
+		//   $.fancybox.play(); - toggle slideshow
+		//   $.fancybox.play( true ); - start
+		//   $.fancybox.play( false ); - stop
+		play: function ( action ) {
+			var clear = function () {
+					clearTimeout(F.player.timer);
+				},
+				set = function () {
+					clear();
+
+					if (F.current && F.player.isActive) {
+						F.player.timer = setTimeout(F.next, F.current.playSpeed);
+					}
+				},
+				stop = function () {
+					clear();
+
+					D.unbind('.player');
+
+					F.player.isActive = false;
+
+					F.trigger('onPlayEnd');
+				},
+				start = function () {
+					if (F.current && (F.current.loop || F.current.index < F.group.length - 1)) {
+						F.player.isActive = true;
+
+						D.bind({
+							'onCancel.player beforeClose.player' : stop,
+							'onUpdate.player'   : set,
+							'beforeLoad.player' : clear
+						});
+
+						set();
+
+						F.trigger('onPlayStart');
+					}
+				};
+
+			if (action === true || (!F.player.isActive && action !== false)) {
+				start();
+			} else {
+				stop();
+			}
+		},
+
+		// Navigate to next gallery item
+		next: function ( direction ) {
+			var current = F.current;
+
+			if (current) {
+				if (!isString(direction)) {
+					direction = current.direction.next;
+				}
+
+				F.jumpto(current.index + 1, direction, 'next');
+			}
+		},
+
+		// Navigate to previous gallery item
+		prev: function ( direction ) {
+			var current = F.current;
+
+			if (current) {
+				if (!isString(direction)) {
+					direction = current.direction.prev;
+				}
+
+				F.jumpto(current.index - 1, direction, 'prev');
+			}
+		},
+
+		// Navigate to gallery item by index
+		jumpto: function ( index, direction, router ) {
+			var current = F.current;
+
+			if (!current) {
+				return;
+			}
+
+			index = getScalar(index);
+
+			F.direction = direction || current.direction[ (index >= current.index ? 'next' : 'prev') ];
+			F.router    = router || 'jumpto';
+
+			if (current.loop) {
+				if (index < 0) {
+					index = current.group.length + (index % current.group.length);
+				}
+
+				index = index % current.group.length;
+			}
+
+			if (current.group[ index ] !== undefined) {
+				F.cancel();
+
+				F._start(index);
+			}
+		},
+
+		// Center inside viewport and toggle position type to fixed or absolute if needed
+		reposition: function (e, onlyAbsolute) {
+			var current = F.current,
+				wrap    = current ? current.wrap : null,
+				pos;
+
+			if (wrap) {
+				pos = F._getPosition(onlyAbsolute);
+
+				if (e && e.type === 'scroll') {
+					delete pos.position;
+
+					wrap.stop(true, true).animate(pos, 200);
+
+				} else {
+					wrap.css(pos);
+
+					current.pos = $.extend({}, current.dim, pos);
+				}
+			}
+		},
+
+		update: function (e) {
+			var type = (e && e.type),
+				anyway = !type || type === 'orientationchange';
+
+			if (anyway) {
+				clearTimeout(didUpdate);
+
+				didUpdate = null;
+			}
+
+			if (!F.isOpen || didUpdate) {
+				return;
+			}
+
+			didUpdate = setTimeout(function() {
+				var current = F.current;
+
+				if (!current || F.isClosing) {
+					return;
+				}
+
+				F.wrap.removeClass('fancybox-tmp');
+
+				if (anyway || type === 'load' || (type === 'resize' && current.autoResize)) {
+					F._setDimension();
+				}
+
+				if (!(type === 'scroll' && current.canShrink)) {
+					F.reposition(e);
+				}
+
+				F.trigger('onUpdate');
+
+				didUpdate = null;
+
+			}, (anyway && !isTouch ? 0 : 300));
+		},
+
+		// Shrink content to fit inside viewport or restore if resized
+		toggle: function ( action ) {
+			if (F.isOpen) {
+				F.current.fitToView = $.type(action) === "boolean" ? action : !F.current.fitToView;
+
+				// Help browser to restore document dimensions
+				if (isTouch) {
+					F.wrap.removeAttr('style').addClass('fancybox-tmp');
+
+					F.trigger('onUpdate');
+				}
+
+				F.update();
+			}
+		},
+
+		hideLoading: function () {
+			D.unbind('.loading');
+
+			$('#fancybox-loading').remove();
+		},
+
+		showLoading: function () {
+			var el, viewport;
+
+			F.hideLoading();
+
+			el = $('<div id="fancybox-loading"><div></div></div>').click(F.cancel).appendTo('body');
+
+			// If user will press the escape-button, the request will be canceled
+			D.bind('keydown.loading', function(e) {
+				if ((e.which || e.keyCode) === 27) {
+					e.preventDefault();
+
+					F.cancel();
+				}
+			});
+
+			if (!F.defaults.fixed) {
+				viewport = F.getViewport();
+
+				el.css({
+					position : 'absolute',
+					top  : (viewport.h * 0.5) + viewport.y,
+					left : (viewport.w * 0.5) + viewport.x
+				});
+			}
+		},
+
+		getViewport: function () {
+			var locked = (F.current && F.current.locked) || false,
+				rez    = {
+					x: W.scrollLeft(),
+					y: W.scrollTop()
+				};
+
+			if (locked) {
+				rez.w = locked[0].clientWidth;
+				rez.h = locked[0].clientHeight;
+
+			} else {
+				// See http://bugs.jquery.com/ticket/6724
+				rez.w = isTouch && window.innerWidth  ? window.innerWidth  : W.width();
+				rez.h = isTouch && window.innerHeight ? window.innerHeight : W.height();
+			}
+
+			return rez;
+		},
+
+		// Unbind the keyboard / clicking actions
+		unbindEvents: function () {
+			if (F.wrap && isQuery(F.wrap)) {
+				F.wrap.unbind('.fb');
+			}
+
+			D.unbind('.fb');
+			W.unbind('.fb');
+		},
+
+		bindEvents: function () {
+			var current = F.current,
+				keys;
+
+			if (!current) {
+				return;
+			}
+
+			// Changing document height on iOS devices triggers a 'resize' event,
+			// that can change document height... repeating infinitely
+			W.bind('orientationchange.fb' + (isTouch ? '' : ' resize.fb') + (current.autoCenter && !current.locked ? ' scroll.fb' : ''), F.update);
+
+			keys = current.keys;
+
+			if (keys) {
+				D.bind('keydown.fb', function (e) {
+					var code   = e.which || e.keyCode,
+						target = e.target || e.srcElement;
+
+					// Skip esc key if loading, because showLoading will cancel preloading
+					if (code === 27 && F.coming) {
+						return false;
+					}
+
+					// Ignore key combinations and key events within form elements
+					if (!e.ctrlKey && !e.altKey && !e.shiftKey && !e.metaKey && !(target && (target.type || $(target).is('[contenteditable]')))) {
+						$.each(keys, function(i, val) {
+							if (current.group.length > 1 && val[ code ] !== undefined) {
+								F[ i ]( val[ code ] );
+
+								e.preventDefault();
+								return false;
+							}
+
+							if ($.inArray(code, val) > -1) {
+								F[ i ] ();
+
+								e.preventDefault();
+								return false;
+							}
+						});
+					}
+				});
+			}
+
+			if ($.fn.mousewheel && current.mouseWheel) {
+				F.wrap.bind('mousewheel.fb', function (e, delta, deltaX, deltaY) {
+					var target = e.target || null,
+						parent = $(target),
+						canScroll = false;
+
+					while (parent.length) {
+						if (canScroll || parent.is('.fancybox-skin') || parent.is('.fancybox-wrap')) {
+							break;
+						}
+
+						canScroll = isScrollable( parent[0] );
+						parent    = $(parent).parent();
+					}
+
+					if (delta !== 0 && !canScroll) {
+						if (F.group.length > 1 && !current.canShrink) {
+							if (deltaY > 0 || deltaX > 0) {
+								F.prev( deltaY > 0 ? 'down' : 'left' );
+
+							} else if (deltaY < 0 || deltaX < 0) {
+								F.next( deltaY < 0 ? 'up' : 'right' );
+							}
+
+							e.preventDefault();
+						}
+					}
+				});
+			}
+		},
+
+		trigger: function (event, o) {
+			var ret, obj = o || F.coming || F.current;
+
+			if (!obj) {
+				return;
+			}
+
+			if ($.isFunction( obj[event] )) {
+				ret = obj[event].apply(obj, Array.prototype.slice.call(arguments, 1));
+			}
+
+			if (ret === false) {
+				return false;
+			}
+
+			if (obj.helpers) {
+				$.each(obj.helpers, function (helper, opts) {
+					if (opts && F.helpers[helper] && $.isFunction(F.helpers[helper][event])) {
+						F.helpers[helper][event]($.extend(true, {}, F.helpers[helper].defaults, opts), obj);
+					}
+				});
+			}
+
+			D.trigger(event);
+		},
+
+		isImage: function (str) {
+			return isString(str) && str.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i);
+		},
+
+		isSWF: function (str) {
+			return isString(str) && str.match(/\.(swf)((\?|#).*)?$/i);
+		},
+
+		_start: function (index) {
+			var coming = {},
+				obj,
+				href,
+				type,
+				margin,
+				padding;
+
+			index = getScalar( index );
+			obj   = F.group[ index ] || null;
+
+			if (!obj) {
+				return false;
+			}
+
+			coming = $.extend(true, {}, F.opts, obj);
+
+			// Convert margin and padding properties to array - top, right, bottom, left
+			margin  = coming.margin;
+			padding = coming.padding;
+
+			if ($.type(margin) === 'number') {
+				coming.margin = [margin, margin, margin, margin];
+			}
+
+			if ($.type(padding) === 'number') {
+				coming.padding = [padding, padding, padding, padding];
+			}
+
+			// 'modal' propery is just a shortcut
+			if (coming.modal) {
+				$.extend(true, coming, {
+					closeBtn   : false,
+					closeClick : false,
+					nextClick  : false,
+					arrows     : false,
+					mouseWheel : false,
+					keys       : null,
+					helpers: {
+						overlay : {
+							closeClick : false
+						}
+					}
+				});
+			}
+
+			// 'autoSize' property is a shortcut, too
+			if (coming.autoSize) {
+				coming.autoWidth = coming.autoHeight = true;
+			}
+
+			if (coming.width === 'auto') {
+				coming.autoWidth = true;
+			}
+
+			if (coming.height === 'auto') {
+				coming.autoHeight = true;
+			}
+
+			/*
+			 * Add reference to the group, so it`s possible to access from callbacks, example:
+			 * afterLoad : function() {
+			 *     this.title = 'Image ' + (this.index + 1) + ' of ' + this.group.length + (this.title ? ' - ' + this.title : '');
+			 * }
+			 */
+
+			coming.group  = F.group;
+			coming.index  = index;
+
+			// Give a chance for callback or helpers to update coming item (type, title, etc)
+			F.coming = coming;
+
+			if (false === F.trigger('beforeLoad')) {
+				F.coming = null;
+
+				return;
+			}
+
+			type = coming.type;
+			href = coming.href;
+
+			if (!type) {
+				F.coming = null;
+
+				//If we can not determine content type then drop silently or display next/prev item if looping through gallery
+				if (F.current && F.router && F.router !== 'jumpto') {
+					F.current.index = index;
+
+					return F[ F.router ]( F.direction );
+				}
+
+				return false;
+			}
+
+			F.isActive = true;
+
+			if (type === 'image' || type === 'swf') {
+				coming.autoHeight = coming.autoWidth = false;
+				coming.scrolling  = 'visible';
+			}
+
+			if (type === 'image') {
+				coming.aspectRatio = true;
+			}
+
+			if (type === 'iframe' && isTouch) {
+				coming.scrolling = 'scroll';
+			}
+
+			// Build the neccessary markup
+			coming.wrap = $(coming.tpl.wrap).addClass('fancybox-' + (isTouch ? 'mobile' : 'desktop') + ' fancybox-type-' + type + ' fancybox-tmp ' + coming.wrapCSS).appendTo( coming.parent || 'body' );
+
+			$.extend(coming, {
+				skin  : $('.fancybox-skin',  coming.wrap),
+				outer : $('.fancybox-outer', coming.wrap),
+				inner : $('.fancybox-inner', coming.wrap)
+			});
+
+			$.each(["Top", "Right", "Bottom", "Left"], function(i, v) {
+				coming.skin.css('padding' + v, getValue(coming.padding[ i ]));
+			});
+
+			F.trigger('onReady');
+
+			// Check before try to load; 'inline' and 'html' types need content, others - href
+			if (type === 'inline' || type === 'html') {
+				if (!coming.content || !coming.content.length) {
+					return F._error( 'content' );
+				}
+
+			} else if (!href) {
+				return F._error( 'href' );
+			}
+
+			if (type === 'image') {
+				F._loadImage();
+
+			} else if (type === 'ajax') {
+				F._loadAjax();
+
+			} else if (type === 'iframe') {
+				F._loadIframe();
+
+			} else {
+				F._afterLoad();
+			}
+		},
+
+		_error: function ( type ) {
+			$.extend(F.coming, {
+				type       : 'html',
+				autoWidth  : true,
+				autoHeight : true,
+				minWidth   : 0,
+				minHeight  : 0,
+				scrolling  : 'no',
+				hasError   : type,
+				content    : F.coming.tpl.error
+			});
+
+			F._afterLoad();
+		},
+
+		_loadImage: function () {
+			// Reset preload image so it is later possible to check "complete" property
+			var img = F.imgPreload = new Image();
+
+			img.onload = function () {
+				this.onload = this.onerror = null;
+
+				F.coming.width  = this.width / F.opts.pixelRatio;
+				F.coming.height = this.height / F.opts.pixelRatio;
+
+				F._afterLoad();
+			};
+
+			img.onerror = function () {
+				this.onload = this.onerror = null;
+
+				F._error( 'image' );
+			};
+
+			img.src = F.coming.href;
+
+			if (img.complete !== true) {
+				F.showLoading();
+			}
+		},
+
+		_loadAjax: function () {
+			var coming = F.coming;
+
+			F.showLoading();
+
+			F.ajaxLoad = $.ajax($.extend({}, coming.ajax, {
+				url: coming.href,
+				error: function (jqXHR, textStatus) {
+					if (F.coming && textStatus !== 'abort') {
+						F._error( 'ajax', jqXHR );
+
+					} else {
+						F.hideLoading();
+					}
+				},
+				success: function (data, textStatus) {
+					if (textStatus === 'success') {
+						coming.content = data;
+
+						F._afterLoad();
+					}
+				}
+			}));
+		},
+
+		_loadIframe: function() {
+			var coming = F.coming,
+				iframe = $(coming.tpl.iframe.replace(/\{rnd\}/g, new Date().getTime()))
+					.attr('scrolling', isTouch ? 'auto' : coming.iframe.scrolling)
+					.attr('src', coming.href);
+
+			// This helps IE
+			$(coming.wrap).bind('onReset', function () {
+				try {
+					$(this).find('iframe').hide().attr('src', '//about:blank').end().empty();
+				} catch (e) {}
+			});
+
+			if (coming.iframe.preload) {
+				F.showLoading();
+
+				iframe.one('load', function() {
+					$(this).data('ready', 1);
+
+					// iOS will lose scrolling if we resize
+					if (!isTouch) {
+						$(this).bind('load.fb', F.update);
+					}
+
+					// Without this trick:
+					//   - iframe won't scroll on iOS devices
+					//   - IE7 sometimes displays empty iframe
+					$(this).parents('.fancybox-wrap').width('100%').removeClass('fancybox-tmp').show();
+
+					F._afterLoad();
+				});
+			}
+
+			coming.content = iframe.appendTo( coming.inner );
+
+			if (!coming.iframe.preload) {
+				F._afterLoad();
+			}
+		},
+
+		_preloadImages: function() {
+			var group   = F.group,
+				current = F.current,
+				len     = group.length,
+				cnt     = current.preload ? Math.min(current.preload, len - 1) : 0,
+				item,
+				i;
+
+			for (i = 1; i <= cnt; i += 1) {
+				item = group[ (current.index + i ) % len ];
+
+				if (item.type === 'image' && item.href) {
+					new Image().src = item.href;
+				}
+			}
+		},
+
+		_afterLoad: function () {
+			var coming   = F.coming,
+				previous = F.current,
+				placeholder = 'fancybox-placeholder',
+				current,
+				content,
+				type,
+				scrolling,
+				href,
+				embed;
+
+			F.hideLoading();
+
+			if (!coming || F.isActive === false) {
+				return;
+			}
+
+			if (false === F.trigger('afterLoad', coming, previous)) {
+				coming.wrap.stop(true).trigger('onReset').remove();
+
+				F.coming = null;
+
+				return;
+			}
+
+			if (previous) {
+				F.trigger('beforeChange', previous);
+
+				previous.wrap.stop(true).removeClass('fancybox-opened')
+					.find('.fancybox-item, .fancybox-nav')
+					.remove();
+			}
+
+			F.unbindEvents();
+
+			current   = coming;
+			content   = coming.content;
+			type      = coming.type;
+			scrolling = coming.scrolling;
+
+			$.extend(F, {
+				wrap  : current.wrap,
+				skin  : current.skin,
+				outer : current.outer,
+				inner : current.inner,
+				current  : current,
+				previous : previous
+			});
+
+			href = current.href;
+
+			switch (type) {
+				case 'inline':
+				case 'ajax':
+				case 'html':
+					if (current.selector) {
+						content = $('<div>').html(content).find(current.selector);
+
+					} else if (isQuery(content)) {
+						if (!content.data(placeholder)) {
+							content.data(placeholder, $('<div class="' + placeholder + '"></div>').insertAfter( content ).hide() );
+						}
+
+						content = content.show().detach();
+
+						current.wrap.bind('onReset', function () {
+							if ($(this).find(content).length) {
+								content.hide().replaceAll( content.data(placeholder) ).data(placeholder, false);
+							}
+						});
+					}
+				break;
+
+				case 'image':
+					content = current.tpl.image.replace('{href}', href);
+				break;
+
+				case 'swf':
+					content = '<object id="fancybox-swf" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%"><param name="movie" value="' + href + '"></param>';
+					embed   = '';
+
+					$.each(current.swf, function(name, val) {
+						content += '<param name="' + name + '" value="' + val + '"></param>';
+						embed   += ' ' + name + '="' + val + '"';
+					});
+
+					content += '<embed src="' + href + '" type="application/x-shockwave-flash" width="100%" height="100%"' + embed + '></embed></object>';
+				break;
+			}
+
+			if (!(isQuery(content) && content.parent().is(current.inner))) {
+				current.inner.append( content );
+			}
+
+			// Give a chance for helpers or callbacks to update elements
+			F.trigger('beforeShow');
+
+			// Set scrolling before calculating dimensions
+			current.inner.css('overflow', scrolling === 'yes' ? 'scroll' : (scrolling === 'no' ? 'hidden' : scrolling));
+
+			// Set initial dimensions and start position
+			F._setDimension();
+
+			F.reposition();
+
+			F.isOpen = false;
+			F.coming = null;
+
+			F.bindEvents();
+
+			if (!F.isOpened) {
+				$('.fancybox-wrap').not( current.wrap ).stop(true).trigger('onReset').remove();
+
+			} else if (previous.prevMethod) {
+				F.transitions[ previous.prevMethod ]();
+			}
+
+			F.transitions[ F.isOpened ? current.nextMethod : current.openMethod ]();
+
+			F._preloadImages();
+		},
+
+		_setDimension: function () {
+			var viewport   = F.getViewport(),
+				steps      = 0,
+				canShrink  = false,
+				canExpand  = false,
+				wrap       = F.wrap,
+				skin       = F.skin,
+				inner      = F.inner,
+				current    = F.current,
+				width      = current.width,
+				height     = current.height,
+				minWidth   = current.minWidth,
+				minHeight  = current.minHeight,
+				maxWidth   = current.maxWidth,
+				maxHeight  = current.maxHeight,
+				scrolling  = current.scrolling,
+				scrollOut  = current.scrollOutside ? current.scrollbarWidth : 0,
+				margin     = current.margin,
+				wMargin    = getScalar(margin[1] + margin[3]),
+				hMargin    = getScalar(margin[0] + margin[2]),
+				wPadding,
+				hPadding,
+				wSpace,
+				hSpace,
+				origWidth,
+				origHeight,
+				origMaxWidth,
+				origMaxHeight,
+				ratio,
+				width_,
+				height_,
+				maxWidth_,
+				maxHeight_,
+				iframe,
+				body;
+
+			// Reset dimensions so we could re-check actual size
+			wrap.add(skin).add(inner).width('auto').height('auto').removeClass('fancybox-tmp');
+
+			wPadding = getScalar(skin.outerWidth(true)  - skin.width());
+			hPadding = getScalar(skin.outerHeight(true) - skin.height());
+
+			// Any space between content and viewport (margin, padding, border, title)
+			wSpace = wMargin + wPadding;
+			hSpace = hMargin + hPadding;
+
+			origWidth  = isPercentage(width)  ? (viewport.w - wSpace) * getScalar(width)  / 100 : width;
+			origHeight = isPercentage(height) ? (viewport.h - hSpace) * getScalar(height) / 100 : height;
+
+			if (current.type === 'iframe') {
+				iframe = current.content;
+
+				if (current.autoHeight && iframe.data('ready') === 1) {
+					try {
+						if (iframe[0].contentWindow.document.location) {
+							inner.width( origWidth ).height(9999);
+
+							body = iframe.contents().find('body');
+
+							if (scrollOut) {
+								body.css('overflow-x', 'hidden');
+							}
+
+							origHeight = body.outerHeight(true);
+						}
+
+					} catch (e) {}
+				}
+
+			} else if (current.autoWidth || current.autoHeight) {
+				inner.addClass( 'fancybox-tmp' );
+
+				// Set width or height in case we need to calculate only one dimension
+				if (!current.autoWidth) {
+					inner.width( origWidth );
+				}
+
+				if (!current.autoHeight) {
+					inner.height( origHeight );
+				}
+
+				if (current.autoWidth) {
+					origWidth = inner.width();
+				}
+
+				if (current.autoHeight) {
+					origHeight = inner.height();
+				}
+
+				inner.removeClass( 'fancybox-tmp' );
+			}
+
+			width  = getScalar( origWidth );
+			height = getScalar( origHeight );
+
+			ratio  = origWidth / origHeight;
+
+			// Calculations for the content
+			minWidth  = getScalar(isPercentage(minWidth) ? getScalar(minWidth, 'w') - wSpace : minWidth);
+			maxWidth  = getScalar(isPercentage(maxWidth) ? getScalar(maxWidth, 'w') - wSpace : maxWidth);
+
+			minHeight = getScalar(isPercentage(minHeight) ? getScalar(minHeight, 'h') - hSpace : minHeight);
+			maxHeight = getScalar(isPercentage(maxHeight) ? getScalar(maxHeight, 'h') - hSpace : maxHeight);
+
+			// These will be used to determine if wrap can fit in the viewport
+			origMaxWidth  = maxWidth;
+			origMaxHeight = maxHeight;
+
+			if (current.fitToView) {
+				maxWidth  = Math.min(viewport.w - wSpace, maxWidth);
+				maxHeight = Math.min(viewport.h - hSpace, maxHeight);
+			}
+
+			maxWidth_  = viewport.w - wMargin;
+			maxHeight_ = viewport.h - hMargin;
+
+			if (current.aspectRatio) {
+				if (width > maxWidth) {
+					width  = maxWidth;
+					height = getScalar(width / ratio);
+				}
+
+				if (height > maxHeight) {
+					height = maxHeight;
+					width  = getScalar(height * ratio);
+				}
+
+				if (width < minWidth) {
+					width  = minWidth;
+					height = getScalar(width / ratio);
+				}
+
+				if (height < minHeight) {
+					height = minHeight;
+					width  = getScalar(height * ratio);
+				}
+
+			} else {
+				width = Math.max(minWidth, Math.min(width, maxWidth));
+
+				if (current.autoHeight && current.type !== 'iframe') {
+					inner.width( width );
+
+					height = inner.height();
+				}
+
+				height = Math.max(minHeight, Math.min(height, maxHeight));
+			}
+
+			// Try to fit inside viewport (including the title)
+			if (current.fitToView) {
+				inner.width( width ).height( height );
+
+				wrap.width( width + wPadding );
+
+				// Real wrap dimensions
+				width_  = wrap.width();
+				height_ = wrap.height();
+
+				if (current.aspectRatio) {
+					while ((width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight) {
+						if (steps++ > 19) {
+							break;
+						}
+
+						height = Math.max(minHeight, Math.min(maxHeight, height - 10));
+						width  = getScalar(height * ratio);
+
+						if (width < minWidth) {
+							width  = minWidth;
+							height = getScalar(width / ratio);
+						}
+
+						if (width > maxWidth) {
+							width  = maxWidth;
+							height = getScalar(width / ratio);
+						}
+
+						inner.width( width ).height( height );
+
+						wrap.width( width + wPadding );
+
+						width_  = wrap.width();
+						height_ = wrap.height();
+					}
+
+				} else {
+					width  = Math.max(minWidth,  Math.min(width,  width  - (width_  - maxWidth_)));
+					height = Math.max(minHeight, Math.min(height, height - (height_ - maxHeight_)));
+				}
+			}
+
+			if (scrollOut && scrolling === 'auto' && height < origHeight && (width + wPadding + scrollOut) < maxWidth_) {
+				width += scrollOut;
+			}
+
+			inner.width( width ).height( height );
+
+			wrap.width( width + wPadding );
+
+			width_  = wrap.width();
+			height_ = wrap.height();
+
+			canShrink = (width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight;
+			canExpand = current.aspectRatio ? (width < origMaxWidth && height < origMaxHeight && width < origWidth && height < origHeight) : ((width < origMaxWidth || height < origMaxHeight) && (width < origWidth || height < origHeight));
+
+			$.extend(current, {
+				dim : {
+					width	: getValue( width_ ),
+					height	: getValue( height_ )
+				},
+				origWidth  : origWidth,
+				origHeight : origHeight,
+				canShrink  : canShrink,
+				canExpand  : canExpand,
+				wPadding   : wPadding,
+				hPadding   : hPadding,
+				wrapSpace  : height_ - skin.outerHeight(true),
+				skinSpace  : skin.height() - height
+			});
+
+			if (!iframe && current.autoHeight && height > minHeight && height < maxHeight && !canExpand) {
+				inner.height('auto');
+			}
+		},
+
+		_getPosition: function (onlyAbsolute) {
+			var current  = F.current,
+				viewport = F.getViewport(),
+				margin   = current.margin,
+				width    = F.wrap.width()  + margin[1] + margin[3],
+				height   = F.wrap.height() + margin[0] + margin[2],
+				rez      = {
+					position: 'absolute',
+					top  : margin[0],
+					left : margin[3]
+				};
+
+			if (current.autoCenter && current.fixed && !onlyAbsolute && height <= viewport.h && width <= viewport.w) {
+				rez.position = 'fixed';
+
+			} else if (!current.locked) {
+				rez.top  += viewport.y;
+				rez.left += viewport.x;
+			}
+
+			rez.top  = getValue(Math.max(rez.top,  rez.top  + ((viewport.h - height) * current.topRatio)));
+			rez.left = getValue(Math.max(rez.left, rez.left + ((viewport.w - width)  * current.leftRatio)));
+
+			return rez;
+		},
+
+		_afterZoomIn: function () {
+			var current = F.current;
+
+			if (!current) {
+				return;
+			}
+
+			F.isOpen = F.isOpened = true;
+
+			F.wrap.css('overflow', 'visible').addClass('fancybox-opened');
+
+			F.update();
+
+			// Assign a click event
+			if ( current.closeClick || (current.nextClick && F.group.length > 1) ) {
+				F.inner.css('cursor', 'pointer').bind('click.fb', function(e) {
+					if (!$(e.target).is('a') && !$(e.target).parent().is('a')) {
+						e.preventDefault();
+
+						F[ current.closeClick ? 'close' : 'next' ]();
+					}
+				});
+			}
+
+			// Create a close button
+			if (current.closeBtn) {
+				$(current.tpl.closeBtn).appendTo(F.skin).bind('click.fb', function(e) {
+					e.preventDefault();
+
+					F.close();
+				});
+			}
+
+			// Create navigation arrows
+			if (current.arrows && F.group.length > 1) {
+				if (current.loop || current.index > 0) {
+					$(current.tpl.prev).appendTo(F.outer).bind('click.fb', F.prev);
+				}
+
+				if (current.loop || current.index < F.group.length - 1) {
+					$(current.tpl.next).appendTo(F.outer).bind('click.fb', F.next);
+				}
+			}
+
+			F.trigger('afterShow');
+
+			// Stop the slideshow if this is the last item
+			if (!current.loop && current.index === current.group.length - 1) {
+				F.play( false );
+
+			} else if (F.opts.autoPlay && !F.player.isActive) {
+				F.opts.autoPlay = false;
+
+				F.play();
+			}
+		},
+
+		_afterZoomOut: function ( obj ) {
+			obj = obj || F.current;
+
+			$('.fancybox-wrap').trigger('onReset').remove();
+
+			$.extend(F, {
+				group  : {},
+				opts   : {},
+				router : false,
+				current   : null,
+				isActive  : false,
+				isOpened  : false,
+				isOpen    : false,
+				isClosing : false,
+				wrap   : null,
+				skin   : null,
+				outer  : null,
+				inner  : null
+			});
+
+			F.trigger('afterClose', obj);
+		}
+	});
+
+	/*
+	 *	Default transitions
+	 */
+
+	F.transitions = {
+		getOrigPosition: function () {
+			var current  = F.current,
+				element  = current.element,
+				orig     = current.orig,
+				pos      = {},
+				width    = 50,
+				height   = 50,
+				hPadding = current.hPadding,
+				wPadding = current.wPadding,
+				viewport = F.getViewport();
+
+			if (!orig && current.isDom && element.is(':visible')) {
+				orig = element.find('img:first');
+
+				if (!orig.length) {
+					orig = element;
+				}
+			}
+
+			if (isQuery(orig)) {
+				pos = orig.offset();
+
+				if (orig.is('img')) {
+					width  = orig.outerWidth();
+					height = orig.outerHeight();
+				}
+
+			} else {
+				pos.top  = viewport.y + (viewport.h - height) * current.topRatio;
+				pos.left = viewport.x + (viewport.w - width)  * current.leftRatio;
+			}
+
+			if (F.wrap.css('position') === 'fixed' || current.locked) {
+				pos.top  -= viewport.y;
+				pos.left -= viewport.x;
+			}
+
+			pos = {
+				top     : getValue(pos.top  - hPadding * current.topRatio),
+				left    : getValue(pos.left - wPadding * current.leftRatio),
+				width   : getValue(width  + wPadding),
+				height  : getValue(height + hPadding)
+			};
+
+			return pos;
+		},
+
+		step: function (now, fx) {
+			var ratio,
+				padding,
+				value,
+				prop       = fx.prop,
+				current    = F.current,
+				wrapSpace  = current.wrapSpace,
+				skinSpace  = current.skinSpace;
+
+			if (prop === 'width' || prop === 'height') {
+				ratio = fx.end === fx.start ? 1 : (now - fx.start) / (fx.end - fx.start);
+
+				if (F.isClosing) {
+					ratio = 1 - ratio;
+				}
+
+				padding = prop === 'width' ? current.wPadding : current.hPadding;
+				value   = now - padding;
+
+				F.skin[ prop ](  getScalar( prop === 'width' ?  value : value - (wrapSpace * ratio) ) );
+				F.inner[ prop ]( getScalar( prop === 'width' ?  value : value - (wrapSpace * ratio) - (skinSpace * ratio) ) );
+			}
+		},
+
+		zoomIn: function () {
+			var current  = F.current,
+				startPos = current.pos,
+				effect   = current.openEffect,
+				elastic  = effect === 'elastic',
+				endPos   = $.extend({opacity : 1}, startPos);
+
+			// Remove "position" property that breaks older IE
+			delete endPos.position;
+
+			if (elastic) {
+				startPos = this.getOrigPosition();
+
+				if (current.openOpacity) {
+					startPos.opacity = 0.1;
+				}
+
+			} else if (effect === 'fade') {
+				startPos.opacity = 0.1;
+			}
+
+			F.wrap.css(startPos).animate(endPos, {
+				duration : effect === 'none' ? 0 : current.openSpeed,
+				easing   : current.openEasing,
+				step     : elastic ? this.step : null,
+				complete : F._afterZoomIn
+			});
+		},
+
+		zoomOut: function () {
+			var current  = F.current,
+				effect   = current.closeEffect,
+				elastic  = effect === 'elastic',
+				endPos   = {opacity : 0.1};
+
+			if (elastic) {
+				endPos = this.getOrigPosition();
+
+				if (current.closeOpacity) {
+					endPos.opacity = 0.1;
+				}
+			}
+
+			F.wrap.animate(endPos, {
+				duration : effect === 'none' ? 0 : current.closeSpeed,
+				easing   : current.closeEasing,
+				step     : elastic ? this.step : null,
+				complete : F._afterZoomOut
+			});
+		},
+
+		changeIn: function () {
+			var current   = F.current,
+				effect    = current.nextEffect,
+				startPos  = current.pos,
+				endPos    = { opacity : 1 },
+				direction = F.direction,
+				distance  = 200,
+				field;
+
+			startPos.opacity = 0.1;
+
+			if (effect === 'elastic') {
+				field = direction === 'down' || direction === 'up' ? 'top' : 'left';
+
+				if (direction === 'down' || direction === 'right') {
+					startPos[ field ] = getValue(getScalar(startPos[ field ]) - distance);
+					endPos[ field ]   = '+=' + distance + 'px';
+
+				} else {
+					startPos[ field ] = getValue(getScalar(startPos[ field ]) + distance);
+					endPos[ field ]   = '-=' + distance + 'px';
+				}
+			}
+
+			// Workaround for http://bugs.jquery.com/ticket/12273
+			if (effect === 'none') {
+				F._afterZoomIn();
+
+			} else {
+				F.wrap.css(startPos).animate(endPos, {
+					duration : current.nextSpeed,
+					easing   : current.nextEasing,
+					complete : F._afterZoomIn
+				});
+			}
+		},
+
+		changeOut: function () {
+			var previous  = F.previous,
+				effect    = previous.prevEffect,
+				endPos    = { opacity : 0.1 },
+				direction = F.direction,
+				distance  = 200;
+
+			if (effect === 'elastic') {
+				endPos[ direction === 'down' || direction === 'up' ? 'top' : 'left' ] = ( direction === 'up' || direction === 'left' ? '-' : '+' ) + '=' + distance + 'px';
+			}
+
+			previous.wrap.animate(endPos, {
+				duration : effect === 'none' ? 0 : previous.prevSpeed,
+				easing   : previous.prevEasing,
+				complete : function () {
+					$(this).trigger('onReset').remove();
+				}
+			});
+		}
+	};
+
+	/*
+	 *	Overlay helper
+	 */
+
+	F.helpers.overlay = {
+		defaults : {
+			closeClick : true,      // if true, fancyBox will be closed when user clicks on the overlay
+			speedOut   : 200,       // duration of fadeOut animation
+			showEarly  : true,      // indicates if should be opened immediately or wait until the content is ready
+			css        : {},        // custom CSS properties
+			locked     : !isTouch,  // if true, the content will be locked into overlay
+			fixed      : true       // if false, the overlay CSS position property will not be set to "fixed"
+		},
+
+		overlay : null,      // current handle
+		fixed   : false,     // indicates if the overlay has position "fixed"
+		el      : $('html'), // element that contains "the lock"
+
+		// Public methods
+		create : function(opts) {
+			opts = $.extend({}, this.defaults, opts);
+
+			if (this.overlay) {
+				this.close();
+			}
+
+			this.overlay = $('<div class="fancybox-overlay"></div>').appendTo( F.coming ? F.coming.parent : opts.parent );
+			this.fixed   = false;
+
+			if (opts.fixed && F.defaults.fixed) {
+				this.overlay.addClass('fancybox-overlay-fixed');
+
+				this.fixed = true;
+			}
+		},
+
+		open : function(opts) {
+			var that = this;
+
+			opts = $.extend({}, this.defaults, opts);
+
+			if (this.overlay) {
+				this.overlay.unbind('.overlay').width('auto').height('auto');
+
+			} else {
+				this.create(opts);
+			}
+
+			if (!this.fixed) {
+				W.bind('resize.overlay', $.proxy( this.update, this) );
+
+				this.update();
+			}
+
+			if (opts.closeClick) {
+				this.overlay.bind('click.overlay', function(e) {
+					if ($(e.target).hasClass('fancybox-overlay')) {
+						if (F.isActive) {
+							F.close();
+						} else {
+							that.close();
+						}
+
+						return false;
+					}
+				});
+			}
+
+			this.overlay.css( opts.css ).show();
+		},
+
+		close : function() {
+			var scrollV, scrollH;
+
+			W.unbind('resize.overlay');
+
+			if (this.el.hasClass('fancybox-lock')) {
+				$('.fancybox-margin').removeClass('fancybox-margin');
+
+				scrollV = W.scrollTop();
+				scrollH = W.scrollLeft();
+
+				this.el.removeClass('fancybox-lock');
+
+				W.scrollTop( scrollV ).scrollLeft( scrollH );
+			}
+
+			$('.fancybox-overlay').remove().hide();
+
+			$.extend(this, {
+				overlay : null,
+				fixed   : false
+			});
+		},
+
+		// Private, callbacks
+
+		update : function () {
+			var width = '100%', offsetWidth;
+
+			// Reset width/height so it will not mess
+			this.overlay.width(width).height('100%');
+
+			// jQuery does not return reliable result for IE
+			if (IE) {
+				offsetWidth = Math.max(document.documentElement.offsetWidth, document.body.offsetWidth);
+
+				if (D.width() > offsetWidth) {
+					width = D.width();
+				}
+
+			} else if (D.width() > W.width()) {
+				width = D.width();
+			}
+
+			this.overlay.width(width).height(D.height());
+		},
+
+		// This is where we can manipulate DOM, because later it would cause iframes to reload
+		onReady : function (opts, obj) {
+			var overlay = this.overlay;
+
+			$('.fancybox-overlay').stop(true, true);
+
+			if (!overlay) {
+				this.create(opts);
+			}
+
+			if (opts.locked && this.fixed && obj.fixed) {
+				if (!overlay) {
+					this.margin = D.height() > W.height() ? $('html').css('margin-right').replace("px", "") : false;
+				}
+
+				obj.locked = this.overlay.append( obj.wrap );
+				obj.fixed  = false;
+			}
+
+			if (opts.showEarly === true) {
+				this.beforeShow.apply(this, arguments);
+			}
+		},
+
+		beforeShow : function(opts, obj) {
+			var scrollV, scrollH;
+
+			if (obj.locked) {
+				if (this.margin !== false) {
+					$('*').filter(function(){
+						return ($(this).css('position') === 'fixed' && !$(this).hasClass("fancybox-overlay") && !$(this).hasClass("fancybox-wrap") );
+					}).addClass('fancybox-margin');
+
+					this.el.addClass('fancybox-margin');
+				}
+
+				scrollV = W.scrollTop();
+				scrollH = W.scrollLeft();
+
+				this.el.addClass('fancybox-lock');
+
+				W.scrollTop( scrollV ).scrollLeft( scrollH );
+			}
+
+			this.open(opts);
+		},
+
+		onUpdate : function() {
+			if (!this.fixed) {
+				this.update();
+			}
+		},
+
+		afterClose: function (opts) {
+			// Remove overlay if exists and fancyBox is not opening
+			// (e.g., it is not being open using afterClose callback)
+			//if (this.overlay && !F.isActive) {
+			if (this.overlay && !F.coming) {
+				this.overlay.fadeOut(opts.speedOut, $.proxy( this.close, this ));
+			}
+		}
+	};
+
+	/*
+	 *	Title helper
+	 */
+
+	F.helpers.title = {
+		defaults : {
+			type     : 'float', // 'float', 'inside', 'outside' or 'over',
+			position : 'bottom' // 'top' or 'bottom'
+		},
+
+		beforeShow: function (opts) {
+			var current = F.current,
+				text    = current.title,
+				type    = opts.type,
+				title,
+				target;
+
+			if ($.isFunction(text)) {
+				text = text.call(current.element, current);
+			}
+
+			if (!isString(text) || $.trim(text) === '') {
+				return;
+			}
+
+			title = $('<div class="fancybox-title fancybox-title-' + type + '-wrap">' + text + '</div>');
+
+			switch (type) {
+				case 'inside':
+					target = F.skin;
+				break;
+
+				case 'outside':
+					target = F.wrap;
+				break;
+
+				case 'over':
+					target = F.inner;
+				break;
+
+				default: // 'float'
+					target = F.skin;
+
+					title.appendTo('body');
+
+					if (IE) {
+						title.width( title.width() );
+					}
+
+					title.wrapInner('<span class="child"></span>');
+
+					//Increase bottom margin so this title will also fit into viewport
+					F.current.margin[2] += Math.abs( getScalar(title.css('margin-bottom')) );
+				break;
+			}
+
+			title[ (opts.position === 'top' ? 'prependTo'  : 'appendTo') ](target);
+		}
+	};
+
+	// jQuery plugin initialization
+	$.fn.fancybox = function (options) {
+		var index,
+			that     = $(this),
+			selector = this.selector || '',
+			run      = function(e) {
+				var what = $(this).blur(), idx = index, relType, relVal;
+
+				if (!(e.ctrlKey || e.altKey || e.shiftKey || e.metaKey) && !what.is('.fancybox-wrap')) {
+					relType = options.groupAttr || 'data-fancybox-group';
+					relVal  = what.attr(relType);
+
+					if (!relVal) {
+						relType = 'rel';
+						relVal  = what.get(0)[ relType ];
+					}
+
+					if (relVal && relVal !== '' && relVal !== 'nofollow') {
+						what = selector.length ? $(selector) : that;
+						what = what.filter('[' + relType + '="' + relVal + '"]');
+						idx  = what.index(this);
+					}
+
+					options.index = idx;
+
+					// Stop an event from bubbling if everything is fine
+					if (F.open(what, options) !== false) {
+						e.preventDefault();
+					}
+				}
+			};
+
+		options = options || {};
+		index   = options.index || 0;
+
+		if (!selector || options.live === false) {
+			that.unbind('click.fb-start').bind('click.fb-start', run);
+
+		} else {
+			D.undelegate(selector, 'click.fb-start').delegate(selector + ":not('.fancybox-item, .fancybox-nav')", 'click.fb-start', run);
+		}
+
+		this.filter('[data-fancybox-start=1]').trigger('click');
+
+		return this;
+	};
+
+	// Tests that need a body at doc ready
+	D.ready(function() {
+		var w1, w2;
+
+		if ( $.scrollbarWidth === undefined ) {
+			// http://benalman.com/projects/jquery-misc-plugins/#scrollbarwidth
+			$.scrollbarWidth = function() {
+				var parent = $('<div style="width:50px;height:50px;overflow:auto"><div/></div>').appendTo('body'),
+					child  = parent.children(),
+					width  = child.innerWidth() - child.height( 99 ).innerWidth();
+
+				parent.remove();
+
+				return width;
+			};
+		}
+
+		if ( $.support.fixedPosition === undefined ) {
+			$.support.fixedPosition = (function() {
+				var elem  = $('<div style="position:fixed;top:20px;"></div>').appendTo('body'),
+					fixed = ( elem[0].offsetTop === 20 || elem[0].offsetTop === 15 );
+
+				elem.remove();
+
+				return fixed;
+			}());
+		}
+
+		$.extend(F.defaults, {
+			scrollbarWidth : $.scrollbarWidth(),
+			fixed  : $.support.fixedPosition,
+			parent : $('body')
+		});
+
+		//Get real width of page scroll-bar
+		w1 = $(window).width();
+
+		H.addClass('fancybox-lock-test');
+
+		w2 = $(window).width();
+
+		H.removeClass('fancybox-lock-test');
+
+		$("<style type='text/css'>.fancybox-margin{margin-right:" + (w2 - w1) + "px;}</style>").appendTo("head");
+	});
+
+}(window, document, jQuery));
Index: extensions/Slim/js/jquery.jcarousel.js
===================================================================
--- extensions/Slim/js/jquery.jcarousel.js	(revision 28543)
+++ 	(revision )
@@ -1,1396 +1,0 @@
-/*! jCarousel - v0.3.0 - 2013-11-22
-* http://sorgalla.com/jcarousel
-* Copyright (c) 2013 Jan Sorgalla; Licensed MIT */
-(function($) {
-    'use strict';
-
-    var jCarousel = $.jCarousel = {};
-
-    jCarousel.version = '0.3.0';
-
-    var rRelativeTarget = /^([+\-]=)?(.+)$/;
-
-    jCarousel.parseTarget = function(target) {
-        var relative = false,
-            parts    = typeof target !== 'object' ?
-                           rRelativeTarget.exec(target) :
-                           null;
-
-        if (parts) {
-            target = parseInt(parts[2], 10) || 0;
-
-            if (parts[1]) {
-                relative = true;
-                if (parts[1] === '-=') {
-                    target *= -1;
-                }
-            }
-        } else if (typeof target !== 'object') {
-            target = parseInt(target, 10) || 0;
-        }
-
-        return {
-            target: target,
-            relative: relative
-        };
-    };
-
-    jCarousel.detectCarousel = function(element) {
-        var carousel;
-
-        while (element.length > 0) {
-            carousel = element.filter('[data-jcarousel]');
-
-            if (carousel.length > 0) {
-                return carousel;
-            }
-
-            carousel = element.find('[data-jcarousel]');
-
-            if (carousel.length > 0) {
-                return carousel;
-            }
-
-            element = element.parent();
-        }
-
-        return null;
-    };
-
-    jCarousel.base = function(pluginName) {
-        return {
-            version:  jCarousel.version,
-            _options:  {},
-            _element:  null,
-            _carousel: null,
-            _init:     $.noop,
-            _create:   $.noop,
-            _destroy:  $.noop,
-            _reload:   $.noop,
-            create: function() {
-                this._element
-                    .attr('data-' + pluginName.toLowerCase(), true)
-                    .data(pluginName, this);
-
-                if (false === this._trigger('create')) {
-                    return this;
-                }
-
-                this._create();
-
-                this._trigger('createend');
-
-                return this;
-            },
-            destroy: function() {
-                if (false === this._trigger('destroy')) {
-                    return this;
-                }
-
-                this._destroy();
-
-                this._trigger('destroyend');
-
-                this._element
-                    .removeData(pluginName)
-                    .removeAttr('data-' + pluginName.toLowerCase());
-
-                return this;
-            },
-            reload: function(options) {
-                if (false === this._trigger('reload')) {
-                    return this;
-                }
-
-                if (options) {
-                    this.options(options);
-                }
-
-                this._reload();
-
-                this._trigger('reloadend');
-
-                return this;
-            },
-            element: function() {
-                return this._element;
-            },
-            options: function(key, value) {
-                if (arguments.length === 0) {
-                    return $.extend({}, this._options);
-                }
-
-                if (typeof key === 'string') {
-                    if (typeof value === 'undefined') {
-                        return typeof this._options[key] === 'undefined' ?
-                                null :
-                                this._options[key];
-                    }
-
-                    this._options[key] = value;
-                } else {
-                    this._options = $.extend({}, this._options, key);
-                }
-
-                return this;
-            },
-            carousel: function() {
-                if (!this._carousel) {
-                    this._carousel = jCarousel.detectCarousel(this.options('carousel') || this._element);
-
-                    if (!this._carousel) {
-                        $.error('Could not detect carousel for plugin "' + pluginName + '"');
-                    }
-                }
-
-                return this._carousel;
-            },
-            _trigger: function(type, element, data) {
-                var event,
-                    defaultPrevented = false;
-
-                data = [this].concat(data || []);
-
-                (element || this._element).each(function() {
-                    event = $.Event((pluginName + ':' + type).toLowerCase());
-
-                    $(this).trigger(event, data);
-
-                    if (event.isDefaultPrevented()) {
-                        defaultPrevented = true;
-                    }
-                });
-
-                return !defaultPrevented;
-            }
-        };
-    };
-
-    jCarousel.plugin = function(pluginName, pluginPrototype) {
-        var Plugin = $[pluginName] = function(element, options) {
-            this._element = $(element);
-            this.options(options);
-
-            this._init();
-            this.create();
-        };
-
-        Plugin.fn = Plugin.prototype = $.extend(
-            {},
-            jCarousel.base(pluginName),
-            pluginPrototype
-        );
-
-        $.fn[pluginName] = function(options) {
-            var args        = Array.prototype.slice.call(arguments, 1),
-                returnValue = this;
-
-            if (typeof options === 'string') {
-                this.each(function() {
-                    var instance = $(this).data(pluginName);
-
-                    if (!instance) {
-                        return $.error(
-                            'Cannot call methods on ' + pluginName + ' prior to initialization; ' +
-                            'attempted to call method "' + options + '"'
-                        );
-                    }
-
-                    if (!$.isFunction(instance[options]) || options.charAt(0) === '_') {
-                        return $.error(
-                            'No such method "' + options + '" for ' + pluginName + ' instance'
-                        );
-                    }
-
-                    var methodValue = instance[options].apply(instance, args);
-
-                    if (methodValue !== instance && typeof methodValue !== 'undefined') {
-                        returnValue = methodValue;
-                        return false;
-                    }
-                });
-            } else {
-                this.each(function() {
-                    var instance = $(this).data(pluginName);
-
-                    if (instance instanceof Plugin) {
-                        instance.reload(options);
-                    } else {
-                        new Plugin(this, options);
-                    }
-                });
-            }
-
-            return returnValue;
-        };
-
-        return Plugin;
-    };
-}(jQuery));
-
-(function($, window) {
-    'use strict';
-
-    var toFloat = function(val) {
-        return parseFloat(val) || 0;
-    };
-
-    $.jCarousel.plugin('jcarousel', {
-        animating:   false,
-        tail:        0,
-        inTail:      false,
-        resizeTimer: null,
-        lt:          null,
-        vertical:    false,
-        rtl:         false,
-        circular:    false,
-        underflow:   false,
-        relative:    false,
-
-        _options: {
-            list: function() {
-                return this.element().children().eq(0);
-            },
-            items: function() {
-                return this.list().children();
-            },
-            animation:   400,
-            transitions: false,
-            wrap:        null,
-            vertical:    null,
-            rtl:         null,
-            center:      false
-        },
-
-        // Protected, don't access directly
-        _list:         null,
-        _items:        null,
-        _target:       null,
-        _first:        null,
-        _last:         null,
-        _visible:      null,
-        _fullyvisible: null,
-        _init: function() {
-            var self = this;
-
-            this.onWindowResize = function() {
-                if (self.resizeTimer) {
-                    clearTimeout(self.resizeTimer);
-                }
-
-                self.resizeTimer = setTimeout(function() {
-                    self.reload();
-                }, 100);
-            };
-
-            return this;
-        },
-        _create: function() {
-            this._reload();
-
-            $(window).on('resize.jcarousel', this.onWindowResize);
-        },
-        _destroy: function() {
-            $(window).off('resize.jcarousel', this.onWindowResize);
-        },
-        _reload: function() {
-            this.vertical = this.options('vertical');
-
-            if (this.vertical == null) {
-                this.vertical = this.list().height() > this.list().width();
-            }
-
-            this.rtl = this.options('rtl');
-
-            if (this.rtl == null) {
-                this.rtl = (function(element) {
-                    if (('' + element.attr('dir')).toLowerCase() === 'rtl') {
-                        return true;
-                    }
-
-                    var found = false;
-
-                    element.parents('[dir]').each(function() {
-                        if ((/rtl/i).test($(this).attr('dir'))) {
-                            found = true;
-                            return false;
-                        }
-                    });
-
-                    return found;
-                }(this._element));
-            }
-
-            this.lt = this.vertical ? 'top' : 'left';
-
-            // Ensure before closest() call
-            this.relative = this.list().css('position') === 'relative';
-
-            // Force list and items reload
-            this._list  = null;
-            this._items = null;
-
-            var item = this._target && this.index(this._target) >= 0 ?
-                           this._target :
-                           this.closest();
-
-            // _prepare() needs this here
-            this.circular  = this.options('wrap') === 'circular';
-            this.underflow = false;
-
-            var props = {'left': 0, 'top': 0};
-
-            if (item.length > 0) {
-                this._prepare(item);
-                this.list().find('[data-jcarousel-clone]').remove();
-
-                // Force items reload
-                this._items = null;
-
-                this.underflow = this._fullyvisible.length >= this.items().length;
-                this.circular  = this.circular && !this.underflow;
-
-                props[this.lt] = this._position(item) + 'px';
-            }
-
-            this.move(props);
-
-            return this;
-        },
-        list: function() {
-            if (this._list === null) {
-                var option = this.options('list');
-                this._list = $.isFunction(option) ? option.call(this) : this._element.find(option);
-            }
-
-            return this._list;
-        },
-        items: function() {
-            if (this._items === null) {
-                var option = this.options('items');
-                this._items = ($.isFunction(option) ? option.call(this) : this.list().find(option)).not('[data-jcarousel-clone]');
-            }
-
-            return this._items;
-        },
-        index: function(item) {
-            return this.items().index(item);
-        },
-        closest: function() {
-            var self    = this,
-                pos     = this.list().position()[this.lt],
-                closest = $(), // Ensure we're returning a jQuery instance
-                stop    = false,
-                lrb     = this.vertical ? 'bottom' : (this.rtl && !this.relative ? 'left' : 'right'),
-                width;
-
-            if (this.rtl && this.relative && !this.vertical) {
-                pos += this.list().width() - this.clipping();
-            }
-
-            this.items().each(function() {
-                closest = $(this);
-
-                if (stop) {
-                    return false;
-                }
-
-                var dim = self.dimension(closest);
-
-                pos += dim;
-
-                if (pos >= 0) {
-                    width = dim - toFloat(closest.css('margin-' + lrb));
-
-                    if ((Math.abs(pos) - dim + (width / 2)) <= 0) {
-                        stop = true;
-                    } else {
-                        return false;
-                    }
-                }
-            });
-
-
-            return closest;
-        },
-        target: function() {
-            return this._target;
-        },
-        first: function() {
-            return this._first;
-        },
-        last: function() {
-            return this._last;
-        },
-        visible: function() {
-            return this._visible;
-        },
-        fullyvisible: function() {
-            return this._fullyvisible;
-        },
-        hasNext: function() {
-            if (false === this._trigger('hasnext')) {
-                return true;
-            }
-
-            var wrap = this.options('wrap'),
-                end = this.items().length - 1;
-
-            return end >= 0 &&
-                ((wrap && wrap !== 'first') ||
-                    (this.index(this._last) < end) ||
-                    (this.tail && !this.inTail)) ? true : false;
-        },
-        hasPrev: function() {
-            if (false === this._trigger('hasprev')) {
-                return true;
-            }
-
-            var wrap = this.options('wrap');
-
-            return this.items().length > 0 &&
-                ((wrap && wrap !== 'last') ||
-                    (this.index(this._first) > 0) ||
-                    (this.tail && this.inTail)) ? true : false;
-        },
-        clipping: function() {
-            return this._element['inner' + (this.vertical ? 'Height' : 'Width')]();
-        },
-        dimension: function(element) {
-            return element['outer' + (this.vertical ? 'Height' : 'Width')](true);
-        },
-        scroll: function(target, animate, callback) {
-            if (this.animating) {
-                return this;
-            }
-
-            if (false === this._trigger('scroll', null, [target, animate])) {
-                return this;
-            }
-
-            if ($.isFunction(animate)) {
-                callback = animate;
-                animate  = true;
-            }
-
-            var parsed = $.jCarousel.parseTarget(target);
-
-            if (parsed.relative) {
-                var end    = this.items().length - 1,
-                    scroll = Math.abs(parsed.target),
-                    wrap   = this.options('wrap'),
-                    current,
-                    first,
-                    index,
-                    start,
-                    curr,
-                    isVisible,
-                    props,
-                    i;
-
-                if (parsed.target > 0) {
-                    var last = this.index(this._last);
-
-                    if (last >= end && this.tail) {
-                        if (!this.inTail) {
-                            this._scrollTail(animate, callback);
-                        } else {
-                            if (wrap === 'both' || wrap === 'last') {
-                                this._scroll(0, animate, callback);
-                            } else {
-                                if ($.isFunction(callback)) {
-                                    callback.call(this, false);
-                                }
-                            }
-                        }
-                    } else {
-                        current = this.index(this._target);
-
-                        if ((this.underflow && current === end && (wrap === 'circular' || wrap === 'both' || wrap === 'last')) ||
-                            (!this.underflow && last === end && (wrap === 'both' || wrap === 'last'))) {
-                            this._scroll(0, animate, callback);
-                        } else {
-                            index = current + scroll;
-
-                            if (this.circular && index > end) {
-                                i = end;
-                                curr = this.items().get(-1);
-
-                                while (i++ < index) {
-                                    curr = this.items().eq(0);
-                                    isVisible = this._visible.index(curr) >= 0;
-
-                                    if (isVisible) {
-                                        curr.after(curr.clone(true).attr('data-jcarousel-clone', true));
-                                    }
-
-                                    this.list().append(curr);
-
-                                    if (!isVisible) {
-                                        props = {};
-                                        props[this.lt] = this.dimension(curr);
-                                        this.moveBy(props);
-                                    }
-
-                                    // Force items reload
-                                    this._items = null;
-                                }
-
-                                this._scroll(curr, animate, callback);
-                            } else {
-                                this._scroll(Math.min(index, end), animate, callback);
-                            }
-                        }
-                    }
-                } else {
-                    if (this.inTail) {
-                        this._scroll(Math.max((this.index(this._first) - scroll) + 1, 0), animate, callback);
-                    } else {
-                        first  = this.index(this._first);
-                        current = this.index(this._target);
-                        start  = this.underflow ? current : first;
-                        index  = start - scroll;
-
-                        if (start <= 0 && ((this.underflow && wrap === 'circular') || wrap === 'both' || wrap === 'first')) {
-                            this._scroll(end, animate, callback);
-                        } else {
-                            if (this.circular && index < 0) {
-                                i    = index;
-                                curr = this.items().get(0);
-
-                                while (i++ < 0) {
-                                    curr = this.items().eq(-1);
-                                    isVisible = this._visible.index(curr) >= 0;
-
-                                    if (isVisible) {
-                                        curr.after(curr.clone(true).attr('data-jcarousel-clone', true));
-                                    }
-
-                                    this.list().prepend(curr);
-
-                                    // Force items reload
-                                    this._items = null;
-
-                                    var dim = this.dimension(curr);
-
-                                    props = {};
-                                    props[this.lt] = -dim;
-                                    this.moveBy(props);
-
-                                }
-
-                                this._scroll(curr, animate, callback);
-                            } else {
-                                this._scroll(Math.max(index, 0), animate, callback);
-                            }
-                        }
-                    }
-                }
-            } else {
-                this._scroll(parsed.target, animate, callback);
-            }
-
-            this._trigger('scrollend');
-
-            return this;
-        },
-        moveBy: function(properties, opts) {
-            var position = this.list().position(),
-                multiplier = 1,
-                correction = 0;
-
-            if (this.rtl && !this.vertical) {
-                multiplier = -1;
-
-                if (this.relative) {
-                    correction = this.list().width() - this.clipping();
-                }
-            }
-
-            if (properties.left) {
-                properties.left = (position.left + correction + toFloat(properties.left) * multiplier) + 'px';
-            }
-
-            if (properties.top) {
-                properties.top = (position.top + correction + toFloat(properties.top) * multiplier) + 'px';
-            }
-
-            return this.move(properties, opts);
-        },
-        move: function(properties, opts) {
-            opts = opts || {};
-
-            var option       = this.options('transitions'),
-                transitions  = !!option,
-                transforms   = !!option.transforms,
-                transforms3d = !!option.transforms3d,
-                duration     = opts.duration || 0,
-                list         = this.list();
-
-            if (!transitions && duration > 0) {
-                list.animate(properties, opts);
-                return;
-            }
-
-            var complete = opts.complete || $.noop,
-                css = {};
-
-            if (transitions) {
-                var backup = list.css(['transitionDuration', 'transitionTimingFunction', 'transitionProperty']),
-                    oldComplete = complete;
-
-                complete = function() {
-                    $(this).css(backup);
-                    oldComplete.call(this);
-                };
-                css = {
-                    transitionDuration: (duration > 0 ? duration / 1000 : 0) + 's',
-                    transitionTimingFunction: option.easing || opts.easing,
-                    transitionProperty: duration > 0 ? (function() {
-                        if (transforms || transforms3d) {
-                            // We have to use 'all' because jQuery doesn't prefix
-                            // css values, like transition-property: transform;
-                            return 'all';
-                        }
-
-                        return properties.left ? 'left' : 'top';
-                    })() : 'none',
-                    transform: 'none'
-                };
-            }
-
-            if (transforms3d) {
-                css.transform = 'translate3d(' + (properties.left || 0) + ',' + (properties.top || 0) + ',0)';
-            } else if (transforms) {
-                css.transform = 'translate(' + (properties.left || 0) + ',' + (properties.top || 0) + ')';
-            } else {
-                $.extend(css, properties);
-            }
-
-            if (transitions && duration > 0) {
-                list.one('transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd', complete);
-            }
-
-            list.css(css);
-
-            if (duration <= 0) {
-                list.each(function() {
-                    complete.call(this);
-                });
-            }
-        },
-        _scroll: function(item, animate, callback) {
-            if (this.animating) {
-                if ($.isFunction(callback)) {
-                    callback.call(this, false);
-                }
-
-                return this;
-            }
-
-            if (typeof item !== 'object') {
-                item = this.items().eq(item);
-            } else if (typeof item.jquery === 'undefined') {
-                item = $(item);
-            }
-
-            if (item.length === 0) {
-                if ($.isFunction(callback)) {
-                    callback.call(this, false);
-                }
-
-                return this;
-            }
-
-            this.inTail = false;
-
-            this._prepare(item);
-
-            var pos     = this._position(item),
-                currPos = this.list().position()[this.lt];
-
-            if (pos === currPos) {
-                if ($.isFunction(callback)) {
-                    callback.call(this, false);
-                }
-
-                return this;
-            }
-
-            var properties = {};
-            properties[this.lt] = pos + 'px';
-
-            this._animate(properties, animate, callback);
-
-            return this;
-        },
-        _scrollTail: function(animate, callback) {
-            if (this.animating || !this.tail) {
-                if ($.isFunction(callback)) {
-                    callback.call(this, false);
-                }
-
-                return this;
-            }
-
-            var pos = this.list().position()[this.lt];
-
-            if (this.rtl && this.relative && !this.vertical) {
-                pos += this.list().width() - this.clipping();
-            }
-
-            if (this.rtl && !this.vertical) {
-                pos += this.tail;
-            } else {
-                pos -= this.tail;
-            }
-
-            this.inTail = true;
-
-            var properties = {};
-            properties[this.lt] = pos + 'px';
-
-            this._update({
-                target:       this._target.next(),
-                fullyvisible: this._fullyvisible.slice(1).add(this._visible.last())
-            });
-
-            this._animate(properties, animate, callback);
-
-            return this;
-        },
-        _animate: function(properties, animate, callback) {
-            callback = callback || $.noop;
-
-            if (false === this._trigger('animate')) {
-                callback.call(this, false);
-                return this;
-            }
-
-            this.animating = true;
-
-            var animation = this.options('animation'),
-                complete  = $.proxy(function() {
-                    this.animating = false;
-
-                    var c = this.list().find('[data-jcarousel-clone]');
-
-                    if (c.length > 0) {
-                        c.remove();
-                        this._reload();
-                    }
-
-                    this._trigger('animateend');
-
-                    callback.call(this, true);
-                }, this);
-
-            var opts = typeof animation === 'object' ?
-                           $.extend({}, animation) :
-                           {duration: animation},
-                oldComplete = opts.complete || $.noop;
-
-            if (animate === false) {
-                opts.duration = 0;
-            } else if (typeof $.fx.speeds[opts.duration] !== 'undefined') {
-                opts.duration = $.fx.speeds[opts.duration];
-            }
-
-            opts.complete = function() {
-                complete();
-                oldComplete.call(this);
-            };
-
-            this.move(properties, opts);
-
-            return this;
-        },
-        _prepare: function(item) {
-            var index  = this.index(item),
-                idx    = index,
-                wh     = this.dimension(item),
-                clip   = this.clipping(),
-                lrb    = this.vertical ? 'bottom' : (this.rtl ? 'left'  : 'right'),
-                center = this.options('center'),
-                update = {
-                    target:       item,
-                    first:        item,
-                    last:         item,
-                    visible:      item,
-                    fullyvisible: wh <= clip ? item : $()
-                },
-                curr,
-                isVisible,
-                margin,
-                dim;
-
-            if (center) {
-                wh /= 2;
-                clip /= 2;
-            }
-
-            if (wh < clip) {
-                while (true) {
-                    curr = this.items().eq(++idx);
-
-                    if (curr.length === 0) {
-                        if (!this.circular) {
-                            break;
-                        }
-
-                        curr = this.items().eq(0);
-
-                        if (item.get(0) === curr.get(0)) {
-                            break;
-                        }
-
-                        isVisible = this._visible.index(curr) >= 0;
-
-                        if (isVisible) {
-                            curr.after(curr.clone(true).attr('data-jcarousel-clone', true));
-                        }
-
-                        this.list().append(curr);
-
-                        if (!isVisible) {
-                            var props = {};
-                            props[this.lt] = this.dimension(curr);
-                            this.moveBy(props);
-                        }
-
-                        // Force items reload
-                        this._items = null;
-                    }
-
-                    dim = this.dimension(curr);
-
-                    if (dim === 0) {
-                        break;
-                    }
-
-                    wh += dim;
-
-                    update.last    = curr;
-                    update.visible = update.visible.add(curr);
-
-                    // Remove right/bottom margin from total width
-                    margin = toFloat(curr.css('margin-' + lrb));
-
-                    if ((wh - margin) <= clip) {
-                        update.fullyvisible = update.fullyvisible.add(curr);
-                    }
-
-                    if (wh >= clip) {
-                        break;
-                    }
-                }
-            }
-
-            if (!this.circular && !center && wh < clip) {
-                idx = index;
-
-                while (true) {
-                    if (--idx < 0) {
-                        break;
-                    }
-
-                    curr = this.items().eq(idx);
-
-                    if (curr.length === 0) {
-                        break;
-                    }
-
-                    dim = this.dimension(curr);
-
-                    if (dim === 0) {
-                        break;
-                    }
-
-                    wh += dim;
-
-                    update.first   = curr;
-                    update.visible = update.visible.add(curr);
-
-                    // Remove right/bottom margin from total width
-                    margin = toFloat(curr.css('margin-' + lrb));
-
-                    if ((wh - margin) <= clip) {
-                        update.fullyvisible = update.fullyvisible.add(curr);
-                    }
-
-                    if (wh >= clip) {
-                        break;
-                    }
-                }
-            }
-
-            this._update(update);
-
-            this.tail = 0;
-
-            if (!center &&
-                this.options('wrap') !== 'circular' &&
-                this.options('wrap') !== 'custom' &&
-                this.index(update.last) === (this.items().length - 1)) {
-
-                // Remove right/bottom margin from total width
-                wh -= toFloat(update.last.css('margin-' + lrb));
-
-                if (wh > clip) {
-                    this.tail = wh - clip;
-                }
-            }
-
-            return this;
-        },
-        _position: function(item) {
-            var first  = this._first,
-                pos    = first.position()[this.lt],
-                center = this.options('center'),
-                centerOffset = center ? (this.clipping() / 2) - (this.dimension(first) / 2) : 0;
-
-            if (this.rtl && !this.vertical) {
-                if (this.relative) {
-                    pos -= this.list().width() - this.dimension(first);
-                } else {
-                    pos -= this.clipping() - this.dimension(first);
-                }
-
-                pos += centerOffset;
-            } else {
-                pos -= centerOffset;
-            }
-
-            if (!center &&
-                (this.index(item) > this.index(first) || this.inTail) &&
-                this.tail) {
-                pos = this.rtl && !this.vertical ? pos - this.tail : pos + this.tail;
-                this.inTail = true;
-            } else {
-                this.inTail = false;
-            }
-
-            return -pos;
-        },
-        _update: function(update) {
-            var self = this,
-                current = {
-                    target:       this._target || $(),
-                    first:        this._first || $(),
-                    last:         this._last || $(),
-                    visible:      this._visible || $(),
-                    fullyvisible: this._fullyvisible || $()
-                },
-                back = this.index(update.first || current.first) < this.index(current.first),
-                key,
-                doUpdate = function(key) {
-                    var elIn  = [],
-                        elOut = [];
-
-                    update[key].each(function() {
-                        if (current[key].index(this) < 0) {
-                            elIn.push(this);
-                        }
-                    });
-
-                    current[key].each(function() {
-                        if (update[key].index(this) < 0) {
-                            elOut.push(this);
-                        }
-                    });
-
-                    if (back) {
-                        elIn = elIn.reverse();
-                    } else {
-                        elOut = elOut.reverse();
-                    }
-
-                    self._trigger(key + 'in', $(elIn));
-                    self._trigger(key + 'out', $(elOut));
-
-                    self['_' + key] = update[key];
-                };
-
-            for (key in update) {
-                doUpdate(key);
-            }
-
-            return this;
-        }
-    });
-}(jQuery, window));
-
-(function($) {
-    'use strict';
-
-    $.jcarousel.fn.scrollIntoView = function(target, animate, callback) {
-        var parsed = $.jCarousel.parseTarget(target),
-            first  = this.index(this._fullyvisible.first()),
-            last   = this.index(this._fullyvisible.last()),
-            index;
-
-        if (parsed.relative) {
-            index = parsed.target < 0 ? Math.max(0, first + parsed.target) : last + parsed.target;
-        } else {
-            index = typeof parsed.target !== 'object' ? parsed.target : this.index(parsed.target);
-        }
-
-        if (index < first) {
-            return this.scroll(index, animate, callback);
-        }
-
-        if (index >= first && index <= last) {
-            if ($.isFunction(callback)) {
-                callback.call(this, false);
-            }
-
-            return this;
-        }
-
-        var items = this.items(),
-            clip = this.clipping(),
-            lrb  = this.vertical ? 'bottom' : (this.rtl ? 'left'  : 'right'),
-            wh   = 0,
-            curr;
-
-        while (true) {
-            curr = items.eq(index);
-
-            if (curr.length === 0) {
-                break;
-            }
-
-            wh += this.dimension(curr);
-
-            if (wh >= clip) {
-                var margin = parseFloat(curr.css('margin-' + lrb)) || 0;
-                if ((wh - margin) !== clip) {
-                    index++;
-                }
-                break;
-            }
-
-            if (index <= 0) {
-                break;
-            }
-
-            index--;
-        }
-
-        return this.scroll(index, animate, callback);
-    };
-}(jQuery));
-
-(function($) {
-    'use strict';
-
-    $.jCarousel.plugin('jcarouselControl', {
-        _options: {
-            target: '+=1',
-            event:  'click',
-            method: 'scroll'
-        },
-        _active: null,
-        _init: function() {
-            this.onDestroy = $.proxy(function() {
-                this._destroy();
-                this.carousel()
-                    .one('jcarousel:createend', $.proxy(this._create, this));
-            }, this);
-            this.onReload = $.proxy(this._reload, this);
-            this.onEvent = $.proxy(function(e) {
-                e.preventDefault();
-
-                var method = this.options('method');
-
-                if ($.isFunction(method)) {
-                    method.call(this);
-                } else {
-                    this.carousel()
-                        .jcarousel(this.options('method'), this.options('target'));
-                }
-            }, this);
-        },
-        _create: function() {
-            this.carousel()
-                .one('jcarousel:destroy', this.onDestroy)
-                .on('jcarousel:reloadend jcarousel:scrollend', this.onReload);
-
-            this._element
-                .on(this.options('event') + '.jcarouselcontrol', this.onEvent);
-
-            this._reload();
-        },
-        _destroy: function() {
-            this._element
-                .off('.jcarouselcontrol', this.onEvent);
-
-            this.carousel()
-                .off('jcarousel:destroy', this.onDestroy)
-                .off('jcarousel:reloadend jcarousel:scrollend', this.onReload);
-        },
-        _reload: function() {
-            var parsed   = $.jCarousel.parseTarget(this.options('target')),
-                carousel = this.carousel(),
-                active;
-
-            if (parsed.relative) {
-                active = carousel
-                    .jcarousel(parsed.target > 0 ? 'hasNext' : 'hasPrev');
-            } else {
-                var target = typeof parsed.target !== 'object' ?
-                                carousel.jcarousel('items').eq(parsed.target) :
-                                parsed.target;
-
-                active = carousel.jcarousel('target').index(target) >= 0;
-            }
-
-            if (this._active !== active) {
-                this._trigger(active ? 'active' : 'inactive');
-                this._active = active;
-            }
-
-            return this;
-        }
-    });
-}(jQuery));
-
-(function($) {
-    'use strict';
-
-    $.jCarousel.plugin('jcarouselPagination', {
-        _options: {
-            perPage: null,
-            item: function(page) {
-                return '<a href="#' + page + '">' + page + '</a>';
-            },
-            event:  'click',
-            method: 'scroll'
-        },
-        _pages: {},
-        _items: {},
-        _currentPage: null,
-        _init: function() {
-            this.onDestroy = $.proxy(function() {
-                this._destroy();
-                this.carousel()
-                    .one('jcarousel:createend', $.proxy(this._create, this));
-            }, this);
-            this.onReload = $.proxy(this._reload, this);
-            this.onScroll = $.proxy(this._update, this);
-        },
-        _create: function() {
-            this.carousel()
-                .one('jcarousel:destroy', this.onDestroy)
-                .on('jcarousel:reloadend', this.onReload)
-                .on('jcarousel:scrollend', this.onScroll);
-
-            this._reload();
-        },
-        _destroy: function() {
-            this._clear();
-
-            this.carousel()
-                .off('jcarousel:destroy', this.onDestroy)
-                .off('jcarousel:reloadend', this.onReload)
-                .off('jcarousel:scrollend', this.onScroll);
-        },
-        _reload: function() {
-            var perPage = this.options('perPage');
-
-            this._pages = {};
-            this._items = {};
-
-            // Calculate pages
-            if ($.isFunction(perPage)) {
-                perPage = perPage.call(this);
-            }
-
-            if (perPage == null) {
-                this._pages = this._calculatePages();
-            } else {
-                var pp    = parseInt(perPage, 10) || 0,
-                    items = this.carousel().jcarousel('items'),
-                    page  = 1,
-                    i     = 0,
-                    curr;
-
-                while (true) {
-                    curr = items.eq(i++);
-
-                    if (curr.length === 0) {
-                        break;
-                    }
-
-                    if (!this._pages[page]) {
-                        this._pages[page] = curr;
-                    } else {
-                        this._pages[page] = this._pages[page].add(curr);
-                    }
-
-                    if (i % pp === 0) {
-                        page++;
-                    }
-                }
-            }
-
-            this._clear();
-
-            var self     = this,
-                carousel = this.carousel().data('jcarousel'),
-                element  = this._element,
-                item     = this.options('item');
-
-            $.each(this._pages, function(page, carouselItems) {
-                var currItem = self._items[page] = $(item.call(self, page, carouselItems));
-
-                currItem.on(self.options('event') + '.jcarouselpagination', $.proxy(function() {
-                    var target = carouselItems.eq(0);
-
-                    // If circular wrapping enabled, ensure correct scrolling direction
-                    if (carousel.circular) {
-                        var currentIndex = carousel.index(carousel.target()),
-                            newIndex     = carousel.index(target);
-
-                        if (parseFloat(page) > parseFloat(self._currentPage)) {
-                            if (newIndex < currentIndex) {
-                                target = '+=' + (carousel.items().length - currentIndex + newIndex);
-                            }
-                        } else {
-                            if (newIndex > currentIndex) {
-                                target = '-=' + (currentIndex + (carousel.items().length - newIndex));
-                            }
-                        }
-                    }
-
-                    carousel[this.options('method')](target);
-                }, self));
-
-                element.append(currItem);
-            });
-
-            this._update();
-        },
-        _update: function() {
-            var target = this.carousel().jcarousel('target'),
-                currentPage;
-
-            $.each(this._pages, function(page, carouselItems) {
-                carouselItems.each(function() {
-                    if (target.is(this)) {
-                        currentPage = page;
-                        return false;
-                    }
-                });
-
-                if (currentPage) {
-                    return false;
-                }
-            });
-
-            if (this._currentPage !== currentPage) {
-                this._trigger('inactive', this._items[this._currentPage]);
-                this._trigger('active', this._items[currentPage]);
-            }
-
-            this._currentPage = currentPage;
-        },
-        items: function() {
-            return this._items;
-        },
-        _clear: function() {
-            this._element.empty();
-            this._currentPage = null;
-        },
-        _calculatePages: function() {
-            var carousel = this.carousel().data('jcarousel'),
-                items    = carousel.items(),
-                clip     = carousel.clipping(),
-                wh       = 0,
-                idx      = 0,
-                page     = 1,
-                pages    = {},
-                curr;
-
-            while (true) {
-                curr = items.eq(idx++);
-
-                if (curr.length === 0) {
-                    break;
-                }
-
-                if (!pages[page]) {
-                    pages[page] = curr;
-                } else {
-                    pages[page] = pages[page].add(curr);
-                }
-
-                wh += carousel.dimension(curr);
-
-                if (wh >= clip) {
-                    page++;
-                    wh = 0;
-                }
-            }
-
-            return pages;
-        }
-    });
-}(jQuery));
-
-(function($) {
-    'use strict';
-
-    $.jCarousel.plugin('jcarouselAutoscroll', {
-        _options: {
-            target:    '+=1',
-            interval:  3000,
-            autostart: true
-        },
-        _timer: null,
-        _init: function () {
-            this.onDestroy = $.proxy(function() {
-                this._destroy();
-                this.carousel()
-                    .one('jcarousel:createend', $.proxy(this._create, this));
-            }, this);
-
-            this.onAnimateEnd = $.proxy(this.start, this);
-        },
-        _create: function() {
-            this.carousel()
-                .one('jcarousel:destroy', this.onDestroy);
-
-            if (this.options('autostart')) {
-                this.start();
-            }
-        },
-        _destroy: function() {
-            this.stop();
-            this.carousel()
-                .off('jcarousel:destroy', this.onDestroy);
-        },
-        start: function() {
-            this.stop();
-
-            this.carousel()
-                .one('jcarousel:animateend', this.onAnimateEnd);
-
-            this._timer = setTimeout($.proxy(function() {
-                this.carousel().jcarousel('scroll', this.options('target'));
-            }, this), this.options('interval'));
-
-            return this;
-        },
-        stop: function() {
-            if (this._timer) {
-                this._timer = clearTimeout(this._timer);
-            }
-
-            this.carousel()
-                .off('jcarousel:animateend', this.onAnimateEnd);
-
-            return this;
-        }
-    });
-}(jQuery));
Index: extensions/Slim/js/jquery.kinetic.min.js
===================================================================
--- extensions/Slim/js/jquery.kinetic.min.js	(revision 28556)
+++ extensions/Slim/js/jquery.kinetic.min.js	(revision 28556)
@@ -0,0 +1,3 @@
+/*! jquery.kinetic - v1.8.2 - 2013-03-23 http://the-taylors.org/jquery.kinetic 
+ * Copyright (c) 2013 Dave Taylor; Licensed MIT */
+(function(t){"use strict";var e={cursor:"move",decelerate:!0,triggerHardware:!1,y:!0,x:!0,slowdown:.9,maxvelocity:40,throttleFPS:60,movingClass:{up:"kinetic-moving-up",down:"kinetic-moving-down",left:"kinetic-moving-left",right:"kinetic-moving-right"},deceleratingClass:{up:"kinetic-decelerating-up",down:"kinetic-decelerating-down",left:"kinetic-decelerating-left",right:"kinetic-decelerating-right"}},n="kinetic-settings",i="kinetic-active";window.requestAnimationFrame||(window.requestAnimationFrame=function(){return window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)}}()),t.support=t.support||{},t.extend(t.support,{touch:"ontouchend"in document});var o=function(){return!1},c=function(t,e){return 0===Math.floor(Math.abs(t))?0:t*e},l=function(t,e){var n=t;return t>0?t>e&&(n=e):0-e>t&&(n=0-e),n},s=function(t,e){this.removeClass(t.movingClass.up).removeClass(t.movingClass.down).removeClass(t.movingClass.left).removeClass(t.movingClass.right).removeClass(t.deceleratingClass.up).removeClass(t.deceleratingClass.down).removeClass(t.deceleratingClass.left).removeClass(t.deceleratingClass.right),t.velocity>0&&this.addClass(e.right),0>t.velocity&&this.addClass(e.left),t.velocityY>0&&this.addClass(e.down),0>t.velocityY&&this.addClass(e.up)},a=function(t,e){e.velocity=0,e.velocityY=0,e.decelerate=!0,"function"==typeof e.stopped&&e.stopped.call(t,e)},r=function(t,e){var n=t[0];e.x&&n.scrollWidth>0?(n.scrollLeft=e.scrollLeft=n.scrollLeft+e.velocity,Math.abs(e.velocity)>0&&(e.velocity=e.decelerate?c(e.velocity,e.slowdown):e.velocity)):e.velocity=0,e.y&&n.scrollHeight>0?(n.scrollTop=e.scrollTop=n.scrollTop+e.velocityY,Math.abs(e.velocityY)>0&&(e.velocityY=e.decelerate?c(e.velocityY,e.slowdown):e.velocityY)):e.velocityY=0,s.call(t,e,e.deceleratingClass),"function"==typeof e.moved&&e.moved.call(t,e),Math.abs(e.velocity)>0||Math.abs(e.velocityY)>0?window.requestAnimationFrame(function(){r(t,e)}):a(t,e)},u=function(e){var i=t.kinetic.callMethods[e],o=Array.prototype.slice.call(arguments);i&&this.each(function(){var e=o.slice(1),c=t(this).data(n);e.unshift(c),i.apply(this,e)})},v=function(e,n){e[0],t.support.touch?e.bind("touchstart",n.events.touchStart).bind("touchend",n.events.inputEnd).bind("touchmove",n.events.touchMove):e.mousedown(n.events.inputDown).mouseup(n.events.inputEnd).mousemove(n.events.inputMove),e.click(n.events.inputClick).scroll(n.events.scroll).bind("selectstart",o).bind("dragstart",n.events.dragStart)},d=function(e,n){e[0],t.support.touch?e.unbind("touchstart",n.events.touchStart).unbind("touchend",n.events.inputEnd).unbind("touchmove",n.events.touchMove):e.unbind("mousedown",n.events.inputDown).unbind("mouseup",n.events.inputEnd).unbind("mousemove",n.events.inputMove).unbind("scroll",n.events.scroll),e.unbind("click",n.events.inputClick).unbind("selectstart",o),e.unbind("dragstart",n.events.dragStart)},f=function(o){this.addClass(i).each(function(){var i=this,c=t(this);if(!c.data(n)){var a,u,d,f,p=t.extend({},e,o),m=!1,h=!1,g=!1,w=1e3/p.throttleFPS;p.velocity=0,p.velocityY=0;var y=function(){a=!1,u=!1,g=!1};t(document).mouseup(y).click(y);var C=function(){p.velocity=l(m-a,p.maxvelocity),p.velocityY=l(h-u,p.maxvelocity)},b=function(e){return t.isFunction(p.filterTarget)?p.filterTarget.call(i,e)!==!1:!0},k=function(t,e){g=!0,p.velocity=m=0,p.velocityY=h=0,a=t,u=e},Y=function(){a&&m&&p.decelerate===!1&&(p.decelerate=!0,C(),a=m=g=!1,r(c,p))},D=function(e,n){(!d||new Date>new Date(d.getTime()+w))&&(d=new Date,g&&(a||u)&&(f&&(t(f).blur(),f=null,c.focus()),p.decelerate=!1,p.velocity=p.velocityY=0,c[0].scrollLeft=p.scrollLeft=p.x?c[0].scrollLeft-(e-a):c[0].scrollLeft,c[0].scrollTop=p.scrollTop=p.y?c[0].scrollTop-(n-u):c[0].scrollTop,m=a,h=u,a=e,u=n,C(),s.call(c,p,p.movingClass),"function"==typeof p.moved&&p.moved.call(c,p)))};p.events={touchStart:function(t){var e;b(t.target)&&(e=t.originalEvent.touches[0],k(e.clientX,e.clientY),t.stopPropagation())},touchMove:function(t){var e;g&&(e=t.originalEvent.touches[0],D(e.clientX,e.clientY),t.preventDefault&&t.preventDefault())},inputDown:function(t){b(t.target)&&(k(t.clientX,t.clientY),f=t.target,"IMG"===t.target.nodeName&&t.preventDefault(),t.stopPropagation())},inputEnd:function(t){Y(),f=null,t.preventDefault&&t.preventDefault()},inputMove:function(t){g&&(D(t.clientX,t.clientY),t.preventDefault&&t.preventDefault())},scroll:function(t){"function"==typeof p.moved&&p.moved.call(c,p),t.preventDefault&&t.preventDefault()},inputClick:function(t){return Math.abs(p.velocity)>0?(t.preventDefault(),!1):void 0},dragStart:function(){return f?!1:void 0}},v(c,p),c.data(n,p).css("cursor",p.cursor),p.triggerHardware&&c.css({"-webkit-transform":"translate3d(0,0,0)","-webkit-perspective":"1000","-webkit-backface-visibility":"hidden"})}})};t.kinetic={settingsKey:n,callMethods:{start:function(e,n){var i=t(this);e=t.extend(e,n),e&&(e.decelerate=!1,r(i,e))},end:function(e){t(this),e&&(e.decelerate=!0)},stop:function(e){var n=t(this);a(n,e)},detach:function(e){var n=t(this);d(n,e),n.removeClass(i).css("cursor","")},attach:function(e){var n=t(this);v(n,e),n.addClass(i).css("cursor","move")}}},t.fn.kinetic=function(t){return"string"==typeof t?u.apply(this,arguments):f.call(this,t),this}})(window.jQuery||window.Zepto);
Index: extensions/Slim/js/jquery.mousewheel.min.js
===================================================================
--- extensions/Slim/js/jquery.mousewheel.min.js	(revision 28556)
+++ extensions/Slim/js/jquery.mousewheel.min.js	(revision 28556)
@@ -0,0 +1,8 @@
+/*! Copyright (c) 2013 Brandon Aaron (http://brandon.aaron.sh)
+ * Licensed under the MIT License (LICENSE.txt).
+ *
+ * Version: 3.1.4
+ *
+ * Requires: 1.2.2+
+ */
+(function(e){if(typeof define==="function"&&define.amd){define(["jquery"],e)}else if(typeof exports==="object"){module.exports=e}else{e(jQuery)}})(function(e){function o(t){var n=t||window.event,s=[].slice.call(arguments,1),o=0,u=0,a=0,f=0,l=0,c;t=e.event.fix(n);t.type="mousewheel";if(n.wheelDelta){o=n.wheelDelta}if(n.detail){o=n.detail*-1}a=o;if(n.axis!==undefined&&n.axis===n.HORIZONTAL_AXIS){a=0;u=o*-1}if(n.deltaY){a=n.deltaY*-1;o=a}if(n.deltaX){u=n.deltaX;o=u*-1}if(n.wheelDeltaY!==undefined){a=n.wheelDeltaY}if(n.wheelDeltaX!==undefined){u=n.wheelDeltaX*-1}f=Math.abs(o);if(!r||f<r){r=f}l=Math.max(Math.abs(a),Math.abs(u));if(!i||l<i){i=l}c=o>0?"floor":"ceil";o=Math[c](o/r);u=Math[c](u/i);a=Math[c](a/i);s.unshift(t,o,u,a);return(e.event.dispatch||e.event.handle).apply(this,s)}var t=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"];var n="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"];var r,i;if(e.event.fixHooks){for(var s=t.length;s;){e.event.fixHooks[t[--s]]=e.event.mouseHooks}}e.event.special.mousewheel={setup:function(){if(this.addEventListener){for(var e=n.length;e;){this.addEventListener(n[--e],o,false)}}else{this.onmousewheel=o}},teardown:function(){if(this.removeEventListener){for(var e=n.length;e;){this.removeEventListener(n[--e],o,false)}}else{this.onmousewheel=null}}};e.fn.extend({mousewheel:function(e){return e?this.bind("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.unbind("mousewheel",e)}})})
Index: extensions/Slim/js/jquery.smoothDivScroll-1.3.js
===================================================================
--- extensions/Slim/js/jquery.smoothDivScroll-1.3.js	(revision 28556)
+++ extensions/Slim/js/jquery.smoothDivScroll-1.3.js	(revision 28556)
@@ -0,0 +1,1367 @@
+/*
+ * jQuery SmoothDivScroll 1.3
+ *
+ * Copyright (c) 2013 Thomas Kahn
+ * Licensed under the GPL license.
+ *
+ * http://www.smoothdivscroll.com/
+ *
+ * Depends:
+ * jquery-1.10.2.min.js
+   Please use https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js
+   ...or later
+
+ * jquery-ui-1.10.3.custom.min
+   Make your own custom download at http://jqueryui.com/download.
+   First deselect all components. Then check just "Widget" and "Effects Core".
+   Download the file and put it in your javascript folder.
+
+ * jquery.mousewheel.min.js
+   Used for mousewheel functionality.
+   Download the latest version at https://github.com/brandonaaron/jquery-mousewheel
+ *
+
+ * jquery.kinetic.min.js
+   Used for scrolling by dragging, mainly used on touch devices.
+   Download the latest version at https://github.com/davetayls/jquery.kinetic
+ *
+ */
+(function ($) {
+
+	$.widget("thomaskahn.smoothDivScroll", {
+		// Default options
+		options: {
+			// Classes for elements added by Smooth Div Scroll
+			scrollingHotSpotLeftClass: "scrollingHotSpotLeft", // String
+			scrollingHotSpotRightClass: "scrollingHotSpotRight", // String
+			scrollingHotSpotLeftVisibleClass: "scrollingHotSpotLeftVisible", // String
+			scrollingHotSpotRightVisibleClass: "scrollingHotSpotRightVisible", // String
+			scrollableAreaClass: "scrollableArea", // String
+			scrollWrapperClass: "scrollWrapper", // String
+
+			// Misc settings
+			hiddenOnStart: false, // Boolean
+			getContentOnLoad: {}, // Object
+			countOnlyClass: "", // String
+			startAtElementId: "", // String
+
+			// Hotspot scrolling
+			hotSpotScrolling: true, // Boolean
+			hotSpotScrollingStep: 15, // Pixels
+			hotSpotScrollingInterval: 10, // Milliseconds
+			hotSpotMouseDownSpeedBooster: 3, // Integer
+			visibleHotSpotBackgrounds: "hover", // always, onStart, hover or empty (no visible hotspots)
+			hotSpotsVisibleTime: 5000, // Milliseconds
+			easingAfterHotSpotScrolling: true, // Boolean
+			easingAfterHotSpotScrollingDistance: 10, // Pixels
+			easingAfterHotSpotScrollingDuration: 300, // Milliseconds
+			easingAfterHotSpotScrollingFunction: "easeOutQuart", // String
+
+			// Mousewheel scrolling
+			mousewheelScrolling: "", // vertical, horizontal, allDirections or empty (no mousewheel scrolling) String
+			mousewheelScrollingStep: 70, // Pixels
+			easingAfterMouseWheelScrolling: true, // Boolean
+			easingAfterMouseWheelScrollingDuration: 300, // Milliseconds
+			easingAfterMouseWheelScrollingFunction: "easeOutQuart", // String
+
+			// Manual scrolling (hotspot and/or mousewheel scrolling)
+			manualContinuousScrolling: false, // Boolean
+
+			// Autoscrolling
+			autoScrollingMode: "", // always, onStart or empty (no auto scrolling) String
+			autoScrollingDirection: "endlessLoopRight", // right, left, backAndForth, endlessLoopRight, endlessLoopLeft String
+			autoScrollingStep: 1, // Pixels
+			autoScrollingInterval: 10, // Milliseconds
+
+			// Touch scrolling
+			touchScrolling: false,
+
+			// Easing for when the scrollToElement method is used
+			scrollToAnimationDuration: 1000, // Milliseconds
+			scrollToEasingFunction: "easeOutQuart" // String
+		},
+		_create: function () {
+			var self = this, o = this.options, el = this.element;
+
+			// Create variables for any existing or not existing 
+			// scroller elements on the page.
+			el.data("scrollWrapper", el.find("." + o.scrollWrapperClass));
+			el.data("scrollingHotSpotRight", el.find("." + o.scrollingHotSpotRightClass));
+			el.data("scrollingHotSpotLeft", el.find("." + o.scrollingHotSpotLeftClass));
+			el.data("scrollableArea", el.find("." + o.scrollableAreaClass));
+
+			// Check which elements are already present on the page. 
+			// Create any elements needed by the plugin if
+			// the user hasn't already created them.
+
+			// First detach any present hot spots
+			if (el.data("scrollingHotSpotRight").length > 0) {
+
+				el.data("scrollingHotSpotRight").detach();
+			}
+			if (el.data("scrollingHotSpotLeft").length > 0) {
+
+				el.data("scrollingHotSpotLeft").detach();
+			}
+
+			// Both the scrollable area and the wrapper are missing
+			if (el.data("scrollableArea").length === 0 && el.data("scrollWrapper").length === 0) {
+				el.wrapInner("<div class='" + o.scrollableAreaClass + "'>").wrapInner("<div class='" + o.scrollWrapperClass + "'>");
+
+				el.data("scrollWrapper", el.find("." + o.scrollWrapperClass));
+				el.data("scrollableArea", el.find("." + o.scrollableAreaClass));
+			}
+			// Only the wrapper is missing
+			else if (el.data("scrollWrapper").length === 0) {
+				el.wrapInner("<div class='" + o.scrollWrapperClass + "'>");
+				el.data("scrollWrapper", el.find("." + o.scrollWrapperClass));
+			}
+			// Only the scrollable area is missing
+			else if (el.data("scrollableArea").length === 0) {
+				el.data("scrollWrapper").wrapInner("<div class='" + o.scrollableAreaClass + "'>");
+				el.data("scrollableArea", el.find("." + o.scrollableAreaClass));
+			}
+
+			// Put the right and left hot spot back into the scroller again
+			// or create them if they where not present from the beginning.
+			if (el.data("scrollingHotSpotRight").length === 0) {
+				el.prepend("<div class='" + o.scrollingHotSpotRightClass + "'></div>");
+				el.data("scrollingHotSpotRight", el.find("." + o.scrollingHotSpotRightClass));
+			} else {
+				el.prepend(el.data("scrollingHotSpotRight"));
+			}
+
+			if (el.data("scrollingHotSpotLeft").length === 0) {
+				el.prepend("<div class='" + o.scrollingHotSpotLeftClass + "'></div>");
+				el.data("scrollingHotSpotLeft", el.find("." + o.scrollingHotSpotLeftClass));
+			} else {
+				el.prepend(el.data("scrollingHotSpotLeft"));
+			}
+
+
+			// Create variables in the element data storage
+			el.data("speedBooster", 1);
+			el.data("scrollXPos", 0);
+			el.data("hotSpotWidth", el.data("scrollingHotSpotLeft").innerWidth());
+			el.data("scrollableAreaWidth", 0);
+			el.data("startingPosition", 0);
+			el.data("rightScrollingInterval", null);
+			el.data("leftScrollingInterval", null);
+			el.data("autoScrollingInterval", null);
+			el.data("hideHotSpotBackgroundsInterval", null);
+			el.data("previousScrollLeft", 0);
+			el.data("pingPongDirection", "right");
+			el.data("getNextElementWidth", true);
+			el.data("swapAt", null);
+			el.data("startAtElementHasNotPassed", true);
+			el.data("swappedElement", null);
+			el.data("originalElements", el.data("scrollableArea").children(o.countOnlyClass));
+			el.data("visible", true);
+			el.data("enabled", true);
+			el.data("scrollableAreaHeight", el.data("scrollableArea").height());
+			el.data("scrollerOffset", el.offset());
+
+			/*****************************************
+			SET UP EVENTS FOR TOUCH SCROLLING
+			*****************************************/
+			if (o.touchScrolling && el.data("enabled")) {
+				// Use jquery.kinetic.js for touch scrolling
+				// Vertical scrolling disabled
+				el.data("scrollWrapper").kinetic({
+					y: false,
+					moved: function (settings) {
+						if (o.manualContinuousScrolling) {
+							if (el.data("scrollWrapper").scrollLeft() <= 0) {
+								self._checkContinuousSwapLeft();
+							} else {
+								self._checkContinuousSwapRight();
+							}
+						}
+						
+						// Callback
+						self._trigger("touchMoved");
+					},
+					stopped: function (settings) {
+						// Stop any ongoing animations
+						el.data("scrollWrapper").stop(true, false);
+
+						// Stop any ongoing auto scrolling
+						self.stopAutoScrolling();
+						
+						// Callback
+						self._trigger("touchStopped");
+					}
+				});
+			}
+
+			/*****************************************
+			SET UP EVENTS FOR SCROLLING RIGHT
+			*****************************************/
+			// Check the mouse X position and calculate 
+			// the relative X position inside the right hotspot
+			el.data("scrollingHotSpotRight").bind("mousemove", function (e) {
+				if (o.hotSpotScrolling) {
+					var x = e.pageX - $(this).offset().left;
+					el.data("scrollXPos", Math.round((x / el.data("hotSpotWidth")) * o.hotSpotScrollingStep));
+
+					// If the position is less then 1, it's set to 1
+					if (el.data("scrollXPos") === Infinity || el.data("scrollXPos") < 1) {
+						el.data("scrollXPos", 1);
+					}
+				}
+			});
+
+			// Mouseover right hotspot - scrolling
+			el.data("scrollingHotSpotRight").bind("mouseover", function () {
+				if (o.hotSpotScrolling) {
+					// Stop any ongoing animations
+					el.data("scrollWrapper").stop(true, false);
+
+					// Stop any ongoing auto scrolling
+					self.stopAutoScrolling();
+
+					// Start the scrolling interval
+					el.data("rightScrollingInterval", setInterval(function () {
+						if (el.data("scrollXPos") > 0 && el.data("enabled")) {
+							el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + (el.data("scrollXPos") * el.data("speedBooster")));
+
+							if (o.manualContinuousScrolling) {
+								self._checkContinuousSwapRight();
+							}
+
+							self._showHideHotSpots();
+						}
+					}, o.hotSpotScrollingInterval));
+
+					// Callback
+					self._trigger("mouseOverRightHotSpot");
+				}
+			});
+
+			// Mouseout right hotspot - stop scrolling
+			el.data("scrollingHotSpotRight").bind("mouseout", function () {
+				if (o.hotSpotScrolling) {
+					clearInterval(el.data("rightScrollingInterval"));
+					el.data("scrollXPos", 0);
+
+					// Easing out after scrolling
+					if (o.easingAfterHotSpotScrolling && el.data("enabled")) {
+						el.data("scrollWrapper").animate({ scrollLeft: el.data("scrollWrapper").scrollLeft() + o.easingAfterHotSpotScrollingDistance }, { duration: o.easingAfterHotSpotScrollingDuration, easing: o.easingAfterHotSpotScrollingFunction });
+					}
+				}
+			});
+
+
+			// mousedown right hotspot (add scrolling speed booster)
+			el.data("scrollingHotSpotRight").bind("mousedown", function () {
+				el.data("speedBooster", o.hotSpotMouseDownSpeedBooster);
+			});
+
+			// mouseup anywhere (stop boosting the scrolling speed)
+			$("body").bind("mouseup", function () {
+				el.data("speedBooster", 1);
+			});
+
+			/*****************************************
+			SET UP EVENTS FOR SCROLLING LEFT
+			*****************************************/
+			// Check the mouse X position and calculate
+			// the relative X position inside the left hotspot
+			el.data("scrollingHotSpotLeft").bind("mousemove", function (e) {
+				if (o.hotSpotScrolling) {
+					var x = el.data("hotSpotWidth") - (e.pageX - $(this).offset().left);
+
+					el.data("scrollXPos", Math.round((x / el.data("hotSpotWidth")) * o.hotSpotScrollingStep));
+
+					// If the position is less then 1, it's set to 1
+					if (el.data("scrollXPos") === Infinity || el.data("scrollXPos") < 1) {
+						el.data("scrollXPos", 1);
+					}
+				}
+			});
+
+			// Mouseover left hotspot
+			el.data("scrollingHotSpotLeft").bind("mouseover", function () {
+				if (o.hotSpotScrolling) {
+					// Stop any ongoing animations
+					el.data("scrollWrapper").stop(true, false);
+
+					// Stop any ongoing auto scrolling
+					self.stopAutoScrolling();
+
+					el.data("leftScrollingInterval", setInterval(function () {
+						if (el.data("scrollXPos") > 0 && el.data("enabled")) {
+							el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() - (el.data("scrollXPos") * el.data("speedBooster")));
+
+							if (o.manualContinuousScrolling) {
+								self._checkContinuousSwapLeft();
+							}
+
+							self._showHideHotSpots();
+						}
+					}, o.hotSpotScrollingInterval));
+
+					// Callback
+					self._trigger("mouseOverLeftHotSpot");
+				}
+			});
+
+			// mouseout left hotspot
+			el.data("scrollingHotSpotLeft").bind("mouseout", function () {
+				if (o.hotSpotScrolling) {
+					clearInterval(el.data("leftScrollingInterval"));
+					el.data("scrollXPos", 0);
+
+					// Easing out after scrolling
+					if (o.easingAfterHotSpotScrolling && el.data("enabled")) {
+						el.data("scrollWrapper").animate({ scrollLeft: el.data("scrollWrapper").scrollLeft() - o.easingAfterHotSpotScrollingDistance }, { duration: o.easingAfterHotSpotScrollingDuration, easing: o.easingAfterHotSpotScrollingFunction });
+					}
+				}
+			});
+
+			// mousedown left hotspot (add scrolling speed booster)
+			el.data("scrollingHotSpotLeft").bind("mousedown", function () {
+				el.data("speedBooster", o.hotSpotMouseDownSpeedBooster);
+			});
+
+			/*****************************************
+			SET UP EVENT FOR MOUSEWHEEL SCROLLING
+			*****************************************/
+			el.data("scrollableArea").mousewheel(function (event, delta, deltaX, deltaY) {
+
+				if (el.data("enabled") && o.mousewheelScrolling.length > 0) {
+					var pixels;
+
+					// Can be either positive or negative
+					// Is multiplied/inverted by minus one since you want it to scroll 
+					// left when moving the wheel down/right and right when moving the wheel up/left
+					if (o.mousewheelScrolling === "vertical" && deltaY !== 0) {
+						// Stop any ongoing auto scrolling if it's running
+						self.stopAutoScrolling();
+						event.preventDefault();
+						pixels = Math.round((o.mousewheelScrollingStep * deltaY) * -1);
+						self.move(pixels);
+					} else if (o.mousewheelScrolling === "horizontal" && deltaX !== 0) {
+						// Stop any ongoing auto scrolling if it's running
+						self.stopAutoScrolling();
+						event.preventDefault();
+						pixels = Math.round((o.mousewheelScrollingStep * deltaX) * -1);
+						self.move(pixels);
+					} else if (o.mousewheelScrolling === "allDirections") {
+						// Stop any ongoing auto scrolling if it's running
+						self.stopAutoScrolling();
+						event.preventDefault();
+						pixels = Math.round((o.mousewheelScrollingStep * delta) * -1);
+						self.move(pixels);
+					}
+
+
+				}
+			});
+
+			// Capture and disable mousewheel events when the pointer
+			// is over any of the hotspots
+			if (o.mousewheelScrolling) {
+				el.data("scrollingHotSpotLeft").add(el.data("scrollingHotSpotRight")).mousewheel(function (event) {
+					event.preventDefault();
+				});
+			}
+
+			/*****************************************
+			SET UP EVENT FOR RESIZING THE BROWSER WINDOW
+			*****************************************/
+			$(window).bind("resize", function () {
+				self._showHideHotSpots();
+				self._trigger("windowResized");
+			});
+
+			/*****************************************
+			FETCHING CONTENT ON INITIALIZATION
+			*****************************************/
+			// If getContentOnLoad is present in the options, 
+			// sort out the method and parameters and get the content
+
+			if (!(jQuery.isEmptyObject(o.getContentOnLoad))) {
+				self[o.getContentOnLoad.method](o.getContentOnLoad.content, o.getContentOnLoad.manipulationMethod, o.getContentOnLoad.addWhere, o.getContentOnLoad.filterTag);
+			}
+
+			// Should it be hidden on start?
+			if (o.hiddenOnStart) {
+				self.hide();
+			}
+
+			/*****************************************
+			AUTOSCROLLING
+			*****************************************/
+			// The $(window).load event handler is used because the width of the elements are not calculated
+			// properly until then, at least not in Google Chrome. The start of the auto scrolling and the
+			// setting of the hotspot backgrounds is started here as well for the same reason. 
+			// If the auto scrolling is not started in $(window).load, it won't start because it 
+			// will interpret the scrollable areas as too short.
+			$(window).load(function () {
+
+				// If scroller is not hidden, recalculate the scrollable area
+				if (!(o.hiddenOnStart)) {
+					self.recalculateScrollableArea();
+				}
+
+				// Autoscrolling is active
+				if ((o.autoScrollingMode.length > 0) && !(o.hiddenOnStart)) {
+					self.startAutoScrolling();
+				}
+
+				// If the user wants to have visible hotspot backgrounds, 
+				// here is where it's taken care of
+				if (o.autoScrollingMode !== "always") {
+
+					switch (o.visibleHotSpotBackgrounds) {
+						case "always":
+							self.showHotSpotBackgrounds();
+							break;
+						case "onStart":
+							self.showHotSpotBackgrounds();
+							el.data("hideHotSpotBackgroundsInterval", setTimeout(function () {
+								self.hideHotSpotBackgrounds(250);
+							}, o.hotSpotsVisibleTime));
+							break;
+						case "hover":
+							el.mouseenter(function (event) {
+								if (o.hotSpotScrolling) {
+									event.stopPropagation();
+									self.showHotSpotBackgrounds(250);
+								}
+							}).mouseleave(function (event) {
+								if (o.hotSpotScrolling) {
+									event.stopPropagation();
+									self.hideHotSpotBackgrounds(250);
+								}
+							});
+							break;
+						default:
+							break;
+					}
+				}
+
+				self._showHideHotSpots();
+
+				self._trigger("setupComplete");
+
+			});
+
+		},
+		/**********************************************************
+		_init 
+		**********************************************************/
+		// When the contents of the scrollable area is changed outside the widget,
+		// the widget must be reinitilaized.
+		// This code is run every time the widget is called without arguments
+		 _init: function () {
+			var self = this, el = this.element;
+		 
+			// Recalculate the total width of the elements inside the scrollable area
+			self.recalculateScrollableArea();
+		 
+			// Determine which hotspots to show
+			self._showHideHotSpots();
+		
+			// Trigger callback
+			self._trigger("initializationComplete");
+		},
+		/**********************************************************
+		Override _setOption and handle altered options
+		**********************************************************/
+		_setOption: function (key, value) {
+			var self = this, o = this.options, el = this.element;
+
+			// Update option
+			o[key] = value;
+
+			if (key === "hotSpotScrolling") {
+				// Handler if the option hotSpotScrolling is altered
+				if (value === true) {
+					self._showHideHotSpots();
+				} else {
+					el.data("scrollingHotSpotLeft").hide();
+					el.data("scrollingHotSpotRight").hide();
+				}
+			} else if (key === "autoScrollingStep" ||
+			// Make sure that certain values are integers, otherwise
+			// they will summon bad spirits in the plugin
+				key === "easingAfterHotSpotScrollingDistance" ||
+				key === "easingAfterHotSpotScrollingDuration" ||
+				key === "easingAfterMouseWheelScrollingDuration") {
+				o[key] = parseInt(value, 10);
+			} else if (key === "autoScrollingInterval") {
+				// Handler if the autoScrollingInterval is altered
+				o[key] = parseInt(value, 10);
+				self.startAutoScrolling();
+			}
+
+		},
+		/**********************************************************
+		Hotspot functions
+		**********************************************************/
+		showHotSpotBackgrounds: function (fadeSpeed) {
+
+			// Alter the CSS (SmoothDivScroll.css) if you want to customize
+			// the look'n'feel of the visible hotspots
+			var self = this, el = this.element, o = this.options;
+
+
+			// Fade in the hotspot backgrounds
+			if (fadeSpeed !== undefined) {
+				// Before the fade-in starts, we need to make sure the opacity is zero
+				//el.data("scrollingHotSpotLeft").add(el.data("scrollingHotSpotRight")).css("opacity", "0.0");
+
+				el.data("scrollingHotSpotLeft").addClass(o.scrollingHotSpotLeftVisibleClass);
+				el.data("scrollingHotSpotRight").addClass(o.scrollingHotSpotRightVisibleClass);
+
+				// Fade in the hotspots
+				el.data("scrollingHotSpotLeft").add(el.data("scrollingHotSpotRight")).fadeTo(fadeSpeed, 0.35);
+			}
+			// Don't fade, just show them
+			else {
+
+				// The left hotspot
+				el.data("scrollingHotSpotLeft").addClass(o.scrollingHotSpotLeftVisibleClass);
+				el.data("scrollingHotSpotLeft").removeAttr("style");
+
+				// The right hotspot
+				el.data("scrollingHotSpotRight").addClass(o.scrollingHotSpotRightVisibleClass);
+				el.data("scrollingHotSpotRight").removeAttr("style");
+			}
+
+			self._showHideHotSpots();
+
+		},
+		hideHotSpotBackgrounds: function (fadeSpeed) {
+			var el = this.element, o = this.options;
+
+			// Fade out the hotspot backgrounds
+			if (fadeSpeed !== undefined) {
+
+				// Fade out the left hotspot
+				el.data("scrollingHotSpotLeft").fadeTo(fadeSpeed, 0.0, function () {
+					el.data("scrollingHotSpotLeft").removeClass(o.scrollingHotSpotLeftVisibleClass);
+				});
+
+				// Fade out the right hotspot
+				el.data("scrollingHotSpotRight").fadeTo(fadeSpeed, 0.0, function () {
+					el.data("scrollingHotSpotRight").removeClass(o.scrollingHotSpotRightVisibleClass);
+				});
+
+			}
+			// Don't fade, just hide them
+			else {
+				el.data("scrollingHotSpotLeft").removeClass(o.scrollingHotSpotLeftVisibleClass).removeAttr("style");
+				el.data("scrollingHotSpotRight").removeClass(o.scrollingHotSpotRightVisibleClass).removeAttr("style");
+			}
+
+		},
+		// Function for showing and hiding hotspots depending on the
+		// offset of the scrolling
+		_showHideHotSpots: function () {
+			var self = this, el = this.element, o = this.options;
+
+			// Hot spot scrolling is not enabled so show no hot spots
+			if (!(o.hotSpotScrolling)) {
+				el.data("scrollingHotSpotLeft").hide();
+				el.data("scrollingHotSpotRight").hide();
+			} else {
+
+				// If the manual continuous scrolling option is set show both
+				if (o.hotSpotScrolling && o.autoScrollingMode !== "always" && el.data("autoScrollingInterval") !== null) {
+					el.data("scrollingHotSpotLeft").show();
+					el.data("scrollingHotSpotRight").show();
+				}
+				// Autoscrolling not set to always and hotspot scrolling enabled.
+				// Regular hot spot scrolling.
+				else if (o.autoScrollingMode !== "always" && o.hotSpotScrolling) {
+					// If the scrollable area is shorter than the scroll wrapper, both hotspots
+					// should be hidden
+					if (el.data("scrollableAreaWidth") <= (el.data("scrollWrapper").innerWidth())) {
+						el.data("scrollingHotSpotLeft").hide();
+						el.data("scrollingHotSpotRight").hide();
+					}
+					// When you can't scroll further left the left scroll hotspot should be hidden
+					// and the right hotspot visible.
+					else if (el.data("scrollWrapper").scrollLeft() === 0) {
+						el.data("scrollingHotSpotLeft").hide();
+						el.data("scrollingHotSpotRight").show();
+						// Callback
+						self._trigger("scrollerLeftLimitReached");
+						// Clear interval
+						clearInterval(el.data("leftScrollingInterval"));
+						el.data("leftScrollingInterval", null);
+					}
+					// When you can't scroll further right
+					// the right scroll hotspot should be hidden
+					// and the left hotspot visible
+					else if (el.data("scrollableAreaWidth") <= (el.data("scrollWrapper").innerWidth() + el.data("scrollWrapper").scrollLeft())) {
+						el.data("scrollingHotSpotLeft").show();
+						el.data("scrollingHotSpotRight").hide();
+						// Callback
+						self._trigger("scrollerRightLimitReached");
+						// Clear interval
+						clearInterval(el.data("rightScrollingInterval"));
+						el.data("rightScrollingInterval", null);
+					}
+					// If you are somewhere in the middle of your
+					// scrolling, both hotspots should be visible
+					else {
+						el.data("scrollingHotSpotLeft").show();
+						el.data("scrollingHotSpotRight").show();
+					}
+				}
+				// If auto scrolling is set to always, there should be no hotspots
+				else {
+					el.data("scrollingHotSpotLeft").hide();
+					el.data("scrollingHotSpotRight").hide();
+				}
+			}
+
+
+
+		},
+		// Function for calculating the scroll position of a certain element
+		_setElementScrollPosition: function (method, element) {
+			var el = this.element, o = this.options, tempScrollPosition = 0;
+
+			switch (method) {
+				case "first":
+					el.data("scrollXPos", 0);
+					return true;
+				case "start":
+					// Check to see if there is a specified start element in the options 
+					// and that the element exists in the DOM
+					if (o.startAtElementId !== "") {
+						if (el.data("scrollableArea").has("#" + o.startAtElementId)) {
+							tempScrollPosition = $("#" + o.startAtElementId).position().left;
+							el.data("scrollXPos", tempScrollPosition);
+							return true;
+						}
+					}
+					return false;
+				case "last":
+					el.data("scrollXPos", (el.data("scrollableAreaWidth") - el.data("scrollWrapper").innerWidth()));
+					return true;
+				case "number":
+					// Check to see that an element number is passed
+					if (!(isNaN(element))) {
+						tempScrollPosition = el.data("scrollableArea").children(o.countOnlyClass).eq(element - 1).position().left;
+						el.data("scrollXPos", tempScrollPosition);
+						return true;
+					}
+					return false;
+				case "id":
+					// Check that an element id is passed and that the element exists in the DOM
+					if (element.length > 0) {
+						if (el.data("scrollableArea").has("#" + element)) {
+							tempScrollPosition = $("#" + element).position().left;
+							el.data("scrollXPos", tempScrollPosition);
+							return true;
+						}
+					}
+					return false;
+				default:
+					return false;
+			}
+
+
+		},
+		/**********************************************************
+		Jumping to a certain element
+		**********************************************************/
+		jumpToElement: function (jumpTo, element) {
+			var self = this, el = this.element;
+
+			// Check to see that the scroller is enabled
+			if (el.data("enabled")) {
+				// Get the position of the element to scroll to
+				if (self._setElementScrollPosition(jumpTo, element)) {
+					// Jump to the element
+					el.data("scrollWrapper").scrollLeft(el.data("scrollXPos"));
+					// Check the hotspots
+					self._showHideHotSpots();
+					// Trigger the right callback
+					switch (jumpTo) {
+						case "first":
+							self._trigger("jumpedToFirstElement");
+							break;
+						case "start":
+							self._trigger("jumpedToStartElement");
+							break;
+						case "last":
+							self._trigger("jumpedToLastElement");
+							break;
+						case "number":
+							self._trigger("jumpedToElementNumber", null, { "elementNumber": element });
+							break;
+						case "id":
+							self._trigger("jumpedToElementId", null, { "elementId": element });
+							break;
+						default:
+							break;
+					}
+
+				}
+			}
+		},
+		/**********************************************************
+		Scrolling to a certain element
+		**********************************************************/
+		scrollToElement: function (scrollTo, element) {
+			var self = this, el = this.element, o = this.options, autoscrollingWasRunning = false;
+
+			if (el.data("enabled")) {
+				// Get the position of the element to scroll to
+				if (self._setElementScrollPosition(scrollTo, element)) {
+					// Stop any ongoing auto scrolling
+					if (el.data("autoScrollingInterval") !== null) {
+						self.stopAutoScrolling();
+						autoscrollingWasRunning = true;
+					}
+
+					// Stop any other running animations
+					// (clear queue but don't jump to the end)
+					el.data("scrollWrapper").stop(true, false);
+
+					// Do the scolling animation
+					el.data("scrollWrapper").animate({
+						scrollLeft: el.data("scrollXPos")
+					}, { duration: o.scrollToAnimationDuration, easing: o.scrollToEasingFunction, complete: function () {
+						// If auto scrolling was running before, start it again
+						if (autoscrollingWasRunning) {
+							self.startAutoScrolling();
+						}
+
+						self._showHideHotSpots();
+
+						// Trigger the right callback
+						switch (scrollTo) {
+							case "first":
+								self._trigger("scrolledToFirstElement");
+								break;
+							case "start":
+								self._trigger("scrolledToStartElement");
+								break;
+							case "last":
+								self._trigger("scrolledToLastElement");
+								break;
+							case "number":
+								self._trigger("scrolledToElementNumber", null, { "elementNumber": element });
+								break;
+							case "id":
+								self._trigger("scrolledToElementId", null, { "elementId": element });
+								break;
+							default:
+								break;
+						}
+					}
+					});
+				}
+			}
+
+		},
+		move: function (pixels) {
+			var self = this, el = this.element, o = this.options;
+			// clear queue, move to end
+			el.data("scrollWrapper").stop(true, true);
+
+			// Only run this code if it's possible to scroll left or right,
+			if ((pixels < 0 && el.data("scrollWrapper").scrollLeft() > 0) || (pixels > 0 && el.data("scrollableAreaWidth") > (el.data("scrollWrapper").innerWidth() + el.data("scrollWrapper").scrollLeft())) || o.manualContinuousScrolling ) {
+
+        var scrollLength = el.data("scrollableArea").width() - el.data("scrollWrapper").width();
+        var sOffset = el.data("scrollWrapper").scrollLeft() + pixels;
+
+        if( sOffset < 0 ) { // Swap last element to be the first one if scroll out of the left edge of view
+                
+            var forceSwapElementLeft = function(){
+              el.data("swappedElement", el.data("scrollableArea").children(":last").detach());
+              el.data("scrollableArea").prepend(el.data("swappedElement"));
+              el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + el.data("swappedElement").outerWidth(true));              
+            };
+            
+            while(sOffset < 0 ){ // keep swap elements left until it has enough length for scrolling left
+              forceSwapElementLeft();
+              sOffset = el.data("scrollableArea").children(":first").outerWidth(true) + sOffset;                   
+            }
+
+        } else if( sOffset - scrollLength > 0 ){ // Swap the first element to be the last one if scroll out of the right edge of view
+           
+          var forceSwapElementRight = function(){            
+            el.data("swappedElement", el.data("scrollableArea").children(":first").detach());
+            el.data("scrollableArea").append(el.data("swappedElement"));
+            var wrapperLeft = el.data("scrollWrapper").scrollLeft();
+            el.data("scrollWrapper").scrollLeft(wrapperLeft - el.data("swappedElement").outerWidth(true));            
+          };
+          
+          while( sOffset - scrollLength > 0 ){ // keep swap elements right until it has enough length for scrolling right
+            forceSwapElementRight();
+            sOffset = sOffset - el.data("scrollableArea").children(":last").outerWidth(true);              
+          }
+          
+        }
+          
+				if (o.easingAfterMouseWheelScrolling) {
+        
+          el.data("scrollWrapper").animate({ scrollLeft: el.data("scrollWrapper").scrollLeft() + pixels }, { duration: o.easingAfterMouseWheelScrollingDuration, easing: o.easingAfterMouseWheelFunction, complete: function () {
+            self._showHideHotSpots();
+            if (o.manualContinuousScrolling) {
+              if (pixels > 0) {
+                self._checkContinuousSwapRight();
+              } else {
+                self._checkContinuousSwapLeft();
+              }
+            }
+          }
+          });
+          
+				} else {
+					el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + pixels);
+					self._showHideHotSpots();
+
+					if (o.manualContinuousScrolling) {
+						if (pixels > 0) {
+							self._checkContinuousSwapRight();
+						} else {
+							self._checkContinuousSwapLeft();
+						}
+					}
+				}
+         
+
+			}
+
+   },
+		/**********************************************************
+		Adding or replacing content
+		**********************************************************/
+		/*  Arguments are:
+		content - a valid URL to a Flickr feed - string
+		manipulationMethod - addFirst, addLast or replace (default) - string
+		*/
+		getFlickrContent: function (content, manipulationMethod) {
+			var self = this, el = this.element;
+
+			$.getJSON(content, function (data) {
+				// small square - size is 75x75
+				// thumbnail -> large - size is the longest side
+				var flickrImageSizes = [{ size: "small square", pixels: 75, letter: "_s" },
+										{ size: "thumbnail", pixels: 100, letter: "_t" },
+										{ size: "small", pixels: 240, letter: "_m" },
+										{ size: "medium", pixels: 500, letter: "" },
+										{ size: "medium 640", pixels: 640, letter: "_z" },
+										{ size: "large", pixels: 1024, letter: "_b"}];
+				var loadedFlickrImages = [];
+				var imageIdStringBuffer = [];
+				var startingIndex;
+				var numberOfFlickrItems = data.items.length;
+				var loadedFlickrImagesCounter = 0;
+
+				// Determine a plausible starting value for the
+				// image height
+				if (el.data("scrollableAreaHeight") <= 75) {
+					startingIndex = 0;
+				} else if (el.data("scrollableAreaHeight") <= 100) {
+					startingIndex = 1;
+				} else if (el.data("scrollableAreaHeight") <= 240) {
+					startingIndex = 2;
+				} else if (el.data("scrollableAreaHeight") <= 500) {
+					startingIndex = 3;
+				} else if (el.data("scrollableAreaHeight") <= 640) {
+					startingIndex = 4;
+				} else {
+					startingIndex = 5;
+				}
+
+				// Put all items from the feed in an array.
+				// This is necessary
+				$.each(data.items, function (index, item) {
+					loadFlickrImage(item, startingIndex);
+				});
+
+				function loadFlickrImage(item, sizeIndex) {
+					var path = item.media.m;
+					var imgSrc = path.replace("_m", flickrImageSizes[sizeIndex].letter);
+					var tempImg = $("<img />").attr("src", imgSrc);
+
+					tempImg.load(function () {
+						// Is it still smaller? Load next size
+						if (this.height < el.data("scrollableAreaHeight")) {
+							// Load a bigger image, if possible
+							if ((sizeIndex + 1) < flickrImageSizes.length) {
+								loadFlickrImage(item, sizeIndex + 1);
+							} else {
+								addImageToLoadedImages(this);
+							}
+						}
+						else {
+							addImageToLoadedImages(this);
+						}
+
+						// Finishing stuff to do when all images have been loaded
+						if (loadedFlickrImagesCounter === numberOfFlickrItems) {
+							switch (manipulationMethod) {
+								case "addFirst":
+									// Add the loaded content first in the scrollable area
+									el.data("scrollableArea").children(":first").before(loadedFlickrImages);
+									break;
+								case "addLast":
+									// Add the loaded content last in the scrollable area
+									el.data("scrollableArea").children(":last").after(loadedFlickrImages);
+									break;
+								default:
+									// Replace the content in the scrollable area
+									el.data("scrollableArea").html(loadedFlickrImages);
+									break;
+							}
+
+							// Recalculate the total width of the elements inside the scrollable area
+							self.recalculateScrollableArea();
+
+							// Determine which hotspots to show
+							self._showHideHotSpots();
+
+							// Trigger callback
+							self._trigger("addedFlickrContent", null, { "addedElementIds": imageIdStringBuffer });
+						}
+
+					});
+				}
+
+				// Add the loaded content first or last in the scrollable area
+				function addImageToLoadedImages(imageObj) {
+					// Calculate the scaled width
+					var widthScalingFactor = el.data("scrollableAreaHeight") / imageObj.height;
+					var tempWidth = Math.round(imageObj.width * widthScalingFactor);
+					// Set an id for the image - the filename is used as an id
+					var tempIdArr = $(imageObj).attr("src").split("/");
+					var lastElemIndex = (tempIdArr.length - 1);
+					tempIdArr = tempIdArr[lastElemIndex].split(".");
+					$(imageObj).attr("id", tempIdArr[0]);
+					// Set the height of the image to the height of the scrollable area and add the width
+					$(imageObj).css({ "height": el.data("scrollableAreaHeight"), "width": tempWidth });
+					// Add the id of the image to the array of id's - this
+					// is used as a parameter when the callback is triggered
+					imageIdStringBuffer.push(tempIdArr[0]);
+					// Add the image to the array of loaded images
+					loadedFlickrImages.push(imageObj);
+
+					// Increment counter for loaded images
+					loadedFlickrImagesCounter++;
+				}
+
+			});
+		},
+		/*  Arguments are:
+		content - a valid URL to an AJAX content source - string
+		manipulationMethod - addFirst, addLast or replace (default) - string
+		filterTag - a jQuery selector that matches the elements from the AJAX content
+		source that you want, for example ".myClass" or "#thisDiv" or "div" - string
+		*/
+		getAjaxContent: function (content, manipulationMethod, filterTag) {
+			var self = this, el = this.element;
+			$.ajaxSetup({ cache: false });
+
+			$.get(content, function (data) {
+				var filteredContent;
+
+				if (filterTag !== undefined) {
+					if (filterTag.length > 0) {
+						// A bit of a hack since I can't know if the element
+						// that the user wants is a direct child of body (= use filter)
+						// or other types of elements (= use find)
+						filteredContent = $("<div>").html(data).find(filterTag);
+					} else {
+						filteredContent = content;
+					}
+				} else {
+					filteredContent = data;
+				}
+
+				switch (manipulationMethod) {
+					case "addFirst":
+						// Add the loaded content first in the scrollable area
+						el.data("scrollableArea").children(":first").before(filteredContent);
+						break;
+					case "addLast":
+						// Add the loaded content last in the scrollable area
+						el.data("scrollableArea").children(":last").after(filteredContent);
+						break;
+					default:
+						// Replace the content in the scrollable area
+						el.data("scrollableArea").html(filteredContent);
+						break;
+				}
+
+				// Recalculate the total width of the elements inside the scrollable area
+				self.recalculateScrollableArea();
+
+				// Determine which hotspots to show
+				self._showHideHotSpots();
+
+				// Trigger callback
+				self._trigger("addedAjaxContent");
+
+			});
+		},
+		getHtmlContent: function (content, manipulationMethod, filterTag) {
+			var self = this, el = this.element;
+
+			// No AJAX involved at all - just add raw HTML-content
+			/* Arguments are:
+			content - any raw HTML that you want - string
+			manipulationMethod - addFirst, addLast or replace (default) - string
+			filterTag - a jQuery selector that matches the elements from the AJAX content
+			source that you want, for example ".myClass" or "#thisDiv" or "div" - string
+			*/
+			var filteredContent;
+			if (filterTag !== undefined) {
+				if (filterTag.length > 0) {
+					// A bit of a hack since I can't know if the element
+					// that the user wants is a direct child of body (= use filter)
+					// or other types of elements (= use find)
+					filteredContent = $("<div>").html(content).find(filterTag);
+				} else {
+					filteredContent = content;
+				}
+			} else {
+				filteredContent = content;
+			}
+
+			switch (manipulationMethod) {
+				case "addFirst":
+					// Add the loaded content first in the scrollable area
+					el.data("scrollableArea").children(":first").before(filteredContent);
+					break;
+				case "addLast":
+					// Add the loaded content last in the scrollable area
+					el.data("scrollableArea").children(":last").after(filteredContent);
+					break;
+				default:
+					// Replace the content in the scrollable area
+					el.data("scrollableArea").html(filteredContent);
+					break;
+			}
+
+			// Recalculate the total width of the elements inside the scrollable area
+			self.recalculateScrollableArea();
+	
+			// Determine which hotspots to show
+			self._showHideHotSpots();
+
+			// Trigger callback
+			self._trigger("addedHtmlContent");
+
+		},
+		/**********************************************************
+		Recalculate the scrollable area
+		**********************************************************/
+		recalculateScrollableArea: function () {
+
+			var tempScrollableAreaWidth = 0, foundStartAtElement = false, o = this.options, el = this.element;
+
+			// Add up the total width of all the items inside the scrollable area
+			el.data("scrollableArea").children(o.countOnlyClass).each(function () {
+				// Check to see if the current element in the loop is the one where the scrolling should start
+				if ((o.startAtElementId.length > 0) && (($(this).attr("id")) === o.startAtElementId)) {
+					el.data("startingPosition", tempScrollableAreaWidth);
+					foundStartAtElement = true;
+				}
+				tempScrollableAreaWidth = tempScrollableAreaWidth + $(this).outerWidth(true);
+
+			});
+
+			// If the element with the ID specified by startAtElementId
+			// is not found, reset it
+			if (!(foundStartAtElement)) {
+				el.data("startAtElementId", "");
+			}
+
+			// Set the width of the scrollable area
+			el.data("scrollableAreaWidth", tempScrollableAreaWidth);
+			el.data("scrollableArea").width(el.data("scrollableAreaWidth"));
+
+			// Move to the starting position
+			el.data("scrollWrapper").scrollLeft(el.data("startingPosition"));
+			el.data("scrollXPos", el.data("startingPosition"));
+		},
+		/**********************************************************
+		Get current scrolling left offset
+		**********************************************************/
+		getScrollerOffset: function () {
+			var el = this.element;
+
+			// Returns the current left offset
+			// Please remember that if the scroller is in continuous
+			// mode, the offset is not that relevant anymore since
+			// the plugin will swap the elements inside the scroller
+			// around and manipulate the offset in this process.
+			return el.data("scrollWrapper").scrollLeft();
+		},
+		/**********************************************************
+		Stopping, starting and doing the auto scrolling
+		**********************************************************/
+		stopAutoScrolling: function () {
+			var self = this, el = this.element;
+
+			if (el.data("autoScrollingInterval") !== null) {
+				clearInterval(el.data("autoScrollingInterval"));
+				el.data("autoScrollingInterval", null);
+
+				// Check to see which hotspots should be active
+				// in the position where the scroller has stopped
+				self._showHideHotSpots();
+
+				self._trigger("autoScrollingStopped");
+			}
+		},
+		/**********************************************************
+		Start Autoscrolling
+		**********************************************************/
+		startAutoScrolling: function () {
+			var self = this, el = this.element, o = this.options;
+
+			if (el.data("enabled")) {
+				self._showHideHotSpots();
+
+				// Stop any running interval
+				clearInterval(el.data("autoScrollingInterval"));
+				el.data("autoScrollingInterval", null);
+
+				// Callback
+				self._trigger("autoScrollingStarted");
+
+				// Start interval
+				el.data("autoScrollingInterval", setInterval(function () {
+
+					// If the scroller is not visible or
+					// if the scrollable area is shorter than the scroll wrapper
+					// any running auto scroll interval should stop.
+					if (!(el.data("visible")) || (el.data("scrollableAreaWidth") <= (el.data("scrollWrapper").innerWidth()))) {
+						// Stop any running interval
+						clearInterval(el.data("autoScrollingInterval"));
+						el.data("autoScrollingInterval", null);
+
+					}
+					else {
+
+						// Store the old scrollLeft value to see if the scrolling has reached the end
+						el.data("previousScrollLeft", el.data("scrollWrapper").scrollLeft());
+
+						switch (o.autoScrollingDirection) {
+							case "right":
+
+								el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + o.autoScrollingStep);
+								if (el.data("previousScrollLeft") === el.data("scrollWrapper").scrollLeft()) {
+									self._trigger("autoScrollingRightLimitReached");
+									self.stopAutoScrolling();
+								}
+								break;
+
+							case "left":
+								el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() - o.autoScrollingStep);
+								if (el.data("previousScrollLeft") === el.data("scrollWrapper").scrollLeft()) {
+									self._trigger("autoScrollingLeftLimitReached");
+									self.stopAutoScrolling();
+								}
+								break;
+
+							case "backAndForth":
+								if (el.data("pingPongDirection") === "right") {
+									el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + (o.autoScrollingStep));
+								}
+								else {
+									el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() - (o.autoScrollingStep));
+								}
+
+								// If the scrollLeft hasnt't changed it means that the scrolling has reached
+								// the end and the direction should be switched
+								if (el.data("previousScrollLeft") === el.data("scrollWrapper").scrollLeft()) {
+									if (el.data("pingPongDirection") === "right") {
+										el.data("pingPongDirection", "left");
+										self._trigger("autoScrollingRightLimitReached");
+									}
+									else {
+										el.data("pingPongDirection", "right");
+										self._trigger("autoScrollingLeftLimitReached");
+									}
+								}
+								break;
+
+							case "endlessLoopRight":
+
+								// Do the auto scrolling
+								el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + o.autoScrollingStep);
+
+								self._checkContinuousSwapRight();
+								break;
+							case "endlessLoopLeft":
+
+								// Do the auto scrolling
+								el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() - o.autoScrollingStep);
+
+								self._checkContinuousSwapLeft();
+								break;
+							default:
+								break;
+
+						}
+					}
+				}, o.autoScrollingInterval));
+			}
+		},
+		/**********************************************************
+		Check Continuos Swap Right
+		**********************************************************/
+		_checkContinuousSwapRight: function () {
+			var el = this.element, o = this.options;
+
+			// Get the width of the first element. When it has scrolled out of view,
+			// the element swapping should be executed. A true/false variable is used
+			// as a flag variable so the swapAt value doesn't have to be recalculated
+			// in each loop.  
+			if (el.data("getNextElementWidth")) {
+
+				if ((o.startAtElementId.length > 0) && (el.data("startAtElementHasNotPassed"))) {
+					// If the user has set a certain element to start at, set swapAt 
+					// to that element width. This happens once.
+					el.data("swapAt", $("#" + o.startAtElementId).outerWidth(true));
+					el.data("startAtElementHasNotPassed", false);
+				}
+				else {
+					// Set swapAt to the first element in the scroller
+					el.data("swapAt", el.data("scrollableArea").children(":first").outerWidth(true));
+				}
+				el.data("getNextElementWidth", false);
+			}
+
+
+			// Check to see if the swap should be done
+			if (el.data("swapAt") <= el.data("scrollWrapper").scrollLeft()) {
+				el.data("swappedElement", el.data("scrollableArea").children(":first").detach());
+				el.data("scrollableArea").append(el.data("swappedElement"));
+				var wrapperLeft = el.data("scrollWrapper").scrollLeft();
+				el.data("scrollWrapper").scrollLeft(wrapperLeft - el.data("swappedElement").outerWidth(true));
+				el.data("getNextElementWidth", true);
+			}
+		},
+		/**********************************************************
+		Check Continuos Swap Left
+		**********************************************************/
+		_checkContinuousSwapLeft: function () {
+			var el = this.element, o = this.options;
+
+			// Get the width of the first element. When it has scrolled out of view,
+			// the element swapping should be executed. A true/false variable is used
+			// as a flag variable so the swapAt value doesn't have to be recalculated
+			// in each loop.
+
+			if (el.data("getNextElementWidth")) {
+				if ((o.startAtElementId.length > 0) && (el.data("startAtElementHasNotPassed"))) {
+					el.data("swapAt", $("#" + o.startAtElementId).outerWidth(true));
+					el.data("startAtElementHasNotPassed", false);
+				}
+				else {
+					el.data("swapAt", el.data("scrollableArea").children(":first").outerWidth(true));
+				}
+
+				el.data("getNextElementWidth", false);
+			}
+
+			// Check to see if the swap should be done
+			if (el.data("scrollWrapper").scrollLeft() === 0) {
+       
+				el.data("swappedElement", el.data("scrollableArea").children(":last").detach());
+				el.data("scrollableArea").prepend(el.data("swappedElement"));
+				el.data("scrollWrapper").scrollLeft(el.data("scrollWrapper").scrollLeft() + el.data("swappedElement").outerWidth(true));
+				el.data("getNextElementWidth", true);
+        
+			}
+
+		},
+		restoreOriginalElements: function () {
+			var self = this, el = this.element;
+
+			// Restore the original content of the scrollable area
+			el.data("scrollableArea").html(el.data("originalElements"));
+			self.recalculateScrollableArea();
+			self.jumpToElement("first");
+		},
+		show: function () {
+			var el = this.element;
+			el.data("visible", true);
+			el.show();
+		},
+		hide: function () {
+			var el = this.element;
+			el.data("visible", false);
+			el.hide();
+		},
+		enable: function () {
+			var el = this.element;
+
+			// Enable touch scrolling
+			if (this.options.touchScrolling) {
+				el.data("scrollWrapper").kinetic('attach');
+			}
+
+			// Set enabled to true
+			el.data("enabled", true);
+		},
+		disable: function () {
+			var self = this, el = this.element;
+
+			// Clear all running intervals
+			self.stopAutoScrolling();
+			clearInterval(el.data("rightScrollingInterval"));
+			clearInterval(el.data("leftScrollingInterval"));
+			clearInterval(el.data("hideHotSpotBackgroundsInterval"));
+
+			// Disable touch scrolling
+			if (this.options.touchScrolling) {
+				el.data("scrollWrapper").kinetic('detach');
+			}
+
+			// Set enabled to false
+			el.data("enabled", false);
+		},
+		destroy: function () {
+			var self = this, el = this.element;
+
+			// Clear all running intervals
+			self.stopAutoScrolling();
+			clearInterval(el.data("rightScrollingInterval"));
+			clearInterval(el.data("leftScrollingInterval"));
+			clearInterval(el.data("hideHotSpotBackgroundsInterval"));
+
+			// Remove all element specific events
+			el.data("scrollingHotSpotRight").unbind("mouseover");
+			el.data("scrollingHotSpotRight").unbind("mouseout");
+			el.data("scrollingHotSpotRight").unbind("mousedown");
+
+			el.data("scrollingHotSpotLeft").unbind("mouseover");
+			el.data("scrollingHotSpotLeft").unbind("mouseout");
+			el.data("scrollingHotSpotLeft").unbind("mousedown");
+
+			el.unbind("mousenter");
+			el.unbind("mouseleave");
+
+			// Remove all elements created by the plugin
+			el.data("scrollingHotSpotRight").remove();
+			el.data("scrollingHotSpotLeft").remove();
+			el.data("scrollableArea").remove();
+			el.data("scrollWrapper").remove();
+
+			// Restore the original content of the scrollable area
+			el.html(el.data("originalElements"));
+
+			// Call the base destroy function
+			$.Widget.prototype.destroy.apply(this, arguments);
+
+		}
+
+
+	});
+})(jQuery);
Index: extensions/Slim/js/lytebox.js
===================================================================
--- extensions/Slim/js/lytebox.js	(revision 28543)
+++ 	(revision )
@@ -1,1991 +1,0 @@
-//**************************************************************************************************/
-//	Lytebox v5.5
-//
-//	 Author: Markus F. Hay
-//  Website: http://lytebox.com  (http://dolem.com/lytebox)
-//	   Date: January 26, 2012
-//	License: Creative Commons Attribution 3.0 License (http://creativecommons.org/licenses/by/3.0/)
-//**************************************************************************************************/
-function Lytebox(bInitialize, aHttp) {
-	/*** Language Configuration ***/
-	
-		// English - configure for your language or customize as needed. 
-		// Note that these values will be seen by users when mousing over buttons.
-		this.label = new Object();
-		this.label['close']		= 'Close (Esc)';
-		this.label['prev'] 		= 'Precédent';	// Previous (left arrow)
-		this.label['next'] 		= 'Suivant'; 		// Next (right arrow)
-		this.label['play'] 		= 'Play (spacebar)';
-		this.label['pause'] 	= 'Pause (spacebar)';
-		this.label['print'] 	= 'Print';
-		this.label['image'] 	= 'Image %1 of %2';		// %1 = active image, %2 = total images
-		this.label['page'] 		= 'Page %1 of %2'; 		// %1 = active page, %2 = total pages
-		
-	
-	/*** Configure Lytebox ***/
-	
-		this.theme   			= (typeof lyteboxTheme !== 'undefined') && /^(black|grey|red|green|blue|gold|orange)$/i.test(lyteboxTheme) ? lyteboxTheme : 'grey'; // themes: black (default), grey, red, green, blue, gold, orange
-		this.roundedBorder		= false; 		// controls whether or not the viewer uses rounded corners (false = square corners)
-		this.innerBorder		= true;			// controls whether to show the inner border around image/html content
-		this.outerBorder		= false;			// controls whether to show the outer grey (or theme) border
-		this.resizeSpeed		= 5;			// controls the speed of the image resizing (1=slowest and 10=fastest)
-		this.maxOpacity			= 90;			// higher opacity = darker overlay, lower opacity = lighter overlay
-		this.borderSize			= 0;			// if you adjust the padding in the CSS, you will need to update this variable -- otherwise, leave this alone...
-
-		this.appendQS			= false;		// if true, will append request_from=lytebox to the QS. Use this with caution as it may cause pages to not render
-		this.fixedPosition		= this.isMobile() ? false : true;	// if true, viewer will remain in a fixed position, otherwise page scrolling will be allowed
-		this.inherit			= true;			// controls whether or not data-lyte-options are inherited from the first link in a grouped set
-		
-		this.__hideObjects		= true;			// controls whether or not objects (such as Flash, Java, etc.) should be hidden when the viewer opens
-		this.__autoResize		= true;			// controls whether or not images should be resized if larger than the browser window dimensions
-		this.__doAnimations		= true;			// controls ALL animation effects (i.e. overlay fade in/out, image resize transition, etc.)
-		this.__animateOverlay	= false;		// controls ONLY the overlay (background darkening) effects, and whether or not to fade in/out
-		this.__forceCloseClick 	= false;		// if true, users are forced to click on the "Close" button when viewing content
-		this.__refreshPage		= false;		// force page refresh after closing Lytebox
-		this.__showPrint		= false;		// true to show print button, false to hide
-		this.__navType			= 3;			// 1 = "Prev/Next" buttons on top left and left
-												// 2 = "Prev/Next" buttons in navigation bar
-												// 3 = navType_1 + navType_2 (show both)
-													
-		// These two options control the position of the title/counter and navigation buttons. Note that for mobile devices,
-		// the title is displayed on top and the navigation on the bottom. This is due to the view area being limited.
-		// You can customize this for non-mobile devices by changing the 2nd condition (: false) to true (: true)
-		this.__navTop			= this.isMobile() ? false : false; // true to show the buttons on the top right, false to show them on bottom right (default)
-		this.__titleTop			= this.isMobile() ? true : false;  // true to show the title on the top left, false to show it on the bottom left (default)
-	
-	
-	/*** Configure HTML Content / Media Viewer Options ***/
-	
-		this.__width			= '100%';		// default width of content viewer
-		this.__height			= '100%';		// default height of content viewer
-		this.__scrolling		= 'auto';		// controls whether or not scrolling is allowed in the content viewer -- options are auto|yes|no
-		this.__loopPlayback		= false;		// controls whether or not embedded media is looped (swf, avi, mov, etc.)
-		this.__autoPlay			= true;			// controls whether or not to autoplay embedded media
-		this.__autoEmbed		= true;			// controls whether or not to automatically embed media in an object tag
-	
-	
-	/*** Configure Slideshow Options ***/
-	
-		this.__slideInterval	= 4000;			// change value (milliseconds) to increase/decrease the time between "slides"
-		this.__showNavigation	= false;		// true to display Next/Prev buttons/text during slideshow, false to hide
-		this.__showClose		= true;			// true to display the Close button, false to hide
-		this.__showDetails		= true;			// true to display image details (caption, count), false to hide
-		this.__showPlayPause	= true;			// true to display pause/play buttons next to close button, false to hide
-		this.__autoEnd			= true;			// true to automatically close Lytebox after the last image is reached, false to keep open
-		this.__pauseOnNextClick	= false;		// true to pause the slideshow when the "Next" button is clicked
-		this.__pauseOnPrevClick = true;			// true to pause the slideshow when the "Prev" button is clicked
-		this.__loopSlideshow	= false;		// true to continuously loop through slides, false otherwise
-	
-	
-	/*** Configure Event Callbacks ***/
-	
-		this.__beforeStart		= '';			// function to call before the viewer starts
-		this.__afterStart		= '';			// function to call after the viewer starts
-		this.__beforeEnd		= '';			// function to call before the viewer ends (after close click)
-		this.__afterEnd			= '';			// function to call after the viewer ends
-	
-		
-	/*** Configure Lytetip (tooltips) Options ***/
-		this.__changeTipCursor 	= true; 		// true to change the cursor to 'help', false to leave default (inhereted)
-		this.__tipDecoration	= 'dotted';		// controls the text-decoration (underline) of the tip link (dotted|solid|none)
-		this.__tipStyle 		= 'classic';	// sets the default tip style if none is specified via data-lyte-options. Possible values are classic, info, help, warning, error
-		this.__tipRelative		= true;			// if true, tips will be positioned relative to the element. if false, tips will be absolutely positioned on the page.
-												// if you are having issues with tooltips not being properly positioned, then set this to false
-
-
-	this.navTypeHash = new Object();
-	this.navTypeHash['Hover_by_type_1'] 	= true;
-	this.navTypeHash['Display_by_type_1'] 	= false;
-	this.navTypeHash['Hover_by_type_2'] 	= false;
-	this.navTypeHash['Display_by_type_2']	= true;
-	this.navTypeHash['Hover_by_type_3'] 	= true;
-	this.navTypeHash['Display_by_type_3'] 	= true;
-	this.resizeWTimerArray		= new Array();
-	this.resizeWTimerCount		= 0;
-	this.resizeHTimerArray		= new Array();
-	this.resizeHTimerCount		= 0;
-	this.changeContentTimerArray= new Array();
-	this.changeContentTimerCount= 0;
-	this.overlayTimerArray		= new Array();
-	this.overlayTimerCount		= 0;
-	this.imageTimerArray		= new Array();
-	this.imageTimerCount		= 0;
-	this.timerIDArray			= new Array();
-	this.timerIDCount			= 0;
-	this.slideshowIDArray		= new Array();
-	this.slideshowIDCount		= 0;
-	this.imageArray	 = new Array();
-	this.slideArray	 = new Array();
-	this.frameArray	 = new Array();
-	this.contentNum = null;
-	this.aPageSize = new Array();
-	this.overlayLoaded = false;
-	this.checkFrame();
-	this.isSlideshow 	= false;
-	this.isLyteframe 	= false;
-	this.tipSet	 		= false;
-	this.ieVersion = this.ffVersion = this.chromeVersion = this.operaVersion = this.safariVersion = -1;
-	this.ie = this.ff = this.chrome = this.opera = this.safari = false;
-	this.setBrowserInfo();
-	this.classAttribute = (((this.ie && this.doc.compatMode == 'BackCompat') || (this.ie && this.ieVersion <= 7)) ? 'className' : 'class');
-	this.classAttribute = (this.ie && (document.documentMode == 8 || document.documentMode == 9)) ? 'class' : this.classAttribute;
-	this.isReady = false;
-	if (bInitialize) {
-		this.http = aHttp;
-		this.bodyOnscroll = document.body.onscroll;
-		if(this.resizeSpeed > 10) { this.resizeSpeed = 10; }
-		if(this.resizeSpeed < 1) { this.resizeSpeed = 1; }
-		var ie8Duration = 2;
-			var isWinXP = (navigator.userAgent.match(/windows nt 5.1/i) || navigator.userAgent.match(/windows nt 5.2/i) ? true : false);
-		this.resizeDuration = (11 - this.resizeSpeed) * (this.ie ? (this.ieVersion >= 9 ? 6 : (this.ieVersion == 8 ? (this.doc.compatMode == 'BackCompat' ? ie8Duration : ie8Duration - 1) : 3)) : 7);
-			this.resizeDuration = this.ff ? (11 - this.resizeSpeed) * (this.ffVersion < 6 ? 3 : (isWinXP ? 6 : 12)) : this.resizeDuration;
-		this.resizeDuration = this.chrome ? (11 - this.resizeSpeed) * 5 : this.resizeDuration;
-		this.resizeDuration = this.safari ? (11 - this.resizeSpeed) * 20 : this.resizeDuration;
-			this.resizeDuration = this.isMobile() ? (11 - this.resizeSpeed) * 2 : this.resizeDuration;
-		if (window.name != 'lbIframe') {
-			this.initialize();
-		}
-	} else {
-		this.http = new Array();
-		if (typeof $ == 'undefined') {
-			$ = function (id) {
-					if ($.cache[id] === undefined) {
-						$.cache[id] = document.getElementById(id) || false;
-					}
-					return $.cache[id];
-				};
-			$.cache = {};
-		}
-	}
-}
-Lytebox.prototype.setBrowserInfo = function() {
-	var ua = navigator.userAgent.toLowerCase();
-	this.chrome = ua.indexOf('chrome') > -1;
-	this.ff = ua.indexOf('firefox') > -1;
-	this.safari = !this.chrome && ua.indexOf('safari') > -1;
-	this.opera = ua.indexOf('opera') > -1;
-	this.ie = /*@cc_on!@*/false;
-	if (this.chrome) {
-		var re = new RegExp("chrome/([0-9]{1,}[\.0-9]{0,})");
-		if (re.exec(ua) != null) {
-			this.chromeVersion = parseInt( RegExp.$1 );
-		}
-	}
-	if (this.ff) {
-		var re = new RegExp("firefox/([0-9]{1,}[\.0-9]{0,})");
-		if (re.exec(ua) != null) {
-			this.ffVersion = parseInt( RegExp.$1 );
-		}
-	}
-	if (this.ie) {
-		var re = new RegExp("msie ([0-9]{1,}[\.0-9]{0,})");
-		if (re.exec(ua) != null) {
-			this.ieVersion = parseInt( RegExp.$1 );
-		}
-	}
-	if (this.opera) {
-		var re = new RegExp("opera/([0-9]{1,}[\.0-9]{0,})");
-		if (re.exec(ua) != null) {
-			this.operaVersion = parseInt( RegExp.$1 );
-		}
-	}
-	if (this.safari) {
-		var re = new RegExp("version/([0-9]{1,}[\.0-9]{0,})");
-		if (re.exec(ua) != null) {
-			this.safariVersion = parseInt( RegExp.$1 );
-		}
-	}
-};
-Lytebox.prototype.initialize = function() {
-	this.updateLyteboxItems();
-	var oBody = this.doc.getElementsByTagName('body').item(0);
-	if (this.doc.$('lbOverlay')) { oBody.removeChild(this.doc.$('lbOverlay')); }
-	if (this.doc.$('lbMain')) {	oBody.removeChild(this.doc.$('lbMain')); }
-	if (this.doc.$('lbLauncher')) { oBody.removeChild(this.doc.$('lbLauncher')); }
-	var oLauncher = this.doc.createElement('a');
-		oLauncher.setAttribute('id','lbLauncher');
-		oLauncher.setAttribute(this.classAttribute, 'lytebox');
-		oLauncher.style.display = 'none';
-		oBody.appendChild(oLauncher);
-	var oOverlay = this.doc.createElement('div');
-		oOverlay.setAttribute('id','lbOverlay');
-		oOverlay.setAttribute(this.classAttribute, this.theme);
-		if (this.ie && (this.ieVersion <= 6 || (this.ieVersion <= 9 && this.doc.compatMode == 'BackCompat'))) {
-			oOverlay.style.position = 'absolute';
-		}
-		oOverlay.style.display = 'none';
-		oBody.appendChild(oOverlay);
-	var oLytebox = this.doc.createElement('div');
-		oLytebox.setAttribute('id','lbMain');
-		oLytebox.style.display = 'none';
-		oBody.appendChild(oLytebox);
-	var oOuterContainer = this.doc.createElement('div');
-		oOuterContainer.setAttribute('id','lbOuterContainer');
-		oOuterContainer.setAttribute(this.classAttribute, this.theme);
-		if (this.roundedBorder) {
-			oOuterContainer.style.MozBorderRadius = '8px';
-			oOuterContainer.style.borderRadius = '8px';
-		}
-		oLytebox.appendChild(oOuterContainer);
-	var oTopContainer = this.doc.createElement('div');
-		oTopContainer.setAttribute('id','lbTopContainer');
-		oTopContainer.setAttribute(this.classAttribute, this.theme);
-		if (this.roundedBorder) {
-			oTopContainer.style.MozBorderRadius = '8px';
-			oTopContainer.style.borderRadius = '8px';
-		}
-		oOuterContainer.appendChild(oTopContainer);
-	var oTopData = this.doc.createElement('div');
-		oTopData.setAttribute('id','lbTopData');
-		oTopData.setAttribute(this.classAttribute, this.theme);
-		oTopContainer.appendChild(oTopData);
-	var oTitleTop = this.doc.createElement('span');
-		oTitleTop.setAttribute('id','lbTitleTop');
-		oTopData.appendChild(oTitleTop);
-	var oNumTop = this.doc.createElement('span');
-		oNumTop.setAttribute('id','lbNumTop');
-		oTopData.appendChild(oNumTop);
-	var oTopNav = this.doc.createElement('div');
-		oTopNav.setAttribute('id','lbTopNav');
-		oTopContainer.appendChild(oTopNav);
-	var oCloseTop = this.doc.createElement('a');
-		oCloseTop.setAttribute('id','lbCloseTop');
-		oCloseTop.setAttribute('title', this.label['close']);
-		oCloseTop.setAttribute(this.classAttribute, this.theme);
-		oCloseTop.setAttribute('href','javascript:void(0)');
-		oTopNav.appendChild(oCloseTop);
-	var oPrintTop = this.doc.createElement('a');
-		oPrintTop.setAttribute('id','lbPrintTop')
-		oPrintTop.setAttribute('title', this.label['print']);
-		oPrintTop.setAttribute(this.classAttribute, this.theme);
-		oPrintTop.setAttribute('href','javascript:void(0)');
-		oTopNav.appendChild(oPrintTop);
-	var oNextTop = this.doc.createElement('a');
-		oNextTop.setAttribute('id','lbNextTop');
-		oNextTop.setAttribute('title', this.label['next']);
-		oNextTop.setAttribute(this.classAttribute, this.theme);
-		oNextTop.setAttribute('href','javascript:void(0)');
-		oTopNav.appendChild(oNextTop);
-	var oPauseTop = this.doc.createElement('a');
-		oPauseTop.setAttribute('id','lbPauseTop');
-		oPauseTop.setAttribute('title', this.label['pause']);
-		oPauseTop.setAttribute(this.classAttribute, this.theme);
-		oPauseTop.setAttribute('href','javascript:void(0)');
-		oPauseTop.style.display = 'none';
-		oTopNav.appendChild(oPauseTop);
-	var oPlayTop = this.doc.createElement('a');
-		oPlayTop.setAttribute('id','lbPlayTop');
-		oPlayTop.setAttribute('title', this.label['play']);
-		oPlayTop.setAttribute(this.classAttribute, this.theme);
-		oPlayTop.setAttribute('href','javascript:void(0)');
-		oPlayTop.style.display = 'none';
-		oTopNav.appendChild(oPlayTop);
-	var oPrevTop = this.doc.createElement('a');
-		oPrevTop.setAttribute('id','lbPrevTop');
-		oPrevTop.setAttribute('title', this.label['prev']);
-		oPrevTop.setAttribute(this.classAttribute, this.theme);
-		oPrevTop.setAttribute('href','javascript:void(0)');
-		oTopNav.appendChild(oPrevTop);
-	var oIframeContainer = this.doc.createElement('div');
-		oIframeContainer.setAttribute('id','lbIframeContainer');
-		oIframeContainer.style.display = 'none';
-		oOuterContainer.appendChild(oIframeContainer);
-	var oIframe = this.doc.createElement('iframe');
-		oIframe.setAttribute('id','lbIframe');
-		oIframe.setAttribute('name','lbIframe')
-		oIframe.setAttribute('frameBorder','0');
-		if (this.innerBorder) {
-			oIframe.setAttribute(this.classAttribute, this.theme);
-		}
-		oIframe.style.display = 'none';
-		oIframeContainer.appendChild(oIframe);
-	var oImageContainer = this.doc.createElement('div');
-		oImageContainer.setAttribute('id','lbImageContainer');
-		oOuterContainer.appendChild(oImageContainer);
-	var oLyteboxImage = this.doc.createElement('img');
-		oLyteboxImage.setAttribute('id','lbImage');
-		if (this.innerBorder) {
-			oLyteboxImage.setAttribute(this.classAttribute, this.theme);
-		}
-		oImageContainer.appendChild(oLyteboxImage);
-	var oLoading = this.doc.createElement('div');
-		oLoading.setAttribute('id','lbLoading');
-		oLoading.setAttribute(this.classAttribute, this.theme);
-		oOuterContainer.appendChild(oLoading);
-	var oBottomContainer = this.doc.createElement('div');
-		oBottomContainer.setAttribute('id','lbBottomContainer');
-		oBottomContainer.setAttribute(this.classAttribute, this.theme);
-		if (this.roundedBorder) {
-			oBottomContainer.style.MozBorderRadius = '8px';
-			oBottomContainer.style.borderRadius = '8px';
-		}
-		oOuterContainer.appendChild(oBottomContainer);
-	var oDetailsBottom = this.doc.createElement('div');
-		oDetailsBottom.setAttribute('id','lbBottomData');
-		oDetailsBottom.setAttribute(this.classAttribute, this.theme);
-		oBottomContainer.appendChild(oDetailsBottom);
-	var oTitleBottom = this.doc.createElement('span');
-		oTitleBottom.setAttribute('id','lbTitleBottom');
-		oDetailsBottom.appendChild(oTitleBottom);
-	var oNumBottom = this.doc.createElement('span');
-		oNumBottom.setAttribute('id','lbNumBottom');
-		oDetailsBottom.appendChild(oNumBottom);
-	var oDescBottom = this.doc.createElement('span');
-		oDescBottom.setAttribute('id','lbDescBottom');
-		oDetailsBottom.appendChild(oDescBottom);
-	var oHoverNav = this.doc.createElement('div');
-		oHoverNav.setAttribute('id','lbHoverNav');
-		oImageContainer.appendChild(oHoverNav);
-	var oBottomNav = this.doc.createElement('div');
-		oBottomNav.setAttribute('id','lbBottomNav');
-		oBottomContainer.appendChild(oBottomNav);
-	var oPrevHov = this.doc.createElement('a');
-		oPrevHov.setAttribute('id','lbPrevHov');
-		oPrevHov.setAttribute('title', this.label['prev']);
-		oPrevHov.setAttribute(this.classAttribute, this.theme);
-		oPrevHov.setAttribute('href','javascript:void(0)');
-		oHoverNav.appendChild(oPrevHov);
-	var oNextHov = this.doc.createElement('a');
-		oNextHov.setAttribute('id','lbNextHov');
-		oNextHov.setAttribute('title', this.label['next']);
-		oNextHov.setAttribute(this.classAttribute, this.theme);
-		oNextHov.setAttribute('href','javascript:void(0)');
-		oHoverNav.appendChild(oNextHov);
-	var oClose = this.doc.createElement('a');
-		oClose.setAttribute('id','lbClose');
-		oClose.setAttribute('title', this.label['close']);
-		oClose.setAttribute(this.classAttribute, this.theme);
-		oClose.setAttribute('href','javascript:void(0)');
-		oBottomNav.appendChild(oClose);
-	var oPrint = this.doc.createElement('a');
-		oPrint.setAttribute('id','lbPrint');
-		oPrint.setAttribute('title', this.label['print']);
-		oPrint.setAttribute(this.classAttribute, this.theme);
-		oPrint.setAttribute('href','javascript:void(0)');
-		oPrint.style.display = 'none';
-		oBottomNav.appendChild(oPrint);
-	var oNext = this.doc.createElement('a');
-		oNext.setAttribute('id','lbNext');
-		oNext.setAttribute('title', this.label['next']);
-		oNext.setAttribute(this.classAttribute, this.theme);
-		oNext.setAttribute('href','javascript:void(0)');
-		oBottomNav.appendChild(oNext);
-	var oPause = this.doc.createElement('a');
-		oPause.setAttribute('id','lbPause');
-		oPause.setAttribute('title', this.label['pause']);
-		oPause.setAttribute(this.classAttribute, this.theme);
-		oPause.setAttribute('href','javascript:void(0)');
-		oPause.style.display = 'none';
-		oBottomNav.appendChild(oPause);
-	var oPlay = this.doc.createElement('a');
-		oPlay.setAttribute('id','lbPlay');
-		oPlay.setAttribute('title', this.label['play']);
-		oPlay.setAttribute(this.classAttribute, this.theme);
-		oPlay.setAttribute('href','javascript:void(0)');
-		oPlay.style.display = 'none';
-		oBottomNav.appendChild(oPlay);
-	var oPrev = this.doc.createElement('a');
-		oPrev.setAttribute('id','lbPrev');
-		oPrev.setAttribute('title', this.label['prev']);
-		oPrev.setAttribute(this.classAttribute, this.theme);
-		oPrev.setAttribute('href','javascript:void(0)');
-		oBottomNav.appendChild(oPrev);
-	var iframes = (this.isFrame && window.parent.frames[window.name].document) ? window.parent.frames[window.name].document.getElementsByTagName('iframe') : document.getElementsByTagName('iframe');
-	for (var i = 0; i < iframes.length; i++) {
-		if (/youtube/i.test(iframes[i].src)) {
-			iframes[i].src += ((/\?/.test(iframes[i].src)) ? '&' : '?') + 'wmode=transparent';
-		}
-	}
-	this.isReady = true;
-};
-Lytebox.prototype.updateLyteboxItems = function() {
-	var anchors = (this.isFrame && window.parent.frames[window.name].document) ? window.parent.frames[window.name].document.getElementsByTagName('a') : document.getElementsByTagName('a');
-		anchors = (this.isFrame) ? anchors : document.getElementsByTagName('a');
-	var areas = (this.isFrame && window.parent.frames[window.name].document) ? window.parent.frames[window.name].document.getElementsByTagName('area') : document.getElementsByTagName('area');
-	var lyteLinks = this.combine(anchors, areas);
-	var myLink = relAttribute = revAttribute = classAttribute = dataOptions = dataTip = tipDecoration = tipStyle = tipImage = tipHtml = aSetting = sName = sValue = sExt = aUrl = null;
-	var bImage = bRelative = false;
-	for (var i = 0; i < lyteLinks.length; i++) {
-		myLink = lyteLinks[i];
-		relAttribute = String(myLink.getAttribute('rel'));
-		classAttribute = String(myLink.getAttribute(this.classAttribute));
-		if (myLink.getAttribute('href')) {
-			sType = classAttribute.match(/lytebox|lyteshow|lyteframe/i);
-			sType = this.isEmpty(sType) ? relAttribute.match(/lytebox|lyteshow|lyteframe/i) : sType;
-			dataOptions = String(myLink.getAttribute('data-lyte-options'));
-			dataOptions = this.isEmpty(dataOptions) ? String(myLink.getAttribute('rev')) : dataOptions;
-			aUrl = myLink.getAttribute('href').split('?');
-			sExt = aUrl[0].split('.').pop().toLowerCase();
-			bImage = (sExt == 'png' || sExt == 'jpg' || sExt == 'jpeg' || sExt == 'gif' || sExt == 'bmp');
-			if (sType && sType.length >= 1) {
-				if (this.isMobile() && /youtube/i.test(myLink.getAttribute('href'))) {
-					myLink.target = '_blank';
-				} else if (bImage && (dataOptions.match(/slide:true/i) || sType[0].toLowerCase() == 'lyteshow')) {
-					myLink.onclick = function () { $lb.start(this, true, false); return false; }
-				} else if (bImage) {
-					myLink.onclick = function () { $lb.start(this, false, false); return false; }
-				} else {
-					myLink.onclick = function () { $lb.start(this, false, true); return false; }
-				}
-			}
-			dataTip = String(myLink.getAttribute('data-tip'));
-			dataTip = this.isEmpty(dataTip) ? myLink.getAttribute('title') : dataTip;
-			if (classAttribute.toLowerCase().match('lytetip') && !this.isEmpty(dataTip) && !this.tipsSet) {
-				if (this.__changeTipCursor) { myLink.style.cursor = 'help'; }
-				tipDecoration = this.__tipDecoration;
-				tipStyle = this.__tipStyle;
-				bRelative = this.__tipRelative;
-				if (!this.isEmpty(dataOptions)) {
-					aOptions = dataOptions.split(' ');
-					for (var j = 0; j < aOptions.length; j++) {
-						aSetting = aOptions[j].split(':');
-						sName = (aSetting.length > 1 ? this.trim(aSetting[0]).toLowerCase() : '');
-						sValue = (aSetting.length > 1 ? this.trim(aSetting[1]) : '');
-						switch(sName) {
-							case 'tipstyle':
-								tipStyle = (/classic|info|help|warning|error/.test(sValue) ? sValue : tipStyle); break;
-							case 'changetipcursor':
-								myLink.style.cursor = (/true|false/.test(sValue) ? (sValue == 'true' ? 'help' : '') : myLink.style.cursor); break;
-							case 'tiprelative':
-								bRelative = (/true|false/.test(sValue) ? (sValue == 'true') : bRelative); break;
-							case 'tipdecoration':
-								tipDecoration = (/dotted|solid|none/.test(sValue) ? sValue : tipDecoration); break;
-						}
-					}
-				}
-				if (tipDecoration != 'dotted') {
-					myLink.style.borderBottom = (tipDecoration == 'solid' ? '1px solid' : 'none');
-				}
-				switch(tipStyle) {
-					case 'info': tipStyle = 'lbCustom lbInfo'; tipImage = 'lbTipImg lbInfoImg'; break;
-					case 'help': tipStyle = 'lbCustom lbHelp'; tipImage = 'lbTipImg lbHelpImg'; break;
-					case 'warning': tipStyle = 'lbCustom lbWarning'; tipImage = 'lbTipImg lbWarningImg'; break;
-					case 'error': tipStyle = 'lbCustom lbError'; tipImage = 'lbTipImg lbErrorImg'; break;
-					case 'classic': tipStyle = 'lbClassic'; tipImage = ''; break;
-					default: tipStyle = 'lbClassic'; tipImage = '';
-				}
-				if ((this.ie && this.ieVersion <= 7) || (this.ieVersion == 8 && this.doc.compatMode == 'BackCompat')) {
-					tipImage = '';
-					if (tipStyle != 'lbClassic' && !this.isEmpty(tipStyle)) {
-						tipStyle += ' lbIEFix';
-					}
-				}
-				var aLinkPos = this.findPos(myLink);
-				if ((this.ie && (this.ieVersion <= 6 || this.doc.compatMode == 'BackCompat')) || bRelative) {
-					myLink.style.position = 'relative';
-				}
-				tipHtml = myLink.innerHTML;
-				myLink.innerHTML = '';
-				if ((this.ie && this.ieVersion <= 6 && this.doc.compatMode != 'BackCompat') || bRelative) {
-					myLink.innerHTML = tipHtml + '<span class="' + tipStyle + '">' + (tipImage ? '<div class="' + tipImage + '"></div>' : '') + dataTip + '</span>';
-				} else {
-					myLink.innerHTML = tipHtml + '<span class="' + tipStyle + '" style="left:'+aLinkPos[0]+'px;top:'+(aLinkPos[1]+aLinkPos[2])+'px;">' + (tipImage ? '<div class="' + tipImage + '"></div>' : '') + dataTip + '</span>';
-				}
-				if (classAttribute.match(/lytebox|lyteshow|lyteframe/i) == null) {
-					myLink.setAttribute('title','');
-				}
-			}
-		}
-	}
-	this.tipsSet = true;
-};
-Lytebox.prototype.launch = function(args) {
-	var sUrl = this.isEmpty(args.url) ? '' : String(args.url);
-	var sOptions = this.isEmpty(args.options) ? '' : String(args.options);
-	var sTitle = this.isEmpty(args.title) ? '' : args.title;
-	var sDesc = this.isEmpty(args.description) ? '' : args.description;
-	var bSlideshow = /slide:true/i.test(sOptions);
-	if (this.isEmpty(sUrl)) {
-		return false;
-	}
-	if (!this.isReady) {
-		this.timerIDArray[this.timerIDCount++] = setTimeout("$lb.launch({ url: '" + sUrl + "', options: '" + sOptions + "', title: '" + sTitle + "', description: '" + sDesc + "' })", 100);
-		return;
-	} else {
-		for (var i = 0; i < this.timerIDCount; i++) { window.clearTimeout(this.timerIDArray[i]); }
-	}
-	var aUrl = sUrl.split('?');
-	var sExt = aUrl[0].split('.').pop().toLowerCase();
-	var bImage = (sExt == 'png' || sExt == 'jpg' || sExt == 'jpeg' || sExt == 'gif' || sExt == 'bmp');
-	var oLauncher = this.doc.$('lbLauncher');
-		oLauncher.setAttribute('href', sUrl);
-		oLauncher.setAttribute('data-lyte-options', sOptions);
-		oLauncher.setAttribute('data-title', sTitle);
-		oLauncher.setAttribute('data-description', sDesc);
-	this.updateLyteboxItems();
-	this.start(oLauncher, bSlideshow, (bImage ? false : true));
-};
-Lytebox.prototype.start = function(oLink, bSlideshow, bFrame) {
-	var dataOptions = String(oLink.getAttribute('data-lyte-options'));
-		dataOptions = this.isEmpty(dataOptions) ? String(oLink.getAttribute('rev')) : dataOptions;
-	this.setOptions(dataOptions);
-	this.isSlideshow = (bSlideshow ? true : false);
-	this.isLyteframe = (bFrame ? true : false);
-	this.isPaused=true;
-	if (!this.isEmpty(this.beforeStart)) {
-		var callback = window[this.beforeStart];
-		if (typeof callback === 'function') {
-			if (!callback(this.args)) { return; }
-		}
-	}
-	if (this.ie && this.ieVersion <= 6) { this.toggleSelects('hide'); }
-	if (this.hideObjects) { this.toggleObjects('hide'); }
-	if (this.isFrame && window.parent.frames[window.name].document) {
-		window.parent.$lb.printId = (this.isLyteframe ? 'lbIframe' : 'lbImage');
-	} else {
-		this.printId = (this.isLyteframe ? 'lbIframe' : 'lbImage');
-	}
-	this.aPageSize	= this.getPageSize();
-	var objOverlay	= this.doc.$('lbOverlay');
-	var objBody		= this.doc.getElementsByTagName("body").item(0);
-	objOverlay.style.height = this.aPageSize[1] + "px";
-	objOverlay.style.display = '';
-	this.fadeIn({ id: 'lbOverlay', opacity: (this.doAnimations && this.animateOverlay && (!this.ie || this.ieVersion >= 9) ? 0 : this.maxOpacity) });
-	var anchors = (this.isFrame && window.parent.frames[window.name].document) ? window.parent.frames[window.name].document.getElementsByTagName('a') : document.getElementsByTagName('a');
-		anchors = (this.isFrame) ? anchors : document.getElementsByTagName('a');
-	var areas = (this.isFrame && window.parent.frames[window.name].document) ? window.parent.frames[window.name].document.getElementsByTagName('area') : document.getElementsByTagName('area');
-	var lyteLinks = this.combine(anchors, areas);
-	var sType = sExt = aUrl = null;
-	this.frameArray = [];
-	this.frameNum = 0;
-	this.imageArray = [];
-	this.imageNum = 0;
-	this.slideArray = [];
-	this.slideNum = 0;
-	if (this.isEmpty(this.group)) {
-		dataOptions = String(oLink.getAttribute('data-lyte-options'));
-		dataOptions = this.isEmpty(dataOptions) ? String(oLink.getAttribute('rev')) : dataOptions;
-		if (this.isLyteframe) {			
-			this.frameArray.push(new Array(oLink.getAttribute('href'), (!this.isEmpty(oLink.getAttribute('data-title')) ? oLink.getAttribute('data-title') : oLink.getAttribute('title')), oLink.getAttribute('data-description'), dataOptions));
-		} else {
-			this.imageArray.push(new Array(oLink.getAttribute('href'), (!this.isEmpty(oLink.getAttribute('data-title')) ? oLink.getAttribute('data-title') : oLink.getAttribute('title')), oLink.getAttribute('data-description'), dataOptions));
-		}
-	} else {
-		for (var i = 0; i < lyteLinks.length; i++) {
-			var myLink = lyteLinks[i];
-			dataOptions = String(myLink.getAttribute('data-lyte-options'));
-			dataOptions = this.isEmpty(dataOptions) ? String(myLink.getAttribute('rev')) : dataOptions;
-			if (myLink.getAttribute('href') && dataOptions.toLowerCase().match('group:' + this.group)) {
-				sType = String(myLink.getAttribute(this.classAttribute)).match(/lytebox|lyteshow|lyteframe/i);
-				sType = this.isEmpty(sType) ? myLink.getAttribute('rel').match(/lytebox|lyteshow|lyteframe/i) : sType;
-				aUrl = myLink.getAttribute('href').split('?');
-				sExt = aUrl[0].split('.').pop().toLowerCase();
-				bImage = (sExt == 'png' || sExt == 'jpg' || sExt == 'jpeg' || sExt == 'gif' || sExt == 'bmp');
-				if (sType && sType.length >= 1) {
-					if (bImage && (dataOptions.match(/slide:true/i) || sType[0].toLowerCase() == 'lyteshow')) {
-						this.slideArray.push(new Array(myLink.getAttribute('href'), (!this.isEmpty(myLink.getAttribute('data-title')) ? myLink.getAttribute('data-title') : myLink.getAttribute('title')), myLink.getAttribute('data-description'), dataOptions));
-					} else if (bImage) {
-						this.imageArray.push(new Array(myLink.getAttribute('href'), (!this.isEmpty(myLink.getAttribute('data-title')) ? myLink.getAttribute('data-title') : myLink.getAttribute('title')), myLink.getAttribute('data-description'), dataOptions));
-					} else {
-						this.frameArray.push(new Array(myLink.getAttribute('href'), (!this.isEmpty(myLink.getAttribute('data-title')) ? myLink.getAttribute('data-title') : myLink.getAttribute('title')), myLink.getAttribute('data-description'), dataOptions));
-					}
-				}
-			}
-		}
-		if (this.isLyteframe) {
-			this.frameArray = this.removeDuplicates(this.frameArray);
-			while(this.frameArray[this.frameNum][0] != oLink.getAttribute('href')) { this.frameNum++; }
-		} else if (bSlideshow) {
-			this.slideArray = this.removeDuplicates(this.slideArray);
-			try {
-				while(this.slideArray[this.slideNum][0] != oLink.getAttribute('href')) { this.slideNum++; }
-			} catch(e) {
-			}
-		} else {
-			this.imageArray = this.removeDuplicates(this.imageArray);
-			while(this.imageArray[this.imageNum][0] != oLink.getAttribute('href')) { this.imageNum++; }
-		}
-	}
-	this.changeContent(this.isLyteframe ? this.frameNum : (this.isSlideshow ? this.slideNum : this.imageNum));
-};
-Lytebox.prototype.changeContent = function(iContentNum) {
-	this.contentNum = iContentNum;
-	if (!this.overlayLoaded) {
-		this.changeContentTimerArray[this.changeContentTimerCount++] = setTimeout("$lb.changeContent(" + this.contentNum + ")", 250);
-		return;
-	} else {
-		for (var i = 0; i < this.changeContentTimerCount; i++) { window.clearTimeout(this.changeContentTimerArray[i]); }
-	}
-	var sDataLyteOptions = (this.isLyteframe) ? this.frameArray[this.contentNum][3] : (this.isSlideshow ? this.slideArray[this.contentNum][3] : this.imageArray[this.contentNum][3]);
-	if (!this.inherit || /inherit:false/i.test(sDataLyteOptions)) {
-		this.setOptions(String(sDataLyteOptions));
-	} else {
-		var sDataLyteOptions1 = String((this.isLyteframe) ? this.frameArray[0][3] : (this.isSlideshow ? this.slideArray[0][3] : this.imageArray[0][3]));
-		if (this.isLyteframe) {
-			var sWidth = sHeight = null;
-			try { sWidth = sDataLyteOptions.match(/width:\d+(%|px|)/i)[0]; } catch(e) { }
-			try { sHeight = sDataLyteOptions.match(/height:\d+(%|px|)/i)[0]; } catch(e) { }
-			if (!this.isEmpty(sWidth)) {
-				sDataLyteOptions1 = sDataLyteOptions1.replace(/width:\d+(%|px|)/i, sWidth);
-			}
-			if (!this.isEmpty(sHeight)) {
-				sDataLyteOptions1 = sDataLyteOptions1.replace(/height:\d+(%|px|)/i, sHeight);
-			}
-		}
-		this.setOptions(sDataLyteOptions1);
-	}
-	var object = this.doc.$('lbMain');
-		object.style.display = '';
-	var iDivisor = 200;
-	if (this.autoResize && this.fixedPosition) {
-		if (this.ie && (this.ieVersion <= 7 || this.doc.compatMode == 'BackCompat')) {
-			object.style.top = (this.getPageScroll() + (this.aPageSize[3] / iDivisor)) + "px";
-			var ps = (this.aPageSize[3] / iDivisor);
-			this.scrollHandler = function(){
-				$lb.doc.$('lbMain').style.top = ($lb.getPageScroll() + ps) + 'px';
-			}
-			this.bodyOnscroll = document.body.onscroll;
-			if (window.addEventListener) {
-				window.addEventListener('scroll', this.scrollHandler);
-			} else if (window.attachEvent) {
-				window.attachEvent('onscroll', this.scrollHandler);
-			}
-			object.style.position = "absolute";
-		} else {
-			object.style.top = ((this.aPageSize[3] / iDivisor)) + "px";
-			object.style.position = "fixed";
-		}
-	} else {
-		object.style.position = "absolute";
-		object.style.top = (this.getPageScroll() + (this.aPageSize[3] / iDivisor)) + "px";
-	}
-	this.doc.$('lbOuterContainer').style.paddingBottom = '0';
-	if (!this.outerBorder) {
-		this.doc.$('lbOuterContainer').style.border = 'none';
-	} else {
-		this.doc.$('lbOuterContainer').setAttribute(this.classAttribute, this.theme);
-	}
-	if (this.forceCloseClick) {
-		this.doc.$('lbOverlay').onclick = '';
-	} else {
-		this.doc.$('lbOverlay').onclick = function() { $lb.end(); return false; }
-	}
-	this.doc.$('lbMain').onclick = function(e) {
-		var e = e;
-		if (!e) {
-			if (window.parent.frames[window.name] && (parent.document.getElementsByTagName('frameset').length <= 0)) {
-				e = window.parent.window.event;
-			} else {
-				e = window.event;
-			}
-		}
-		var id = (e.target ? e.target.id : e.srcElement.id);
-		if ((id == 'lbMain') && (!$lb.forceCloseClick)) { $lb.end(); return false; }
-	}
-	this.doc.$('lbPrintTop').onclick = this.doc.$('lbPrint').onclick = function() { $lb.printWindow(); return false; }
-	this.doc.$('lbCloseTop').onclick = this.doc.$('lbClose').onclick = function() { $lb.end(); return false; }
-	this.doc.$('lbPauseTop').onclick = function() { $lb.togglePlayPause("lbPauseTop", "lbPlayTop"); return false; }
-	this.doc.$('lbPause').onclick = function() { $lb.togglePlayPause("lbPause", "lbPlay"); return false; }
-	this.doc.$('lbPlayTop').onclick = function() { $lb.togglePlayPause("lbPlayTop", "lbPauseTop"); return false; }
-	this.doc.$('lbPlay').onclick = function() { $lb.togglePlayPause("lbPlay", "lbPause"); return false; }
-	if (this.isSlideshow && this.showPlayPause && this.isPaused) {
-		this.doc.$('lbPlay').style.display = '';
-		this.doc.$('lbPause').style.display = 'none';
-	}
-	if (this.isSlideshow) {
-		for (var i = 0; i < this.slideshowIDCount; i++) { window.clearTimeout(this.slideshowIDArray[i]); }
-	}
-	if (!this.outerBorder) {
-		this.doc.$('lbOuterContainer').style.border = 'none';
-	} else {
-		this.doc.$('lbOuterContainer').setAttribute(this.classAttribute, this.theme);
-	}
-	var iDecreaseMargin = 10;
-	if (this.titleTop || this.navTop) {
-		this.doc.$('lbTopContainer').style.visibility = 'hidden';
-		iDecreaseMargin += this.doc.$('lbTopContainer').offsetHeight;
-	} else {
-		this.doc.$('lbTopContainer').style.display = 'none';
-	}
-	this.doc.$('lbBottomContainer').style.display = 'none';
-	this.doc.$('lbImage').style.display = 'none';
-	this.doc.$('lbIframe').style.display = 'none';
-	this.doc.$('lbPrevHov').style.display = 'none';
-	this.doc.$('lbNextHov').style.display =  'none';
-	this.doc.$('lbIframeContainer').style.display = 'none';
-	this.doc.$('lbLoading').style.marginTop = '-' + iDecreaseMargin + 'px';
-	this.doc.$('lbLoading').style.display = '';
-	if (this.isLyteframe) {
-		var iframe = $lb.doc.$('lbIframe');
-			iframe.src = 'about:blank';
-		var w = this.trim(this.width);
-		var h = this.trim(this.height);
-		if (/\%/.test(w)) {
-			var percent = parseInt(w);
-			w = parseInt((this.aPageSize[2]-50)*percent/100);
-			w = w+'px';
-		}
-		if (/\%/.test(h)) {
-			var percent = parseInt(h);
-			h = parseInt((this.aPageSize[3]-150)*percent/100);
-			h = h+'px';
-		}
-		if (this.autoResize) {
-			var x = this.aPageSize[2] - 50;
-			var y = this.aPageSize[3] - 150;
-			w = (parseInt(w) > x ? x : w) + 'px';
-			h = (parseInt(h) > y ? y : h) + 'px';
-		}
-		iframe.height = this.height = h;
-		iframe.width = this.width = w;
-		iframe.scrolling = this.scrolling;
-		var oDoc = iframe.contentWindow || iframe.contentDocument;
-		try {
-			if (oDoc.document) {
-				oDoc = oDoc.document;
-			}
-			oDoc.body.style.margin = 0;
-			oDoc.body.style.padding = 0;
-			if (this.ie && this.ieVersion <= 8) {
-				oDoc.body.scroll = this.scrolling;
-				oDoc.body.overflow = this.scrolling = 'no' ? 'hidden' : 'auto';
-			}
-		} catch(e) { }
-		this.resizeContainer(parseInt(this.width), parseInt(this.height));
-	} else {
-		this.imgPreloader = new Image();
-		this.imgPreloader.onload = function() {
-			var imageWidth = $lb.imgPreloader.width;
-			var imageHeight = $lb.imgPreloader.height;
-			if ($lb.autoResize) {
-				var x = $lb.aPageSize[2] - 10;
-				var y = $lb.aPageSize[3] - 60;
-				if (imageWidth > x) {
-					imageHeight = Math.round(imageHeight * (x / imageWidth));
-					imageWidth = x; 
-					if (imageHeight > y) { 
-						imageWidth = Math.round(imageWidth * (y / imageHeight));
-						imageHeight = y; 
-					}
-				} else if (imageHeight > y) { 
-					imageWidth = Math.round(imageWidth * (y / imageHeight));
-					imageHeight = y; 
-					if (imageWidth > x) {
-						imageHeight = Math.round(imageHeight * (x / imageWidth));
-						imageWidth = x;
-					}
-				}
-			}
-			var lbImage = $lb.doc.$('lbImage');
-			lbImage.src = $lb.imgPreloader.src;
-			lbImage.width = imageWidth;
-			lbImage.height = imageHeight;
-			$lb.resizeContainer(imageWidth, imageHeight);
-			$lb.imgPreloader.onload = function() {};
-		}
-		this.imgPreloader.src = (this.isSlideshow ? this.slideArray[this.contentNum][0] : this.imageArray[this.contentNum][0]);
-	}
-};
-Lytebox.prototype.resizeContainer = function(iWidth, iHeight) {
-	this.resizeWidth = iWidth;
-	this.resizeHeight = iHeight;
-	this.wCur = this.doc.$('lbOuterContainer').offsetWidth;
-	this.hCur = this.doc.$('lbOuterContainer').offsetHeight;
-	this.xScale = ((this.resizeWidth  + (this.borderSize * 2)) / this.wCur) * 100;
-	this.yScale = ((this.resizeHeight  + (this.borderSize * 2)) / this.hCur) * 100;
-	var wDiff = (this.wCur - this.borderSize * 2) - this.resizeWidth;
-	var hDiff = (this.hCur - this.borderSize * 2) - this.resizeHeight;
-	this.wDone = (wDiff == 0);
-	if (!(hDiff == 0)) {
-		this.hDone = false;
-		this.resizeH('lbOuterContainer', this.hCur, this.resizeHeight + this.borderSize * 2, this.getPixelRate(this.hCur, this.resizeHeight));
-	} else {
-		this.hDone = true;
-		if (!this.wDone) {
-			this.resizeW('lbOuterContainer', this.wCur, this.resizeWidth + this.borderSize * 2, this.getPixelRate(this.wCur, this.resizeWidth));
-		}
-	}
-	if ((hDiff == 0) && (wDiff == 0)) {
-		if (this.ie){ this.pause(250); } else { this.pause(100); } 
-	}
-	this.doc.$('lbPrevHov').style.height = this.resizeHeight + "px";
-	this.doc.$('lbNextHov').style.height = this.resizeHeight + "px";
-	if (this.hDone && this.wDone) {
-		if (this.isLyteframe) {
-			this.loadContent();
-		} else {
-			this.showContent();
-		}
-	}
-};
-Lytebox.prototype.loadContent = function() {
-	try {
-		var iframe = this.doc.$('lbIframe');
-		var uri = this.frameArray[this.contentNum][0];
-		if (!this.inline && this.appendQS) {
-			uri += ((/\?/.test(uri)) ? '&' : '?') + 'request_from=lytebox';
-		}
-		if (this.autoPlay && /youtube/i.test(uri)) {
-			uri += ((/\?/.test(uri)) ? '&' : '?') + 'autoplay=1';
-		}
-			if (!this.autoEmbed || (this.ff && (uri.match(/.pdf|.mov|.wmv/i)))) {
-			this.frameSource = uri;
-			this.showContent();
-			return;
-		}
-		if (this.ie) {
-			iframe.onreadystatechange = function() {
-				if ($lb.doc.$('lbIframe').readyState == "complete") {
-					$lb.showContent();
-					$lb.doc.$('lbIframe').onreadystatechange = null;
-				}
-			};
-		} else {
-			iframe.onload = function() {
-				$lb.showContent();
-				$lb.doc.$('lbIframe').onload = null;
-			};
-		}
-		if (this.inline || (uri.match(/.mov|.avi|.wmv|.mpg|.mpeg|.swf/i))) {
-			iframe.src = 'about:blank';
-			this.frameSource = '';
-			var sHtml = (this.inline) ? this.doc.$(uri.substr(uri.indexOf('#') + 1, uri.length)).innerHTML : this.buildObject(parseInt(this.width), parseInt(this.height), uri);
-			var oDoc = iframe.contentWindow || iframe.contentDocument;
-			if (oDoc.document) {
-				oDoc = oDoc.document;
-			}
-			oDoc.open();
-			oDoc.write(sHtml);
-			oDoc.close();
-			oDoc.body.style.margin = 0;
-			oDoc.body.style.padding = 0;
-			if (!this.inline) {
-				oDoc.body.style.backgroundColor = '#fff';
-				oDoc.body.style.fontFamily = 'Verdana, Helvetica, sans-serif';
-				oDoc.body.style.fontSize = '0.9em';
-			}
-			this.frameSource = '';
-		} else {
-			this.frameSource = uri;
-			iframe.src = uri;
-		}
-	} catch(e) { }
-};
-Lytebox.prototype.showContent = function() {
-	if (this.isSlideshow) {
-		if(this.contentNum == (this.slideArray.length - 1)) {
-			if (this.loopSlideshow) {
-				this.slideshowIDArray[this.slideshowIDCount++] = setTimeout("$lb.changeContent(0)", this.slideInterval);
-			} else if (this.autoEnd) {
-				this.slideshowIDArray[this.slideshowIDCount++] = setTimeout("$lb.end('slideshow')", this.slideInterval);
-			}
-		} else {
-			if (!this.isPaused) {
-				this.slideshowIDArray[this.slideshowIDCount++] = setTimeout("$lb.changeContent("+(this.contentNum+1)+")", this.slideInterval);
-			}
-		}
-		this.doc.$('lbHoverNav').style.display = (this.ieVersion != 6 && this.showNavigation && this.navTypeHash['Hover_by_type_' + this.navType] ? '' : 'none');
-		this.doc.$('lbCloseTop').style.display = (this.showClose && this.navTop ? '' : 'none');
-		this.doc.$('lbClose').style.display = (this.showClose && !this.navTop ? '' : 'none');
-		this.doc.$('lbBottomData').style.display = (this.showDetails ? '' : 'none');
-		this.doc.$('lbPauseTop').style.display = (this.showPlayPause && this.navTop ? (!this.isPaused ? '' : 'none') : 'none');
-		this.doc.$('lbPause').style.display = (this.showPlayPause && !this.navTop ? (!this.isPaused ? '' : 'none') : 'none');
-		this.doc.$('lbPlayTop').style.display = (this.showPlayPause && this.navTop ? (!this.isPaused ? 'none' : '') : 'none');
-		this.doc.$('lbPlay').style.display = (this.showPlayPause && !this.navTop ? (!this.isPaused ? 'none' : '') : 'none');
-		this.doc.$('lbPrevTop').style.display = (this.navTop && this.showNavigation && this.navTypeHash['Display_by_type_' + this.navType] ? '' : 'none');
-		this.doc.$('lbPrev').style.display = (!this.navTop && this.showNavigation && this.navTypeHash['Display_by_type_' + this.navType] ? '' : 'none');
-		this.doc.$('lbNextTop').style.display = (this.navTop && this.showNavigation && this.navTypeHash['Display_by_type_' + this.navType] ? '' : 'none');
-		this.doc.$('lbNext').style.display = (!this.navTop && this.showNavigation && this.navTypeHash['Display_by_type_' + this.navType] ? '' : 'none');
-	} else {
-		this.doc.$('lbHoverNav').style.display = (this.ieVersion != 6 && this.navTypeHash['Hover_by_type_' + this.navType] && !this.isLyteframe ? '' : 'none');
-		if ((this.navTypeHash['Display_by_type_' + this.navType] && !this.isLyteframe && this.imageArray.length > 1) || (this.frameArray.length > 1 && this.isLyteframe)) {
-			this.doc.$('lbPrevTop').style.display = (this.navTop ? '' : 'none');
-			this.doc.$('lbPrev').style.display = (!this.navTop ? '' : 'none');
-			this.doc.$('lbNextTop').style.display = (this.navTop ? '' : 'none');
-			this.doc.$('lbNext').style.display = (!this.navTop ? '' : 'none');
-		} else {
-			this.doc.$('lbPrevTop').style.display = 'none';
-			this.doc.$('lbPrev').style.display = 'none';
-			this.doc.$('lbNextTop').style.display = 'none';
-			this.doc.$('lbNext').style.display = 'none';
-		}
-		this.doc.$('lbCloseTop').style.display = (this.navTop ? '' : 'none');
-		this.doc.$('lbClose').style.display = (!this.navTop ? '' : 'none');				
-		this.doc.$('lbBottomData').style.display = '';
-		this.doc.$('lbPauseTop').style.display = 'none';
-		this.doc.$('lbPause').style.display = 'none';
-		this.doc.$('lbPlayTop').style.display = 'none';
-		this.doc.$('lbPlay').style.display = 'none';
-	}
-	this.doc.$('lbPrintTop').style.display = (this.showPrint && this.navTop ? '' : 'none');
-	this.doc.$('lbPrint').style.display = (this.showPrint && !this.navTop ? '' : 'none');
-	this.updateDetails();
-	this.doc.$('lbLoading').style.display = 'none';
-	this.doc.$('lbImageContainer').style.display = (this.isLyteframe ? 'none' : '');
-	this.doc.$('lbIframeContainer').style.display = (this.isLyteframe ? '' : 'none');
-	if (this.isLyteframe) {
-		if (!this.isEmpty(this.frameSource)) {
-			this.doc.$('lbIframe').src = this.frameSource;
-		}
-		this.doc.$('lbIframe').style.display = '';
-		this.fadeIn({ id: 'lbIframe', opacity: (this.doAnimations && (!this.ie || this.ieVersion >= 9) ? 0 : 100) });
-	} else {
-		this.doc.$('lbImage').style.display = '';
-		this.fadeIn({ id: 'lbImage', opacity: (this.doAnimations && (!this.ie || this.ieVersion >= 9) ? 0 : 100) });
-		this.preloadNeighborImages();
-	}
-	if (!this.isEmpty(this.afterStart)) {
-		var callback = window[this.afterStart];
-		if (typeof callback === 'function') {
-			callback(this.args);
-		}
-	}
-};
-Lytebox.prototype.updateDetails = function() {
-	var sTitle = (this.isSlideshow ? this.slideArray[this.contentNum][1] : (this.isLyteframe ? this.frameArray[this.contentNum][1] : this.imageArray[this.contentNum][1]));
-	var sDesc  = (this.isSlideshow ? this.slideArray[this.contentNum][2] : (this.isLyteframe ? this.frameArray[this.contentNum][2] : this.imageArray[this.contentNum][2]));
-	if (this.ie && this.ieVersion <= 7 || (this.ieVersion >= 8 && this.doc.compatMode == 'BackCompat')) {
-		this.doc.$(this.titleTop ? 'lbTitleBottom' : 'lbTitleTop').style.display = 'none';
-		this.doc.$(this.titleTop ? 'lbTitleTop' : 'lbTitleBottom').style.display = (this.isEmpty(sTitle) ? 'none' : 'block');
-	}
-	this.doc.$('lbDescBottom').style.display = (this.isEmpty(sDesc) ? 'none' : '');
-	this.doc.$(this.titleTop ? 'lbTitleTop' : 'lbTitleBottom').innerHTML = (this.isEmpty(sTitle) ? '' : sTitle);
-	this.doc.$(this.titleTop ? 'lbTitleBottom' : 'lbTitleTop').innerHTML = '';
-	this.doc.$(this.titleTop ? 'lbNumBottom' : 'lbNumTop').innerHTML = '';
-	this.updateNav();
-	if (this.titleTop || this.navTop) {
-		this.doc.$('lbTopContainer').style.display = 'block';
-		this.doc.$('lbTopContainer').style.visibility = 'visible';
-	} else {
-		this.doc.$('lbTopContainer').style.display = 'none';
-	}
-	var object = (this.titleTop ? this.doc.$('lbNumTop') : this.doc.$('lbNumBottom'));
-	if (this.isSlideshow && this.slideArray.length > 1) {
-		object.innerHTML = this.label['image'].replace('%1', this.contentNum + 1).replace('%2', this.slideArray.length);
-	} else if (this.imageArray.length > 1 && !this.isLyteframe) {
-		object.innerHTML = this.label['image'].replace('%1', this.contentNum + 1).replace('%2', this.imageArray.length);
-	} else if (this.frameArray.length > 1 && this.isLyteframe) {
-		object.innerHTML = this.label['page'].replace('%1', this.contentNum + 1).replace('%2', this.frameArray.length);
-	} else {
-		object.innerHTML = '';
-	}
-	var bAddSpacer = !(this.titleTop || (this.isEmpty(sTitle) && this.isEmpty(object.innerHTML)));
-	this.doc.$('lbDescBottom').innerHTML = (this.isEmpty(sDesc) ? '' : (bAddSpacer ? '<br style="line-height:0.6em;" />' : '') + sDesc);
-	var iNavWidth = 0;
-	if (this.ie && this.ieVersion <= 7 || (this.ieVersion >= 8 && this.doc.compatMode == 'BackCompat')) {
-		iNavWidth = 39 + (this.showPrint ? 39 : 0) + (this.isSlideshow && this.showPlayPause ? 39 : 0);
-		if ((this.isSlideshow && this.slideArray.length > 1 && this.showNavigation && this.navType != 1) ||
-			(this.frameArray.length > 1 && this.isLyteframe) ||
-			(this.imageArray.length > 1 && !this.isLyteframe && this.navType != 1)) {
-				iNavWidth += 39*2;
-		}
-	}
-	this.doc.$('lbBottomContainer').style.display = (!(this.titleTop && this.navTop) || !this.isEmpty(sDesc) ? 'block' : 'none');
-	if (this.titleTop && this.navTop) {
-		if (iNavWidth > 0) {
-			this.doc.$('lbTopNav').style.width = iNavWidth + 'px';
-		}
-		this.doc.$('lbTopData').style.width = (this.doc.$('lbTopContainer').offsetWidth - this.doc.$('lbTopNav').offsetWidth - 15) + 'px';
-		if (!this.isEmpty(sDesc)) {
-			this.doc.$('lbDescBottom').style.width = (this.doc.$('lbBottomContainer').offsetWidth - 15) + 'px';
-		}
-	} else if ((!this.titleTop || !this.isEmpty(sDesc)) && !this.navTop) {
-		if (iNavWidth > 0) {
-			this.doc.$('lbBottomNav').style.width = iNavWidth + 'px';
-		}
-		this.doc.$('lbBottomData').style.width = (this.doc.$('lbBottomContainer').offsetWidth - this.doc.$('lbBottomNav').offsetWidth - 15) + 'px';
-		this.doc.$('lbDescBottom').style.width = this.doc.$('lbBottomData').style.width;
-	}
-	this.fixBottomPadding();
-	this.aPageSize = this.getPageSize();
-	var iMainTop = parseInt(this.doc.$('lbMain').style.top);
-	if ((this.ie && this.ieVersion <= 7) || (this.ieVersion >= 8 && this.doc.compatMode == 'BackCompat')) {
-		iMainTop = (this.ie ? parseInt(this.doc.$('lbMain').style.top) - this.getPageScroll() : parseInt(this.doc.$('lbMain').style.top));
-	}
-	var iOverlap = (this.doc.$('lbOuterContainer').offsetHeight + iMainTop) - this.aPageSize[3];
-	var iDivisor = 40;
-	if (iOverlap > 0 && this.autoResize && this.fixedPosition) {
-		if (this.ie && (this.ieVersion <= 7 || this.doc.compatMode == 'BackCompat')) {
-			document.body.onscroll = this.bodyOnscroll;
-			if (window.removeEventListener) {
-				window.removeEventListener('scroll', this.scrollHandler);
-			} else if (window.detachEvent) {
-				window.detachEvent('onscroll', this.scrollHandler);
-			}
-		}
-		this.doc.$('lbMain').style.position = "absolute";
-		this.doc.$('lbMain').style.top = (this.getPageScroll() + (this.aPageSize[3] / iDivisor)) + "px";
-	}
-};
-Lytebox.prototype.updateNav = function() {
-	if (this.isSlideshow) {
-		if (this.contentNum != 0) {
-			if (this.navTypeHash['Display_by_type_' + this.navType] && this.showNavigation) {
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme);
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').style.display = '';
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() {
-					if ($lb.pauseOnPrevClick) { $lb.togglePlayPause($lb.navTop ? 'lbPauseTop' : 'lbPause', $lb.navTop ? 'lbPlayTop' : 'lbPlay'); }
-					$lb.changeContent($lb.contentNum - 1); return false;
-				}
-			}
-			if (this.navTypeHash['Hover_by_type_' + this.navType]) {
-				var object = this.doc.$('lbPrevHov');
-				object.style.display = '';
-				object.onclick = function() {
-					if ($lb.pauseOnPrevClick) { $lb.togglePlayPause($lb.navTop ? 'lbPauseTop' : 'lbPause', $lb.navTop ? 'lbPlayTop' : 'lbPlay'); }
-					$lb.changeContent($lb.contentNum - 1); return false;
-				}
-			}
-		} else {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) {
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme + 'Off');
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() { return false; }
-			}
-		}
-		if (this.contentNum != (this.slideArray.length - 1) && this.showNavigation) {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) {
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme);
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').style.display = '';
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() {
-					if ($lb.pauseOnNextClick) { $lb.togglePlayPause($lb.navTop ? 'lbPauseTop' : 'lbPause', $lb.navTop ? 'lbPlayTop' : 'lbPlay'); }
-					$lb.changeContent($lb.contentNum + 1); return false;
-				}
-			}
-			if (this.navTypeHash['Hover_by_type_' + this.navType]) {
-				var object = this.doc.$('lbNextHov');
-				object.style.display = '';
-				object.onclick = function() {
-					if ($lb.pauseOnNextClick) { $lb.togglePlayPause($lb.navTop ? 'lbPauseTop' : 'lbPause', $lb.navTop ? 'lbPlayTop' : 'lbPlay'); }
-					$lb.changeContent($lb.contentNum + 1); return false;
-				}
-			}
-		} else {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) { 
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme + 'Off');
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() { return false; }
-			}
-		}
-	} else if (this.isLyteframe) {
-		if(this.contentNum != 0) {
-			this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme);
-			this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').style.display = '';
-			this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() {
-				$lb.changeContent($lb.contentNum - 1); return false;
-			}
-		} else {
-			this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme + 'Off');
-			this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() { return false; }
-		}
-		if(this.contentNum != (this.frameArray.length - 1)) {
-			this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme);
-			this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').style.display = '';
-			this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() {
-				$lb.changeContent($lb.contentNum + 1); return false;
-			}
-		} else {
-			this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme + 'Off');
-			this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() { return false; }
-		}
-	} else {
-		if(this.contentNum != 0) {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) {
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme);
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').style.display = '';
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() {
-					$lb.changeContent($lb.contentNum - 1); return false;
-				}
-			}
-			if (this.navTypeHash['Hover_by_type_' + this.navType]) {
-				var object2 = this.doc.$('lbPrevHov');
-				object2.style.display = '';
-				object2.onclick = function() {
-					$lb.changeContent($lb.contentNum - 1); return false;
-				}
-			}
-		} else {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) {
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').setAttribute(this.classAttribute, this.theme + 'Off');
-				this.doc.$(this.navTop ? 'lbPrevTop' : 'lbPrev').onclick = function() { return false; }
-			}
-		}
-		if(this.contentNum != (this.imageArray.length - 1)) {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) {
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme);
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').style.display = '';
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() {
-					$lb.changeContent($lb.contentNum + 1); return false;
-				}
-			}
-			if (this.navTypeHash['Hover_by_type_' + this.navType]) {
-				var object2 = this.doc.$('lbNextHov');
-				object2.style.display = '';
-				object2.onclick = function() {
-					$lb.changeContent($lb.contentNum + 1); return false;
-				}
-			}
-		} else {
-			if (this.navTypeHash['Display_by_type_' + this.navType]) { 
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').setAttribute(this.classAttribute, this.theme + 'Off');
-				this.doc.$(this.navTop ? 'lbNextTop' : 'lbNext').onclick = function() { return false; }
-			}
-		}
-	}
-	this.enableKeyboardNav();
-};
-Lytebox.prototype.fixBottomPadding = function() {
-	if (!((this.ieVersion == 7 || this.ieVersion == 8 || this.ieVersion == 9) && this.doc.compatMode == 'BackCompat') && this.ieVersion != 6) {
-		var titleHeight = this.doc.$('lbTopContainer').offsetHeight + 5;
-		var offsetHeight = (titleHeight == 5 ? 0 : titleHeight) + this.doc.$('lbBottomContainer').offsetHeight;
-		this.doc.$('lbOuterContainer').style.paddingBottom = (offsetHeight + 5) + 'px';
-	}
-};
-Lytebox.prototype.enableKeyboardNav = function() { document.onkeydown = this.keyboardAction; };
-Lytebox.prototype.disableKeyboardNav = function() { document.onkeydown = ''; };
-Lytebox.prototype.keyboardAction = function(e) {
-	var keycode = key = escape = null;
-	keycode	= (e == null) ? event.keyCode : e.which;
-	key		= String.fromCharCode(keycode).toLowerCase();
-	escape  = (e == null) ? 27 : e.DOM_VK_ESCAPE;
-	if ((key == 'x') || (key == 'c') || (keycode == escape || keycode == 27)) {
-		parent.$lb.end();
-	} else if (keycode == 32 && $lb.isSlideshow && $lb.showPlayPause) {
-		if ($lb.isPaused) {
-			$lb.togglePlayPause($lb.navTop ? 'lbPlayTop' : 'lbPlay', $lb.navTop ? 'lbPauseTop' : 'lbPause');
-		} else {
-			$lb.togglePlayPause($lb.navTop ? 'lbPauseTop' : 'lbPause', $lb.navTop ? 'lbPlayTop' : 'lbPlay');
-		}
-		return false;
-	} else if (key == 'p' || keycode == 37) {
-		if ($lb.isSlideshow) {
-			if($lb.contentNum != 0) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum - 1);
-			}
-		} else if ($lb.isLyteframe) {
-			if($lb.contentNum != 0) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum - 1);
-			}
-		} else {
-			if($lb.contentNum != 0) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum - 1);
-			}
-		}
-	} else if (key == 'n' || keycode == 39) {
-		if ($lb.isSlideshow) {
-			if($lb.contentNum != ($lb.slideArray.length - 1)) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum + 1);
-			}
-		} else if ($lb.isLyteframe) {
-			if($lb.contentNum != ($lb.frameArray.length - 1)) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum + 1);
-			}
-		} else {
-			if($lb.contentNum != ($lb.imageArray.length - 1)) {
-				$lb.disableKeyboardNav();
-				$lb.changeContent($lb.contentNum + 1);
-			}
-		}
-	}
-};
-Lytebox.prototype.preloadNeighborImages = function() {
-	if (this.isSlideshow) {
-		if ((this.slideArray.length - 1) > this.contentNum) {
-			var preloadNextImage = new Image();
-				preloadNextImage.src = this.slideArray[this.contentNum + 1][0];
-		}
-		if (this.contentNum > 0) {
-			var preloadPrevImage = new Image();
-				preloadPrevImage.src = this.slideArray[this.contentNum - 1][0];
-		}
-	} else {
-		if ((this.imageArray.length - 1) > this.contentNum) {
-			var preloadNextImage = new Image();
-				preloadNextImage.src = this.imageArray[this.contentNum + 1][0];
-		}
-		if (this.contentNum > 0) {
-			var preloadPrevImage = new Image();
-				preloadPrevImage.src = this.imageArray[this.contentNum - 1][0];
-		}
-	}
-};
-Lytebox.prototype.togglePlayPause = function(sHideId, sShowId) {
-	if (this.isSlideshow && (sHideId == 'lbPauseTop' || sHideId == 'lbPause')) {
-		for (var i = 0; i < this.slideshowIDCount; i++) { window.clearTimeout(this.slideshowIDArray[i]); }
-	}
-	this.doc.$(sHideId).style.display = 'none';
-	this.doc.$(sShowId).style.display = '';
-	if (sHideId == 'lbPlayTop' || sHideId == 'lbPlay') {
-		this.isPaused = false;
-		if (this.contentNum == (this.slideArray.length - 1)) {
-			if (this.loopSlideshow) {
-				this.changeContent(0);
-			} else if (this.autoEnd) {
-				this.end();
-			}
-		} else {
-			this.changeContent(this.contentNum + 1);
-		}
-	} else {
-		this.isPaused = true;
-	}
-};
-Lytebox.prototype.end = function(sCaller) {
-	var closeClick = (sCaller == 'slideshow' ? false : true);
-	if (this.isSlideshow && this.isPaused && !closeClick) { return; }
-	if (!this.isEmpty(this.beforeEnd)) {
-		var callback = window[this.beforeEnd];
-		if (typeof callback === 'function') {
-			if (!callback(this.args)) { return; }
-		}
-	}
-	this.disableKeyboardNav();
-	document.body.onscroll = this.bodyOnscroll;
-	if (this.refreshPage) {
-		var uri_href = top.location.href;
-		var reg=/\#.*$/g;
-		uri_href=uri_href.replace(reg, "");
-		top.location.href = uri_href;
-		return;
-	}
-	this.doc.$('lbMain').style.display = 'none';
-	this.fadeOut({ id: 'lbOverlay', opacity: (this.doAnimations && this.animateOverlay && (!this.ie || this.ieVersion >= 9) ? this.maxOpacity : 0), speed: 5, display: 'none' });
-	this.toggleSelects('visible');
-	if (this.hideObjects) { this.toggleObjects('visible'); }
-	this.doc.$('lbOuterContainer').style.width = '200px';
-	this.doc.$('lbOuterContainer').style.height = '200px';
-	if (this.inline && this.safari) {
-		var iframe = this.doc.$('lbIframe');
-		var oDoc = iframe.contentWindow || iframe.contentDocument;
-		if (oDoc.document) {
-			oDoc = oDoc.document;
-		}
-		oDoc.open();
-		oDoc.write('<html><head></head><body></body></html>');
-		oDoc.close();
-	}
-	if (this.isSlideshow) {
-		for (var i = 0; i < this.slideshowIDCount; i++) { window.clearTimeout(this.slideshowIDArray[i]); }
-		this.isPaused = false;
-	}
-	if (!this.isEmpty(this.afterEnd)) {
-		var callback = window[this.afterEnd];
-		if (typeof callback === 'function') {
-			callback(this.args);
-		}
-	}
-};
-Lytebox.prototype.checkFrame = function() {
-	if (window.parent.frames[window.name] && (parent.document.getElementsByTagName('frameset').length <= 0) && window.name != 'lbIframe') {
-		this.isFrame = true;
-		this.doc = parent.document;
-	} else {
-		this.isFrame = false;
-		this.doc = document;
-	}
-	this.doc.$ = this.doc.getElementById;
-};
-Lytebox.prototype.getPixelRate = function(iCurrent, iDim) {
-	var diff = (iDim > iCurrent) ? iDim - iCurrent : iCurrent - iDim;
-	if (diff >= 0 && diff <= 100) { return (100 / this.resizeDuration); }
-	if (diff > 100 && diff <= 200) { return (150 / this.resizeDuration); }
-	if (diff > 200 && diff <= 300) { return (200 / this.resizeDuration); }
-	if (diff > 300 && diff <= 400) { return (250 / this.resizeDuration); }
-	if (diff > 400 && diff <= 500) { return (300 / this.resizeDuration); }
-	if (diff > 500 && diff <= 600) { return (350 / this.resizeDuration); }
-	if (diff > 600 && diff <= 700) { return (400 / this.resizeDuration); }
-	if (diff > 700) { return (450 / this.resizeDuration); }
-};
-Lytebox.prototype.fadeIn = function(args) {
-	var sId = this.isEmpty(args.id) ? '' : args.id;
-	var iSpeed = (this.isEmpty(args.speed) ? 5 : (parseInt(args.speed) > 5 ? 5 : parseInt(args.speed)));
-		iSpeed = isNaN(iSpeed) ? 5 : iSpeed;
-	var iOpacity = this.isEmpty(args.opacity) ? 0 : parseInt(args.opacity);
-		iOpacity = isNaN(iOpacity) ? 0 : iOpacity;
-	var sDisplay = this.isEmpty(args.display) ? '' : args.display;
-	var sVisibility = this.isEmpty(args.visibility) ? '' : args.visibility;
-	var oElement = this.doc.$(sId);
-	var iIncrement = iSpeed;
-	if (/lbImage|lbIframe|lbOverlay|lbBottomContainer|lbTopContainer/.test(sId)) {
-		iIncrement = this.ff ? (this.ffVersion >= 6 ? 2 : 5) : (this.safari ? 3 : (this.ieVersion <= 8 ? 10 : 5));
-		iIncrement = this.isMobile() ? 20 : iIncrement;
-		iIncrement = (sId == 'lbOverlay' ? iIncrement * 2 : iIncrement);
-		iIncrement = (sId == 'lbIframe' ? 100 : iIncrement);
-	} else if (this.ieVersion == 7 || this.ieVersion == 8) {
-		iIncrement = 10;
-	}
-	oElement.style.opacity = (iOpacity / 100);
-	oElement.style.filter = "alpha(opacity=" + (iOpacity) + ")";
-	if (iOpacity >= 100 && (sId == 'lbImage' || sId == 'lbIframe')) {
-		try { oElement.style.removeAttribute("filter"); } catch(e) {}
-		this.fixBottomPadding();
-	} else if (iOpacity >= this.maxOpacity && sId == 'lbOverlay') {
-		for (var i = 0; i < this.overlayTimerCount; i++) { window.clearTimeout(this.overlayTimerArray[i]); }
-		this.overlayLoaded = true;
-		return;
-	} else if (iOpacity >= 100 && (sId == 'lbBottomContainer' || sId == 'lbTopContainer')) {
-		try { oElement.style.removeAttribute("filter"); } catch(e) {}
-		for (var i = 0; i < this.imageTimerCount; i++) { window.clearTimeout(this.imageTimerArray[i]); }
-		this.doc.$('lbOverlay').style.height = this.aPageSize[1] + "px";
-	} else if (iOpacity >= 100) {
-		for (var i = 0; i < this.imageTimerCount; i++) { window.clearTimeout(this.imageTimerArray[i]); }
-	} else {
-		if (sId == 'lbOverlay') {
-			this.overlayTimerArray[this.overlayTimerCount++] = setTimeout("$lb.fadeIn({ id: '" + sId + "', opacity: " + (iOpacity + iIncrement) + ", speed: " + iSpeed + " })", 1);
-		} else {
-			this.imageTimerArray[this.imageTimerCount++] = setTimeout("$lb.fadeIn({ id: '" + sId + "', opacity: " + (iOpacity + iIncrement) + ", speed: " + iSpeed + " })", 1);
-		}
-	}
-};
-Lytebox.prototype.fadeOut = function(args) {
-	var sId = this.isEmpty(args.id) ? '' : args.id;
-	var iSpeed = (this.isEmpty(args.speed) ? 5 : (parseInt(args.speed) > 5 ? 5 : parseInt(args.speed)));
-		iSpeed = isNaN(iSpeed) ? 5 : iSpeed;
-	var iOpacity = this.isEmpty(args.opacity) ? 100 : parseInt(args.opacity);
-		iOpacity = isNaN(iOpacity) ? 100 : iOpacity;
-	var sDisplay = this.isEmpty(args.display) ? '' : args.display;
-	var sVisibility = this.isEmpty(args.visibility) ? '' : args.visibility;
-	var oElement = this.doc.$(sId);
-	if (this.ieVersion == 7 || this.ieVersion == 8) {
-		iSpeed *= 2;
-	}
-	oElement.style.opacity = (iOpacity / 100);
-	oElement.style.filter = "alpha(opacity=" + iOpacity + ")";
-	if (iOpacity <= 0) {
-		try {
-			if (!this.isEmpty(sDisplay)) {
-				oElement.style.display = sDisplay;
-			}
-			if (!this.isEmpty(sVisibility)) {
-				oElement.style.visibility = sVisibility;
-			}
-		} catch(err) { }
-		if (sId == 'lbOverlay') {
-			this.overlayLoaded = false;
-			if (this.isLyteframe) {
-				this.doc.$('lbIframe').src = 'about:blank';
-				this.initialize();
-			}
-		} else {
-			for (var i = 0; i < this.timerIDCount; i++) { window.clearTimeout(this.timerIDArray[i]); }
-		}
-	} else if (sId == 'lbOverlay') {
-		this.overlayTimerArray[this.overlayTimerCount++] = setTimeout("$lb.fadeOut({ id: '" + sId + "', opacity: " + (iOpacity - (iSpeed * 2)) + ", speed: " + iSpeed + ", display: '" + sDisplay + "', visibility: '" + sVisibility + "' })", 1);
-	} else {
-		this.timerIDArray[this.timerIDCount++] = setTimeout("$lb.fadeOut({ id: '" + sId + "', opacity: " + (iOpacity - iSpeed) + ", speed: " + iSpeed + ", display: '" + sDisplay + "', visibility: '" + sVisibility + "' })", 1);
-	}
-};
-Lytebox.prototype.resizeW = function(sId, iCurrentW, iMaxW, iPixelRate, iSpeed) {
-	var object = this.doc.$(sId);
-	var newW = (this.doAnimations ? iCurrentW : iMaxW);
-	object.style.width = (newW) + "px";
-	if (newW < iMaxW) {
-		newW += (newW + iPixelRate >= iMaxW) ? (iMaxW - newW) : iPixelRate;
-	} else if (newW > iMaxW) {
-		newW -= (newW - iPixelRate <= iMaxW) ? (newW - iMaxW) : iPixelRate;
-	}
-	this.resizeWTimerArray[this.resizeWTimerCount++] = setTimeout("$lb.resizeW('" + sId + "', " + newW + ", " + iMaxW + ", " + iPixelRate + ", " + (iSpeed) + ")", iSpeed);
-	if (parseInt(object.style.width) == iMaxW) {
-		this.wDone = true;
-		for (var i = 0; i < this.resizeWTimerCount; i++) { window.clearTimeout(this.resizeWTimerArray[i]); }
-		if (this.isLyteframe) {
-			this.loadContent();
-		} else {
-			this.showContent();
-		}
-	}
-};
-Lytebox.prototype.resizeH = function(sId, iCurrentH, iMaxH, iPixelRate, iSpeed) {
-	var object = this.doc.$(sId);
-	var newH = (this.doAnimations ? iCurrentH : iMaxH);
-	object.style.height = (newH) + "px";
-	if (newH < iMaxH) {
-		newH += (newH + iPixelRate >= iMaxH) ? (iMaxH - newH) : iPixelRate;
-	} else if (newH > iMaxH) {
-		newH -= (newH - iPixelRate <= iMaxH) ? (newH - iMaxH) : iPixelRate;
-	}
-	this.resizeHTimerArray[this.resizeHTimerCount++] = setTimeout("$lb.resizeH('" + sId + "', " + newH + ", " + iMaxH + ", " + iPixelRate + ", " + (iSpeed+.02) + ")", iSpeed+.02);
-	if (parseInt(object.style.height) == iMaxH) {
-		this.hDone = true;
-		for (var i = 0; i < this.resizeHTimerCount; i++) { window.clearTimeout(this.resizeHTimerArray[i]); }
-		this.resizeW('lbOuterContainer', this.wCur, this.resizeWidth + this.borderSize * 2, this.getPixelRate(this.wCur, this.resizeWidth));
-	}
-};
-Lytebox.prototype.getPageScroll = function() {
-	if (self.pageYOffset) {
-		return this.isFrame ? parent.pageYOffset : self.pageYOffset;
-	} else if (this.doc.documentElement && this.doc.documentElement.scrollTop){
-		return this.doc.documentElement.scrollTop;
-	} else if (document.body) {
-		return this.doc.body.scrollTop;
-	}
-};
-Lytebox.prototype.getPageSize = function() {
-	var xScroll, yScroll, windowWidth, windowHeight;
-	if (window.innerHeight && window.scrollMaxY) {
-		xScroll = this.doc.scrollWidth;
-		yScroll = (this.isFrame ? parent.innerHeight : self.innerHeight) + (this.isFrame ? parent.scrollMaxY : self.scrollMaxY);
-	} else if (this.doc.body.scrollHeight > this.doc.body.offsetHeight){
-		xScroll = this.doc.body.scrollWidth;
-		yScroll = this.doc.body.scrollHeight;
-	} else {
-		xScroll = this.doc.getElementsByTagName("html").item(0).offsetWidth;
-		yScroll = this.doc.getElementsByTagName("html").item(0).offsetHeight;
-		xScroll = (xScroll < this.doc.body.offsetWidth) ? this.doc.body.offsetWidth : xScroll;
-		yScroll = (yScroll < this.doc.body.offsetHeight) ? this.doc.body.offsetHeight : yScroll;
-	}
-	if (self.innerHeight) {
-		windowWidth = (this.isFrame) ? parent.innerWidth : self.innerWidth;
-		windowHeight = (this.isFrame) ? parent.innerHeight : self.innerHeight;
-	} else if (document.documentElement && document.documentElement.clientHeight) {
-		windowWidth = this.doc.documentElement.clientWidth;
-		windowHeight = this.doc.documentElement.clientHeight;
-		windowWidth = (windowWidth == 0) ? this.doc.body.clientWidth : windowWidth;
-		windowHeight = (windowHeight == 0) ? this.doc.body.clientHeight : windowHeight;
-	} else if (document.body) {
-		windowWidth = this.doc.getElementsByTagName("html").item(0).clientWidth;
-		windowHeight = this.doc.getElementsByTagName("html").item(0).clientHeight;
-		windowWidth = (windowWidth == 0) ? this.doc.body.clientWidth : windowWidth;
-		windowHeight = (windowHeight == 0) ? this.doc.body.clientHeight : windowHeight;
-	}
-	var pageHeight = (yScroll < windowHeight) ? windowHeight : yScroll;
-	var pageWidth = (xScroll < windowWidth) ? windowWidth : xScroll;
-	return new Array(pageWidth, pageHeight, windowWidth, windowHeight);
-};
-Lytebox.prototype.toggleObjects = function(sState) {
-	var objects = this.doc.getElementsByTagName("object");
-	for (var i = 0; i < objects.length; i++) {
-		objects[i].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-	}
-	var embeds = this.doc.getElementsByTagName("embed");
-	for (var i = 0; i < embeds.length; i++) {
-		embeds[i].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-	}
-	if (this.isFrame) {
-		for (var i = 0; i < parent.frames.length; i++) {
-			try {
-				objects = parent.frames[i].window.document.getElementsByTagName("object");
-				for (var j = 0; j < objects.length; j++) {
-					objects[j].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-				}
-			} catch(e) {}
-			
-			try {
-				embeds = parent.frames[i].window.document.getElementsByTagName("embed");
-				for (var j = 0; j < embeds.length; j++) {
-					embeds[j].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-				}
-			} catch(e) {}
-		}
-	}
-};
-Lytebox.prototype.toggleSelects = function(sState) {
-	var selects = this.doc.getElementsByTagName("select");
-	for (var i = 0; i < selects.length; i++ ) {
-		selects[i].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-	}
-	if (this.isFrame) {
-		for (var i = 0; i < parent.frames.length; i++) {
-			try {
-				selects = parent.frames[i].window.document.getElementsByTagName("select");
-				for (var j = 0; j < selects.length; j++) {
-					selects[j].style.visibility = (sState == "hide") ? 'hidden' : 'visible';
-				}
-			} catch(e) {}
-		}
-	}
-};
-Lytebox.prototype.pause = function(iMillis) {
-	var now = new Date();
-	var exitTime = now.getTime() + iMillis;
-	while (true) {
-		now = new Date();
-		if (now.getTime() > exitTime) { return; }
-	}
-};
-Lytebox.prototype.combine = function(aAnchors, aAreas) {
-	var lyteLinks = [];
-	for (var i = 0; i < aAnchors.length; i++) {
-		lyteLinks.push(aAnchors[i]);
-	}
-	for (var i = 0; i < aAreas.length; i++) {
-		lyteLinks.push(aAreas[i]);
-	}
-	return lyteLinks;
-};
-Lytebox.prototype.removeDuplicates = function (aArray) {
-	var aNew = new Array();
-	o:for(var i = 0, n = aArray.length; i < n; i++) {
-		for(var x = 0, y = aNew.length; x < y; x++) {
-			if (aNew[x][0].toLowerCase() == aArray[i][0].toLowerCase()) { continue o; }
-		}
-		aNew[aNew.length] = aArray[i];
-	}
-	return aNew;
-};
-Lytebox.prototype.printWindow = function () {
-	var w = this.isLyteframe ? 800 : this.imgPreloader.width + 20;
-	var h = this.isLyteframe ? 600 : this.imgPreloader.height + 20;
-	var left = parseInt((screen.availWidth/2) - (w/2));
-	var top = parseInt((screen.availHeight/2) - (h/2));
-	var wOpts = "width=" + w + ",height=" + h + ",left=" + left + ",top=" + top + "screenX=" + left + ",screenY=" + top + "directories=0,location=0,menubar=0,resizable=0,scrollbars=0,status=0,titlebar=0,toolbar=0";
-	var d = new Date();
-	var wName = 'Print' + d.getTime();
-	var wUrl = document.getElementById(this.printId).src;
-	this.wContent = window.open(wUrl, wName, wOpts);
-	this.wContent.focus();
-	var t = setTimeout("$lb.printContent()",1000);
-};
-Lytebox.prototype.printContent = function() {
-	try {
-		if (this.wContent.document.readyState == 'complete') {
-			this.wContent.print();
-			this.wContent.close();
-			this.wContent = null;
-		} else {
-			var t = setTimeout("$lb.printContent()",1000);
-		}
-	} catch(e) { }
-};
-Lytebox.prototype.setOptions = function(sOptions) {
-	this.args = '';
-	this.group = '';
-	this.inline = false;
-	this.hideObjects = this.__hideObjects;
-	this.autoResize = this.__autoResize;
-	this.doAnimations = this.__doAnimations;
-	this.animateOverlay = this.__animateOverlay;
-	this.forceCloseClick = this.__forceCloseClick;
-	this.refreshPage = this.__refreshPage;
-	this.showPrint = this.__showPrint;
-	this.navType = this.__navType;
-	this.titleTop = this.__titleTop;
-	this.navTop = this.__navTop;
-	this.beforeStart = this.__beforeStart;
-	this.afterStart = this.__afterStart
-	this.beforeEnd = this.__beforeEnd;
-	this.afterEnd = this.__afterEnd;
-	this.scrolling = this.__scrolling;
-	this.width = this.__width;
-	this.height = this.__height;
-	this.loopPlayback = this.__loopPlayback;
-	this.autoPlay = this.__autoPlay;
-	this.autoEmbed = this.__autoEmbed;
-	this.slideInterval = this.__slideInterval;
-	this.showNavigation = this.__showNavigation;
-	this.showClose = this.__showClose;
-	this.showDetails = this.__showDetails;
-	this.showPlayPause = this.__showPlayPause;
-	this.autoEnd = this.__autoEnd;
-	this.pauseOnNextClick = this.__pauseOnNextClick;
-	this.pauseOnPrevClick = this.__pauseOnPrevClick;
-	this.loopSlideshow = this.__loopSlideshow;
-	
-	var sName = sValue = '';
-	var aSetting = null;
-	var aOptions = sOptions.split(' ');
-	for (var i = 0; i < aOptions.length; i++) {
-		aSetting = aOptions[i].split(':');
-		sName = (aSetting.length > 1 ? this.trim(aSetting[0]).toLowerCase() : '');
-		sValue = (aSetting.length > 1 ? this.trim(aSetting[1]): '');
-		switch(sName) {
-			case 'group':			this.group = (sName == 'group' ? (!this.isEmpty(sValue) ? sValue.toLowerCase() : '') : ''); break;
-			case 'hideobjects':		this.hideObjects = (/true|false/.test(sValue) ? (sValue == 'true') : this.__hideObjects); break;
-			case 'autoresize':		this.autoResize = (/true|false/.test(sValue) ? (sValue == 'true') : this.__autoResize); break;
-			case 'doanimations':	this.doAnimations = (/true|false/.test(sValue) ? (sValue == 'true') : this.__doAnimations); break;
-			case 'animateoverlay':	this.animateOverlay = (/true|false/.test(sValue) ? (sValue == 'true') : this.__animateOverlay); break;
-			case 'forcecloseclick':	this.forceCloseClick = (/true|false/.test(sValue) ? (sValue == 'true') : this.__forceCloseClick); break;
-			case 'refreshpage':		this.refreshPage = (/true|false/.test(sValue) ? (sValue == 'true') : this.__refreshPage); break;
-			case 'showprint':		this.showPrint = (/true|false/.test(sValue) ? (sValue == 'true') : this.__showPrint); break;
-			case 'navtype':			this.navType = (/[1-3]{1}/.test(sValue) ? parseInt(sValue) : this.__navType); break;
-			case 'titletop':		this.titleTop = (/true|false/.test(sValue) ? (sValue == 'true') : this.__titleTop); break;
-			case 'navtop':			this.navTop = (/true|false/.test(sValue) ? (sValue == 'true') : this.__navTop); break;
-			case 'beforestart':		this.beforeStart = (!this.isEmpty(sValue) ? sValue : this.__beforeStart); break;
-			case 'afterstart':		this.afterStart = (!this.isEmpty(sValue) ? sValue : this.__afterStart); break;
-			case 'beforeend':		this.beforeEnd = (!this.isEmpty(sValue) ? sValue : this.__beforeEnd); break;
-			case 'afterend':		this.afterEnd = (!this.isEmpty(sValue) ? sValue : this.__afterEnd); break;
-			case 'args': 			this.args = (!this.isEmpty(sValue) ? sValue : ''); break;
-			case 'scrollbars':		this.scrolling = (/auto|yes|no/.test(sValue) ? sValue : this.__scrolling); break;
-			case 'scrolling':		this.scrolling = (/auto|yes|no/.test(sValue) ? sValue : this.__scrolling); break;
-			case 'width':			this.width = (/\d(%|px|)/.test(sValue) ? sValue : this.__width); break;
-			case 'height':			this.height = (/\d(%|px|)/.test(sValue) ? sValue : this.__height); break;
-			case 'loopplayback':	this.loopPlayback = (/true|false/.test(sValue) ? (sValue == 'true') : this.__loopPlayback); break;
-			case 'autoplay':		this.autoPlay = (/true|false/.test(sValue) ? (sValue == 'true') : this.__autoPlay); break;
-			case 'autoembed':		this.autoEmbed = (/true|false/.test(sValue) ? (sValue == 'true') : this.__autoEmbed); break;
-			case 'inline':			this.inline = (/true|false/.test(sValue) ? (sValue == 'true') : false);
-			case 'slideinterval':	this.slideInterval = (/\d/.test(sValue) ? parseInt(sValue) : this.__slideInterval); break;
-			case 'shownavigation':	this.showNavigation = (/true|false/.test(sValue) ? (sValue == 'true') : this.__showNavigation); break;
-			case 'showclose':		this.showClose = (/true|false/.test(sValue) ? (sValue == 'true') : this.__showClose); break;
-			case 'showdetails':		this.showDetails = (/true|false/.test(sValue) ? (sValue == 'true') : this.__showDetails); break;
-			case 'showplaypause':	this.showPlayPause = (/true|false/.test(sValue) ? (sValue == 'true') : this.__showPlayPause); break;
-			case 'autoend':			this.autoEnd = (/true|false/.test(sValue) ? (sValue == 'true') : this.__autoEnd); break;
-			case 'pauseonnextclick': this.pauseOnNextClick = (/true|false/.test(sValue) ? (sValue == 'true') : this.__pauseOnNextClick); break;
-			case 'pauseonprevclick': this.pauseOnPrevClick = (/true|false/.test(sValue) ? (sValue == 'true') : this.__pauseOnPrevClick); break;
-			case 'loopslideshow':	this.loopSlideshow = (/true|false/.test(sValue) ? (sValue == 'true') : this.__loopSlideshow); break;
-		}
-	}
-};
-	Lytebox.prototype.buildObject = function(w, h, url) {
-	var object = '';
-	var classId = '';
-	var codebase = '';
-	var pluginsPage = '';
-	var auto = this.autoPlay ? 'true' : 'false';
-	var loop = this.loopPlayback ? 'true' : 'false';
-	var type = url.match(/.mov|.avi|.wmv|.mpg|.mpeg|.swf/i);
-	switch(type[0]) {
-	case '.mov':
-			codebase = 'http://www.apple.com/qtactivex/qtplugin.cab';
-			pluginsPage = 'http://www.apple.com/quicktime/';
-			classId = 'clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B';
-			object 	= '<object classid="' + classId + '" width="' + w + '" height="' + h + '" codebase="' + codebase + '">'
-					+ '<param name="src" value="' + url + '">'
-					+ '<param name="autoplay" value="' + auto + '">'
-					+ '<param name="loop" value="' + loop + '">'
-					+ '<param name="controller" value="true">'
-					+ '<embed src="' + url + '" width="' + w + '" height="' + h + '" autoplay="' + auto + '" loop="' + loop + '" controller="true" pluginspage="' + pluginsPage + '"></embed>'
-					+ '</object>';
-			if (this.getQuicktimeVersion() <= 0) {
-				object	= '<div style="padding:1em;">'
-						+ '<h2>QUICKTIME PLAYER</h2>'
-						+ '<p>Content on this page requires a newer version of QuickTime. Please click the image link below to download and install the latest version.</p>'
-						+ '<p><a href="http://www.apple.com/quicktime/" target="_blank"><img src="http://images.apple.com/about/webbadges/images/qt7badge_getQTfreeDownload.gif" alt="Get QuickTime" border="0" /></a></p>'
-						+ '</div>';
-			}
-			break;
-		case '.avi':
-		case '.mpg':
-		case '.mpeg':
-		case '.wmv':
-			classId = 'clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B';			
-			object 	= '<object classid="' + classId + '" width="' + w + '" height="' + h + '" codebase="' + codebase + '">'
-					+ '<param name="src" value="' + url + '">'
-					+ '<param name="autoplay" value="' + auto + '">'
-					+ '<param name="loop" value="' + loop + '">'
-					+ '<param name="controller" value="true">'
-					+ '<object type="video/quicktime" data="' + url + '" width="' + w + '" height="' + h + '">'
-					+ '<param name="controller" value="false">'
-					+ '<param name="autoplay" value="' + auto + '">'
-					+ '<param name="loop" value="' + loop + '">'
-					+ '</object>' 
-					+ '</object>';
-			break;
-		case '.swf':
-			classId = 'clsid:D27CDB6E-AE6D-11cf-96B8-444553540000';
-			object 	= '<object classid="' + classId + '" width="' + w + '" height="' + h + '" codebase="' + codebase + '">'
-					+ '<param name="movie" value="' + url + '">'
-					+ '<param name="quality" value="high">'
-					+ '<param name="wmode" value="opaque">'
-					+ '<!--[if !IE]>-->'
-					+ '<object type="application/x-shockwave-flash" data="' + url + '" width="' + w + '" height="' + h + '">'
-					+ '<!--<![endif]-->'
-					+ '<param name="quality" value="high">'
-					+ '<param name="wmode" value="opaque">'
-					+ '<div style="padding:1em;">'
-					+ '<h2>FLASH PLAYER</h2>'
-					+ '<p>Content on this page requires a newer version of Adobe Flash Player. Please click the image link below to download and install the latest version.</p>'
-					+ '<p><a href="http://www.adobe.com/go/getflashplayer" target="_blank"><img src="http://www.adobe.com/macromedia/style_guide/images/160x41_Get_Flash_Player.jpg" alt="Get Adobe Flash player" border="0" /></a></p>'
-					+ '</div>'
-					+ '<!--[if !IE]>-->'
-					+ '</object>'
-					+ '<!--<![endif]-->'
-					+ '</object>';
-			break;
-	}
-	return object;
-};
-Lytebox.prototype.getQuicktimeVersion = function() {
-	var agent = navigator.userAgent.toLowerCase(); 
-	var version = -1;
-	if (navigator.plugins != null && navigator.plugins.length > 0) {
-		for (i=0; i < navigator.plugins.length; i++ ) {
-			var plugin = navigator.plugins[i];
-			if (plugin.name.indexOf('QuickTime') > -1) {
-				version = parseFloat(plugin.name.substring(18));
-			}
-		}
-	} else if (this.autoEmbed && agent.indexOf('msie') != -1 && parseInt(navigator.appVersion) >= 4 && agent.indexOf('win') != -1 && agent.indexOf('16bit') == -1) {
-		var control = null;
-		try {
-			control = new ActiveXObject('QuickTime.QuickTime');
-		} catch (e) { }
-		if (control) {
-			isInstalled = true;
-		}			
-		try {
-			control = new ActiveXObject('QuickTimeCheckObject.QuickTimeCheck');
-		} catch (e) { return; }
-		if (control) {
-			isInstalled = true;
-			version = control.QuickTimeVersion.toString(16);
-			version = version.substring(0, 1) + '.' + version.substring(1, 3);
-			version = parseInt(version);
-		}
-	}
-	return version;
-};
-Lytebox.prototype.findPos = function(el) {
-	if (this.ie && this.doc.compatMode == 'BackCompat') {
-		return [0, 16, 12];
-	}
-	var left = 0;
-	var top = 0;
-	var height = 0;
-	height = el.offsetHeight + 6;
-	if (el.offsetParent) {
-		do {
-			left += el.offsetLeft;
-			top += el.offsetTop;
-		} while (el = el.offsetParent);
-	}
-	return [left, top, height];
-};
-Lytebox.prototype.isMobile = function() {
-	var ua = navigator.userAgent;
-	return (ua.match(/ipad/i) != null)
-		|| (ua.match(/ipod/i) != null)
-		|| (ua.match(/iphone/i) != null)
-		|| (ua.match(/android/i) != null)
-		|| (ua.match(/opera mini/i) != null)
-		|| (ua.match(/blackberry/i) != null)
-		|| (ua.match(/(pre\/|palm os|palm|hiptop|avantgo|plucker|xiino|blazer|elaine)/i) != null)
-		|| (ua.match(/(iris|3g_t|windows ce|opera mobi|windows ce; smartphone;|windows ce; iemobile)/i) != null)
-		|| (ua.match(/(mini 9.5|vx1000|lge |m800|e860|u940|ux840|compal|wireless| mobi|ahong|lg380|lgku|lgu900|lg210|lg47|lg920|lg840|lg370|sam-r|mg50|s55|g83|t66|vx400|mk99|d615|d763|el370|sl900|mp500|samu3|samu4|vx10|xda_|samu5|samu6|samu7|samu9|a615|b832|m881|s920|n210|s700|c-810|_h797|mob-x|sk16d|848b|mowser|s580|r800|471x|v120|rim8|c500foma:|160x|x160|480x|x640|t503|w839|i250|sprint|w398samr810|m5252|c7100|mt126|x225|s5330|s820|htil-g1|fly v71|s302|-x113|novarra|k610i|-three|8325rc|8352rc|sanyo|vx54|c888|nx250|n120|mtk |c5588|s710|t880|c5005|i;458x|p404i|s210|c5100|teleca|s940|c500|s590|foma|samsu|vx8|vx9|a1000|_mms|myx|a700|gu1100|bc831|e300|ems100|me701|me702m-three|sd588|s800|8325rc|ac831|mw200|brew |d88|htc\/|htc_touch|355x|m50|km100|d736|p-9521|telco|sl74|ktouch|m4u\/|me702|8325rc|kddi|phone|lg |sonyericsson|samsung|240x|x320|vx10|nokia|sony cmd|motorola|up.browser|up.link|mmp|symbian|smartphone|midp|wap|vodafone|o2|pocket|kindle|mobile|psp|treo)/i) != null);
-};
-Lytebox.prototype.validate = function(args) {
-	var reTest = sName = '';
-	var bValid = false;
-	var oElement = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	var sInput = this.isEmpty(args.value) ? '' : String(args.value);
-	var sType = this.isEmpty(args.type) ? '' : String(args.type).toLowerCase();
-	var sRegex = this.isEmpty(args.regex) ? '' : args.regex;
-	var sCCType = (/visa|mc|amex|diners|discover|jcb/.test(args.ccType) ? args.ccType : '');
-	var sImageType = this.isEmpty(args.imageType) ? '' : String(args.imageType.toLowerCase());
-	var iMin = (/^\d+$/.test(args.min) ? parseInt(args.min) : 0);
-	var iMax = (/^\d+$/.test(args.max) ? parseInt(args.max) : 0);
-	var bInclusive = args.inclusive ? true : (/true|false/.test(args.inclusive) ? (args.inclusive == 'true') : true);
-	var bAllowComma = args.allowComma ? true : (/true|false/.test(args.allowComma) ? (args.allowComma == 'true') : true);
-	var bAllowWhitespace = args.allowWhiteSpace ? true : (/true|false/.test(args.allowWhiteSpace) ? (args.allowWhiteSpace == 'true') : true);
-	if ((this.isEmpty(sInput) && this.isEmpty(oElement)) || (this.isEmpty(sType) && this.isEmpty(sRegex))) {
-		return false;
-	}
-	var sInput = this.isEmpty(sInput) ? oElement.value : sInput;
-	if (!this.isEmpty(sRegex)) {
-		bValid = sRegex.test(sInput);
-	} else {
-		switch(sType) {
-			case 'alnum':
-				bValid = (bAllowWhitespace ? /^[a-z0-9\s]+$/i.test(sInput) : /^[a-z0-9]+$/i.test(sInput)); break;
-			case 'alpha':
-				bValid = (bAllowWhitespace ? /^[a-z\s]+$/i.test(sInput) : /^[a-z]+$/i.test(sInput)); break;
-			case 'between':
-				var iInput = bAllowComma ? parseInt(sInput.replace(/\,/g,'')) : parseInt(sInput);
-				bValid = (bInclusive ? (iInput >= iMin && iInput <= iMax) : (iInput > iMin && iInput < iMax)); break;
-			case 'ccnum':
-				if (this.isEmpty(sCCType)) {
-					bValid = /^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/.test(sInput); break;
-				} else {
-					switch(sCCType) {
-						case 'visa':
-							bValid = /^4[0-9]{12}(?:[0-9]{3})?$/.test(sInput); break;
-						case 'mc':
-							bValid = /^5[1-5][0-9]{14}$/.test(sInput); break;
-						case 'amex':
-							bValid = /^3[47][0-9]{13}$/.test(sInput); break;
-						case 'diners':
-							bValid = /^3(?:0[0-5]|[68][0-9])[0-9]{11}$/.test(sInput); break;
-						case 'discover':
-							bValid = /^6(?:011|5[0-9]{2})[0-9]{12}$/.test(sInput); break;
-						case 'jcb':
-							bValid = /^(?:2131|1800|35\d{3})\d{11}$/.test(sInput); break;
-						default:
-							bValid = false;
-					}
-				}
-			case 'date':
-				var date = new Date(sInput);
-				bValid = !(date.toString() == 'NaN' || date.toString() == 'Invalid Date'); break;
-			case 'digits':
-				bValid = /^\d+$/.test(sInput); break;
-			case 'email':
-				bValid = /^([a-z0-9_\.\-])+\@(([a-z0-9\-])+\.)+([a-z0-9]{2,4})+$/i.test(sInput); break;
-			case 'float':
-				bValid = /^[-+]?[0-9]*\.?[0-9]+$/.test(bAllowComma ? sInput.replace(/\,/g,'') : sInput); break;
-			case 'image':
-				if (this.isEmpty(sImageType)) {
-					bValid = /^(png|jpg|jpeg|gif)$/i.test(sInput.split('.').pop()); break;
-				} else {
-					bValid = (sInput.split('.').pop().toLowerCase().match(sImageType) ? true : false); break;
-				}
-			case 'int':
-			case 'integer':
-				bValid = /^[-+]?\d+$/.test(sInput.replace(/\,/g,'')); break;
-			case 'len':
-			case 'length':
-				bValid = (iMin == iMax) ? (sInput.length == iMin) : (sInput.length >= iMin && sInput.length <= iMax); break;
-			case 'phone':
-				bValid = /^\(?(\d{3})\)?[- ]?(\d{3})[- ]?(\d{4})$/.test(sInput); break;
-			case 'notempty':
-				bValid = !this.isEmpty(sInput); break;
-			case 'ssn':
-				bValid = /^[0-9]{3}\-?[0-9]{2}\-?[0-9]{4}$/.test(sInput); break;
-			case 'url':
-				bValid = /\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»""'']))/i.test(sInput); break;
-			case 'zip':
-				bValid = /^\d{5}$|^\d{5}-\d{4}$/.test(sInput); break;
-		}
-	}
-	return bValid;
-};
-Lytebox.prototype.ajax = function(args) {
-	var iIndex = this.http.length;
-	var oRequest = this.getRequestObject();
-	this.http[iIndex] = oRequest;
-	var oHttpArgs = args;
-	oHttpArgs.index = iIndex;
-	oHttpArgs.method = !(/get|post/i.test(oHttpArgs.method)) ? 'get' : oHttpArgs.method;
-	oHttpArgs.cache = !(/true|false/.test(oHttpArgs.cache)) ? true : (oHttpArgs.cache == 'true' || oHttpArgs.cache);
-	if (!this.isEmpty(oHttpArgs.timeout) && (/^\d+$/.test(oHttpArgs.timeout))) {
-		oHttpArgs.timerId = setTimeout("$lb.http["+iIndex+"].abort()", oHttpArgs.timeout);
-	}
-	oRequest.onreadystatechange = function() {
-		return function() {
-			if (oRequest.readyState == 4 && oRequest.status == 200) {
-				if (document.getElementById(oHttpArgs.updateId)) {
-					try {
-						document.getElementById(oHttpArgs.updateId).innerHTML = oRequest.responseText;
-					} catch(e) { alert(e.description ); };
-				}
-				if (typeof oHttpArgs.success === 'function') {
-					oHttpArgs.success(oRequest);
-				}
-				window.clearTimeout(oHttpArgs.timerId);
-				$lb.http[oHttpArgs.index] = null;
-			} else if (oRequest.readyState == 4 && oRequest.status != 200) {
-				if (typeof oHttpArgs.fail === 'function') {
-					oHttpArgs.fail(oRequest);
-				}
-				window.clearTimeout(oHttpArgs.timerId);
-				$lb.http[oHttpArgs.index] = null;
-			}
-		} (oRequest, oHttpArgs);
-	}
-	if (oHttpArgs.method.toLowerCase() == 'post') {
-		var oForm = document.getElementById(oHttpArgs.form);
-		var bStripTags = !(/true|false/.test(args.stripTags)) ? false : (args.stripTags == 'true' || args.stripTags);
-		var sParams = (oForm == null ? this.serialize({ name: oHttpArgs.form, stripTags: bStripTags }) : this.serialize({ element: oForm, stripTags: bStripTags }));
-		var sTimestamp = (!oHttpArgs.cache ? ((/\&/.test(sParams)) ? '&' : '') + new Date().getTime() : '');
-		oRequest.open('post', oHttpArgs.url, true);
-		oRequest.setRequestHeader('Content-type','application/x-www-form-urlencoded');
-		oRequest.send(sParams + sTimestamp);
-	} else {
-		var sTimestamp = (!oHttpArgs.cache ? ((/\?/.test(oHttpArgs.url)) ? '&' : '?') + new Date().getTime() : '');
-		oRequest.open('get', oHttpArgs.url  + sTimestamp, true);
-		oRequest.send();
-	}
-};
-Lytebox.prototype.serialize = function(args) {
-	var sParams = sValue = '';
-	var bStripTags = !(/true|false/.test(args.stripTags)) ? false : (args.stripTags == 'true' || args.stripTags);
-	var oElements = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	if (oElements == null) {
-		for (var i = 0; i < document.forms.length; i++) {
-			if (document.forms[i].name == args.name) {
-				oElements = document.forms[i].elements;
-			}
-		}
-	}
-	for (var i = 0; i < oElements.length; i++) {
-		if ((oElements[i].type == 'checkbox' && !oElements[i].checked) ||
-			(oElements[i].type == 'radio' && !oElements[i].checked) ||
-			(oElements[i].disabled) || (oElements[i].name == '') || (oElements[i].type == 'reset')) {
-			continue;
-		}
-		if (oElements[i].type == 'select-multiple') {
-			for (var j = 0; j < oElements[i].options.length; j++) {
-				if (oElements[i].options[j].selected == true) {
-					sParams += (sParams == '' ? '' : '&') + oElements[i].name + '=' + encodeURIComponent(oElements[i].options[j].value);
-				}
-			}
-		} else {
-			sValue = bStripTags ? this.stripTags({ value: oElements[i].value }) : oElements[i].value;
-			sParams += (sParams == '' ? '' : '&') + oElements[i].name + '=' + encodeURIComponent(sValue);
-		}
-	}
-	return sParams;
-};
-Lytebox.prototype.getRequestObject = function () {
-	var oReq = null;
-	if (window.XMLHttpRequest) {
-		try { oReq = new XMLHttpRequest(); } catch (e) { }
-	} else if (typeof ActiveXObject != 'undefined') {
-		try {
-			oReq = new ActiveXObject("Msxml2.XMLHTTP");
-		} catch (e) {
-			try { oReq = new ActiveXObject("Microsoft.XMLHTTP"); } catch (e) { }
-		}
-	}
-	return oReq;
-};
-Lytebox.prototype.isEmpty = function(args) {
-	var sValue = '';
-	try {
-		sValue = this.isEmpty(args.value) ? args : args.value;
-	} catch(e) {
-		sValue = args;
-	}
-	return (this.trim(sValue) == '' || sValue == 'null' || sValue == null || typeof(sValue) == 'undefined');
-};
-Lytebox.prototype.stripTags = function(args) {
-	var oElement = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	if (!this.isEmpty(oElement)) {
-		oElement.value = String(oElement.value).replace(/(<([^>]+)>)/ig, '');
-	} else {
-		var sValue = '';
-		try {
-			sValue = this.isEmpty(args.value) ? args : args.value;
-		} catch(e) {
-			sValue = args;
-		}
-		return (this.trim(sValue) == '[object Object]') ? '' : String(sValue).replace(/(<([^>]+)>)/ig, '');
-	}
-};
-Lytebox.prototype.trim = function(args) {
-	var sValue = '';
-	try {
-		sValue = this.isEmpty(args.value) ? args : args.value;
-	} catch(e) {
-		sValue = args;
-	}
-	return String(sValue).replace(/^\s+|\s+$/g, '');
-};
-Lytebox.prototype.capitalize = function (args) {
-	return String(args.value ? args.value : args).replace( /(^|\s)([a-z])/g , function(m,p1,p2){return p1+p2.toUpperCase();});
-};
-Lytebox.prototype.hasClass = function (args) {
-	var sClass = this.isEmpty(args.name) ? '' : args.name;
-	var oElement = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	return new RegExp('(\\s|^)' + sClass + '(\\s|$)').test(oElement.className);
-};
-Lytebox.prototype.addClass = function (args) {
-	var sClass = this.isEmpty(args.name) ? '' : args.name;
-	var oElement = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	var aClasses = sClass.split(' ');
-	for (var i = 0; i < aClasses.length; i++) {
-		if (!this.hasClass({ element: oElement, name: aClasses[i] })) {
-			oElement.className += ' ' + aClasses[i];
-		}
-	}
-};
-Lytebox.prototype.removeClass = function (args) {
-	var sClass = this.isEmpty(args.name) ? '' : args.name;
-	var oElement = this.isEmpty(args.id) ? (this.isEmpty(args.element) ? null : args.element) : document.getElementById(args.id);
-	var aClasses = sClass.split(' ');
-	for (var i = 0; i < aClasses.length; i++) {
-		if (this.hasClass({ element: oElement, name: aClasses[i] })) {
-			oElement.className = oElement.className.replace(new RegExp('(\\s|^)' + aClasses[i] + '(\\s|$)'), ' ').replace(/\s+/g, ' ').replace(/^\s|\s$/, '');
-		}
-	}
-};
-if (window.addEventListener) {
-	window.addEventListener("load", initLytebox, false);
-} else if (window.attachEvent) {
-	window.attachEvent("onload", initLytebox);
-} else {
-	window.onload = function() {initLytebox();}
-}
-function initLytebox() { myLytebox = $lb = new Lytebox(true, $lb.http); }
-myLytebox = $lb = new Lytebox(false);
Index: extensions/Slim/local_head.tpl
===================================================================
--- extensions/Slim/local_head.tpl	(revision 28543)
+++ extensions/Slim/local_head.tpl	(revision 28556)
@@ -1,4 +1,4 @@
 {if (($Slim.style_slim)!=3)}
-{combine_script id='lytebox' load='header' require='jquery' path='themes/Slim/js/lytebox.js'}
+{combine_script id='lytebox' load='header' require='jquery' path='themes/Slim/js/jquery.fancybox.js'}
 {/if}
 
@@ -8,2 +8,9 @@
 {combine_script id='columnizer' load='header' require='jquery' path='themes/Slim/js/jquery.columnizer.js'}
 {/if}
+
+{combine_script id='ui' load='header' require='jquery' path='themes/Slim/js/jquery-ui.custom.min.js'}
+{combine_script id='mousewheel' load='footer' require='jquery' path='themes/Slim/js/jquery.mousewheel.min.js'}
+{combine_script id='kinetic' load='footer' require='jquery' path='themes/Slim/js/jquery.kinetic.min.js'}
+{combine_script id='smoothdivscroll' load='footer' path='themes/Slim/js/jquery.smoothDivScroll-1.3.js'}
+
+
Index: extensions/Slim/template/header.tpl
===================================================================
--- extensions/Slim/template/header.tpl	(revision 28543)
+++ extensions/Slim/template/header.tpl	(revision 28556)
@@ -57,5 +57,4 @@
 
 
-{combine_script id='jcarousel' load='header' require='jquery' path='themes/Slim/js/jquery.jcarousel.js'}
 
 </head>
Index: extensions/Slim/template/index.tpl
===================================================================
--- extensions/Slim/template/index.tpl	(revision 28543)
+++ extensions/Slim/template/index.tpl	(revision 28556)
@@ -3,5 +3,4 @@
 {/if}
 
-{combine_script id='mousewheel' load='header' require='jquery' path='themes/Slim/js/mousewhell.js'}
 
 <div id="content" class="content{if isset($MENUBAR)} contentWithMenu{/if}">
@@ -9,9 +8,9 @@
 {if ($Slim.style_slim)==1}
 	{if !empty($THUMBNAILS)}
-	<div id="home">
-	<a href="{$U_HOME}"><img src="themes/Slim/images/home.png" height="32px" width="32px"></a>
-	</div>
-	<div class="titrePage">
 	<div id="infoBlock">
+	<div class="titrePage slim">
+		<a href="{$U_HOME}">
+		<div id="home"></div>
+		</a>
 	{if !empty($PLUGIN_INDEX_ACTIONS)}{$PLUGIN_INDEX_ACTIONS}{/if}
 	<h2>
@@ -19,5 +18,6 @@
 	</h2>
 	{/if}
-
+	</div>
+	</div>
 {else}
 
@@ -165,45 +165,5 @@
 {if !empty($THUMBNAILS)}
 		{$THUMBNAILS}
-{footer_script}{literal}
-        $('.jcarousel')
-            .jcarousel({
-                 wrap: 'circular',
-            })		
-			.jcarouselAutoscroll({
-			autostart: false
-			});	
-			
-        $('.jcarousel-control-prev')
-            .on('jcarouselcontrol:active', function() {
-                $(this).removeClass('inactive');
-            })
-            .on('jcarouselcontrol:inactive', function() {
-                $(this).addClass('inactive');
-            })
-            .jcarouselControl({
-                target: '-=1'
-            });
 
-        $('.jcarousel-control-next')
-            .on('jcarouselcontrol:active', function() {
-                $(this).removeClass('inactive');
-            })
-            .on('jcarouselcontrol:inactive', function() {
-                $(this).addClass('inactive');
-            })
-            .jcarouselControl({
-                target: '+=1'
-            });
-			
-    $('.jcarousel').mousewheel(function(event, delta) {
-        if (delta > 0)
-            {$('.jcarousel').jcarousel('scroll', '-=1')}
-        else if (delta < 0)
-            {$('.jcarousel').jcarousel('scroll', '+=1')}
-        });
-
-//};	
-		
-{/literal}{/footer_script}
 
 {/if}
@@ -212,53 +172,5 @@
 	{if !empty($CATEGORIES)}
 		{$CATEGORIES}
-		{footer_script}{literal}
-        $('.jcarousel')
-            .jcarousel({
-                 wrap: 'circular'
-            })		
-			.jcarouselAutoscroll({
-			interval: 3000,
-			target: '+=1',
-			autostart: true
-			});	
-			
-        $('.jcarousel-control-prev')
-            .on('jcarouselcontrol:active', function() {
-                $(this).removeClass('inactive');
-            })
-            .on('jcarouselcontrol:inactive', function() {
-                $(this).addClass('inactive');
-            })
-            .jcarouselControl({
-                target: '-=1'
-            });
 
-        $('.jcarousel-control-next')
-            .on('jcarouselcontrol:active', function() {
-                $(this).removeClass('inactive');
-            })
-            .on('jcarouselcontrol:inactive', function() {
-                $(this).addClass('inactive');
-            })
-            .jcarouselControl({
-                target: '+=1'
-            });
-		
-		$('.jcarousel')
-			.on('mouseenter', function(){
-				$(this).jcarouselAutoscroll('stop')
-			})
-			.on('mouseleave', function(){
-				$(this).jcarouselAutoscroll('start')
-			});
-		
-		$('.jcarousel').mousewheel(function(event, delta) {
-        if (delta > 0)
-            {$('.jcarousel').jcarousel('scroll', '-=1')}
-        else if (delta < 0)
-            {$('.jcarousel').jcarousel('scroll', '+=1')}
-        });
-
-{/literal}{/footer_script}
 
 	{/if}
Index: extensions/Slim/template/mainpage_categories.tpl
===================================================================
--- extensions/Slim/template/mainpage_categories.tpl	(revision 28543)
+++ extensions/Slim/template/mainpage_categories.tpl	(revision 28556)
@@ -1,28 +1,48 @@
-{define_derivative name='carousel' width='300' height='300' min_width='300'}
-<div id="carousel">
-<div id="wrap">
-	<div class="jcarousel">
-		<ul>
+{define_derivative name='carousel' width='300' height='350' min_width='350'}
+
+{footer_script}{literal}
+$(document).ready(function () {
+	var isTouch = (('ontouchstart' in window) || (navigator.msMaxTouchPoints > 0)),
+		start;
+	
+	if (isTouch==true){
+	start="";
+	}else{
+	start="onStart";
+	};
+	
+	$("div.carousel").smoothDivScroll({
+		autoScrollingMode: start,
+		touchScrolling: true,
+		autoScrollingStep: 5,
+		mousewheelScrolling: "allDirections",
+		manualContinuousScrolling: true,
+		
+	});	
+			
+	$("div.carousel").bind("mouseover", function() {
+		$(this).smoothDivScroll("stopAutoScrolling");
+	}).bind("mouseout", function() {
+		$(this).smoothDivScroll("startAutoScrolling");
+	});	
+});
+{/literal}{/footer_script}
+
+<div class="carousel">
 			{foreach from=$category_thumbnails item=cat}
-				<li>
 						<div class="illustration">
 							<a href="{$cat.URL}">
 								<img src="{$pwg->derivative_url($carousel, $cat.representative.src_image)}" alt="{$cat.TN_ALT}" title="{$cat.NAME|@replace:'"':' '|@strip_tags:false} - {'display this album'|@translate}" min-width="{$carousel->max_width()}" height="{$carousel->max_height()-22}"/>
-							</a>
-						</div>
+							
 						<div class="CatMPdescription">
 							<h3>
-								<a href="{$cat.URL}">{$cat.NAME}</a>
+								{$cat.NAME}
 							</h3>
 							<div>
 								{$cat.CAPTION_NB_IMAGES}
+						</div>
 							</div>	
+						</a>
 						</div>
-				</li>
 			{/foreach}
-		</ul>
-	</div>
 </div>
-	<a href="#" class="jcarousel-control-prev">&lsaquo;</a>
-    <a href="#" class="jcarousel-control-next">&rsaquo;</a>
-</div>
Index: extensions/Slim/template/menubar.tpl
===================================================================
--- extensions/Slim/template/menubar.tpl	(revision 28543)
+++ extensions/Slim/template/menubar.tpl	(revision 28556)
@@ -1,2 +1,3 @@
+{if !empty($blocks) }
 <div id=menubar>	
 <span id="menu_start">
@@ -33,5 +34,5 @@
 			</div>
 		</div>
+{/if}
 
 
-
Index: extensions/Slim/template/thumbnails.tpl
===================================================================
--- extensions/Slim/template/thumbnails.tpl	(revision 28543)
+++ extensions/Slim/template/thumbnails.tpl	(revision 28556)
@@ -1,3 +1,3 @@
-{define_derivative name='carousel' width='300' height='300' min_width='300'}
+{define_derivative name='carousel' width='300' height='350' min_width='350'}
 {php}
     global $page, $template;
@@ -6,33 +6,73 @@
 {/php}
 
+{footer_script}{literal}
+$(document).ready(function () {
+	var isTouch = (('ontouchstart' in window) || (navigator.msMaxTouchPoints > 0)),
+		start;
+	
+	if (isTouch==true){
+	start="";
+	}else{
+	start="onStart";
+	};
+	
+	$("div.carousel").smoothDivScroll({
+		autoScrollingMode: start,
+		touchScrolling: true,
+		autoScrollingStep:5,
+		mousewheelScrolling: "allDirections",
+		manualContinuousScrolling: true,
+	});	
+			
+	$("div.carousel").bind("mouseover", function() {
+		$(this).smoothDivScroll("stopAutoScrolling");
+	}).bind("mouseout", function() {
+		$(this).smoothDivScroll("startAutoScrolling");
+	});	
+	
+	
+	$('.fancybox').fancybox({
+		helpers : {
+    		title : {
+    			type : 'over'
+    		},
+		},	
+		afterLoad: function() {
+		$("div.carousel").smoothDivScroll("stopAutoScrolling");
+		},
+		afterClose: function() {
+		$("div.carousel").smoothDivScroll("startAutoScrolling");
+		}
+	});
+});
+{/literal}{/footer_script}
 
-<div id="carousel">
-	<div id="wrap">
-		<div class="jcarousel">
-			<ul>
+		
+			
+
+
+	<div class="carousel">
 			{if !empty($category_thumbnails)}
-				{foreach from=$category_thumbnails item=cat}
-				<li>
-					<div class="illustration">
-						<a href="{$cat.URL}">
-							<img src="{$pwg->derivative_url($carousel, $cat.representative.src_image)}" alt="{$cat.TN_ALT}" title="{$cat.NAME|@replace:'"':' '|@strip_tags:false} - {'display this album'|@translate}" min-width="{$carousel->max_width()}" height="{$carousel->max_height()-22}"/>
+			{foreach from=$category_thumbnails item=cat}
+						<div class="illustration">
+							<a href="{$cat.URL}">
+								<img src="{$pwg->derivative_url($carousel, $cat.representative.src_image)}" alt="{$cat.TN_ALT}" title="{$cat.NAME|@replace:'"':' '|@strip_tags:false} - {'display this album'|@translate}" min-width="{$carousel->max_width()}" height="{$carousel->max_height()-22}"/>
+							
+						<div class="CatMPdescription">
+							<h3>
+								{$cat.NAME}
+							</h3>
+							<div>
+								{$cat.CAPTION_NB_IMAGES}
+						</div>
+							</div>	
 						</a>
-					</div>
-					<div class="CatMPdescription">
-						<h3>
-							<a href="{$cat.URL}">{$cat.NAME}</a>
-						</h3>
-						<div>
-							{$cat.CAPTION_NB_IMAGES}
-						</div>	
-					</div>
-				</li>
-				{/foreach}
+						</div>
+			{/foreach}
 			{/if}
 				{foreach from=$thumbnails item=thumbnail}
 				{assign var=derivative value=$pwg->derivative($carousel, $thumbnail.src_image)}
-				<li>
 					<div class="illustration">
-						<a href="{if ($Slim.style_slim)!=3}{$thumbnail.path}" class="lytebox" rev="slide:true group:name showNavigation:true navType:1 slideInterval:6000"{else}{$thumbnail.URL}"{/if} title="{$thumbnail.NAME|strip_tags:false|replace:'\'':'&#39;'|replace:'"':'&quot;'}">
+						<a href="{if ($Slim.style_slim)!=3}{$thumbnail.path}" class="fancybox" data-fancybox-group="gallery"{else}{$thumbnail.URL}"{/if} title="{$thumbnail.NAME|strip_tags:false|replace:'\'':'&#39;'|replace:'"':'&quot;'}">
 						<img class="thumbnail" src="{$derivative->get_url()}" alt="{$thumbnail.TN_ALT}" title="{$thumbnail.TN_TITLE}" height="{$carousel->max_height()-22}"/>
 						{if $SHOW_THUMBNAIL_CAPTION }
@@ -62,10 +102,5 @@
 						</a>	
 					</div>	
-				</li>
 				{/foreach}
-			</ul>
-		</div>
 	</div>
-	<a href="#" class="jcarousel-control-prev">&lsaquo;</a>
-    <a href="#" class="jcarousel-control-next">&rsaquo;</a>
-</div>
+
Index: extensions/Slim/theme.css
===================================================================
--- extensions/Slim/theme.css	(revision 28543)
+++ extensions/Slim/theme.css	(revision 28556)
@@ -12,10 +12,10 @@
 A:hover{color:#8F8F8F;border:none}
 .commentsList{overflow:inherit}
-#theHeader{text-align:left;padding-left:100px;padding-top:70px;position:relative;margin-bottom:10px}
+#theHeader{position:relative;text-align:left;padding-top:70px;position:relative;margin:10px auto;width:95%}
 #theHeader H1{display:inline-block;text-align:left;font-size:280%;margin:0}
 #theHeader p{display:inline-block;font-size:130%;position:absolute;right:40px;bottom:0}
-#content{margin:0}
+#content{margin:0 auto;width:95%}
 .content H2{margin:3px 0 0}
-#infoBlock,#imageHeaderBar{background:rgba(239, 239, 239, 1);border-radius:3px;box-shadow:0 1px 1px rgba(0, 0, 0, 0.4) inset, 0 1px rgba(255, 255, 255, 0.4); margin:0 40px}
+#infoBlock,#imageHeaderBar{background:rgba(239, 239, 239, 1);border-radius:3px;box-shadow:0 1px 1px rgba(0, 0, 0, 0.4) inset, 0 1px rgba(255, 255, 255, 0.4); margin:0}
 .switchBox{background:#5f5f5f; color:#fff}
 .switchBox a{color:#fff}
@@ -25,5 +25,4 @@
 .message{color:#FFF;background:#666}
 .description{margin-left:20px;padding-bottom:10px}
-#home{padding-bottom:20px}
 .logcontener{Background:#EFEFEF;border:1px solid #afafaf;border-radius:5px;margin-top:40px}
 .logcontener SPAN.property{width:100%}
@@ -36,6 +35,6 @@
 
 /*=========================================categorie page======================================================*/
-.illustration{border-radius:7px;position:relative;margin-right:10px;float:none}
-.illustration img{display:block;border-radius:7px;margin:0 auto}
+.illustration{margin-right:10px;position:relative}
+.illustration img{display:block;border-radius:4px;margin:0 auto}
 .content .additional_info{text-align:left;padding-bottom:20px;padding-left:25px}
 .CatMPdescription h3{background:transparent;margin:5px 30px 0 0}
@@ -97,4 +96,8 @@
 .close{cursor:pointer;height:16px;width:16px;background:url(images/menu/close.png) no-repeat;float:right}
 .close:hover{background:url(images/menu/close.png) no-repeat 0 -16px }
+#home {margin:0 40px 0 10px;width:32px;height:32px;background:url(images/menu/home_w.png) no-repeat left top}
+#home:hover{background-position:left -30px}
+.slim a{float:left}
+.slim{padding-top:5px}
 
 /*=========================================picture page======================================================*/
@@ -137,5 +140,5 @@
 
 /*___comment___*/
-#comments{padding:0 0 40px;text-align:left}
+#comments{padding:0 0 40px;text-align:left;margin:0 50px}
 #commentAdd,#pictureCommentList{width:48%}
 #pictureCommentList li{margin-top:20px}
@@ -160,44 +163,53 @@
 
 /*=========================================carousel======================================================*/
-#carousel{position:relative}
-.jcarousel{position:relative;overflow:hidden}
-.jcarousel ul{width:20000em;position:relative;list-style:none;margin:0;padding:0}
-.jcarousel li {float: left}
-#wrap{position:relative;margin:50px;padding:20px 20px 40px;border:1px solid rgba(0,0,0,0.5);border-radius:8px;background:rgba(0,0,0,0.25);box-shadow:0 2px 6px rgba(0,0,0,0.5),inset 0 1px rgba(255,255,255,0.3),inset 0 2px rgba(255,255,255,0.2),inset 0 10px 20px rgba(255,255,255,0.25),inset 0 -15px 30px rgba(0,0,0,0.3)}
-.jcarousel-control-prev,.jcarousel-control-next{position:absolute;top:160px;width:30px;height:30px;text-align:center;background:#4E443C;color:#fff;text-decoration:none;text-shadow:0 0 1px #000;font:24px/27px Arial, sans-serif;-webkit-border-radius:30px;-moz-border-radius:30px;border-radius:30px;-webkit-box-shadow:0 0 2px #999;-moz-box-shadow:0 0 2px #999;box-shadow:0 0 2px #999}
-.jcarousel-control-prev{left:80px}
-.jcarousel-control-next{right:80px}
-.jcarousel-control-prev:hover span,.jcarousel-control-next:hover span{display:block}
-.jcarousel-control-prev.inactive,.jcarousel-control-next.inactive{opacity: .5;cursor:default}
-
-/*=========================================Lytebox======================================================*/
-#lbOverlay{position:fixed;top:0px;left:0px;z-index:99997;width:100%;height:100%;background:#000}
-#lbMain{position:absolute;left:0px;width:100%;z-index:99998;text-align:center;line-height:0;isplay:-moz-inline-stack}
-#lbMain a img{border:1px solid #FFF}
-#lbOuterContainer{position:relative;background:transparent;width:200px;height:200px;margin:0px auto;border:2px solid #CCC}
-#lbTopContainer,#lbBottomContainer{font:0.9em/1.4em Verdana,Helvetica,sans-serif;background:transparent;width:100%;overflow:hidden;margin:0px auto;padding:0px;position:relative;z-index:14;display:none}
-#lbTopContainer{overflow:hidden;margin-top:5px}
-#lbImage,#lbIframe{border:1px solid #CCC}
-#lbImageContainer,#lbIframeContainer{z-index: 12}
-#lbLoading{height:100%;width:100%;margin-top:-10px;background:url("images/Lytebox/loading.gif") no-repeat center center}
-#lbHoverNav{position:absolute;top:0px;left:0px;height:100%;width:100%;z-index:10}
-#lbImageContainer > #lbHoverNav{left:0px}
-#lbHoverNav a{outline: medium none}
-#lbPrevHov{width:48%;height:100%;background:url("images/Lytebox/blank.gif") no-repeat 0% 0%;display:block;left:0px;float:left;margin-left:3px;border:medium none !important}
-#lbPrevHov:hover,#lbPrevHov:visited{background:url("images/Lytebox/prev_t.png") no-repeat left 45%}
-#lbNextHov{width:48%;height:100%;background:url("images/Lytebox/blank.gif") no-repeat 0% 0%;display:block;right:0px;margin-right:3px;border:medium none !important;float: right}
-#lbNextHov:hover,#lbNextHov:visited{background: url("images/Lytebox/next_t.png") no-repeat right 45%}
-#lbTopData,#lbBottomData{float:left;text-align:left;padding-left: 10px}
-#lbBottomData{padding-bottom:0.5em;color:#FFF}
-#lbTopNav,#lbBottomNav{float:right;text-align:right;padding-right:10px;padding-top:10px}
-#lbNumTop,#lbNumBottom{font-style:italic}
-#lbDescBottom{display:block}
-#lbTitleTop,#lbTopNav{margin-top:0.3em}
-#lbTitleTop,#lbTitleBottom{display:block;font-weight:bold}
-#lbClose,#lbCloseTop{width:10px;height:10px;float:right;margin:0px 0px 1px 8px;border:medium none !important;background:url("images/Lytebox/close.png") no-repeat 0% 0%}
-#lbPrint,#lbPrintTop{width:26px;height:28px;float:right;margin:0px 0px 1px 8px;border:medium none !important;background:url("images/Lytebox/print.png") no-repeat 0% 0%}
-#lbPlay,#lbPlayTop{width:10px;height:10px;float:right;margin:0px 0px 1px 8px;border:medium none !important;background:url("images/Lytebox/play.png") no-repeat 0% 0%}
-#lbPause,#lbPauseTop{width:10px;height:10px;float:right;margin:0px 0px 1px 8px;border:medium none !important;background:url("images/Lytebox/pause.png") no-repeat 0% 0%}
-#lbClose,#lbPrint,#lbPlay,#lbPause{margin:0px 0px 6px 8px}
+div.carousel{position:relative;height:355px;width:100%;margin:50px auto;padding:20px 0 20px;border:1px solid rgba(0,0,0,0.5);border-radius:4px;background:rgba(0,0,0,0.25);box-shadow:0 2px 6px rgba(0,0,0,0.5),inset 0 1px rgba(255,255,255,0.3),inset 0 2px rgba(255,255,255,0.2),inset 0 10px 20px rgba(255,255,255,0.25),inset 0 -15px 30px rgba(0,0,0,0.3)}
+div.scrollingHotSpotLeft{min-width:75px;width:10%;height:100%;background-image: url(images/smoothDivScroll/big_transparent.gif);background-repeat:repeat;background-position:center center;position:absolute;z-index:200;left:0;margin-top:-20px;cursor:url(images/smoothDivScroll/cursors/cursor_arrow_left.png), url(images/smoothDivScroll/cursors/cursor_arrow_left.cur),w-resize}
+div.scrollingHotSpotLeftVisible{background-image:url(images/smoothDivScroll/arrow_left.gif);background-color:#fff;background-repeat:no-repeat;opacity:0.35;-moz-opacity:0.35;filter:alpha(opacity = 35);zoom:1}
+div.scrollingHotSpotRight{min-width:75px;width:10%;height:100%;background-image:url(images/smoothDivScroll/big_transparent.gif);background-repeat:repeat;background-position:center center;position:absolute;z-index:200;right:0;margin-top:-20px;cursor:url(images/smoothDivScroll/cursors/cursor_arrow_right.png), url(images/smoothDivScroll/cursors/cursor_arrow_right.cur),e-resize}
+div.scrollingHotSpotRightVisible{background-image:url(images/smoothDivScroll/arrow_right.gif);background-color:#fff;background-repeat:no-repeat;opacity:0.35;filter:alpha(opacity = 35);-moz-opacity:0.35;zoom:1}
+.scrollWrapper{position:relative;overflow:hidden;width:100%;height:100%}
+div.scrollableArea{position:relative;width:auto;height:100%}
+
+/*=========================================fancyBox v2.1.5 fancyapps.com | fancyapps.com/fancybox/#license========================================= */
+.fancybox-wrap,.fancybox-skin,.fancybox-outer,.fancybox-inner,.fancybox-image,.fancybox-wrap iframe,.fancybox-wrap object,.fancybox-nav,.fancybox-nav span,.fancybox-tmp{padding:0;margin:0;border:0;outline:none;vertical-align:top}
+.fancybox-wrap{	position:absolute;top:0;left:0;z-index:8020}
+.fancybox-skin{position:relative;background:#f9f9f9;color:#444;text-shadow:none;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}
+.fancybox-opened{z-index:8030}
+.fancybox-opened .fancybox-skin{-webkit-box-shadow:0 10px 25px rgba(0, 0, 0, 0.5);-moz-box-shadow:0 10px 25px rgba(0, 0, 0, 0.5);box-shadow:0 10px 25px rgba(0, 0, 0, 0.5)}
+.fancybox-outer, .fancybox-inner{position:relative}
+.fancybox-inner{overflow: hidden}
+.fancybox-type-iframe .fancybox-inner{-webkit-overflow-scrolling:touch}
+.fancybox-error{color:#444;font:14px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;margin:0;padding:15px;white-space:nowrap}
+.fancybox-image, .fancybox-iframe{display:block;width:100%;height:100%}
+.fancybox-image{max-width:100%;max-height:100%}
+#fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span{background-image: url('images/fancybox/fancybox_sprite.png')}
+#fancybox-loading {position:fixed;top:50%;left:50%;margin-top:-22px;	margin-left:-22px;background-position:0 -108px;opacity:0.8;cursor:pointer;z-index:8060}
+#fancybox-loading div{width:44px;height:44px;background:url('images/fancybox/fancybox_loading.gif') center center no-repeat}
+.fancybox-close{position:absolute;top:-18px;right:-18px;width:36px;height:36px;cursor:pointer;z-index: 8040}
+.fancybox-nav{position:absolute;top: 0;width:40%;height:100%;cursor:pointer;text-decoration:none;background:transparent url('images/fancybox/blank.gif');-webkit-tap-highlight-color:rgba(0,0,0,0);z-index:8040}
+.fancybox-prev {left:0}
+.fancybox-next {right:0}
+.fancybox-nav span {position:absolute;top:50%;width:36px;height:34px;margin-top:-18px;cursor:pointer;z-index:8040;visibility:hidden}
+.fancybox-prev span {left:10px;background-position:0 -36px}
+.fancybox-next span {right:10px;background-position:0 -72px}
+.fancybox-nav:hover span {visibility:visible}
+.fancybox-tmp {position: absolute;top:-99999px;left:-99999px;visibility:hidden;max-width:99999px;max-height:99999px;overflow:visible !important}
+.fancybox-lock {overflow:hidden !important;width:auto}
+.fancybox-lock body {overflow:hidden !important}
+.fancybox-lock-test {overflow-y:hidden !important}
+.fancybox-overlay {position: absolute;top:0;left:0;overflow:hidden;display:none;z-index:8010;background:url('images/fancybox/fancybox_overlay.png')}
+.fancybox-overlay-fixed {position:fixed;bottom:0;right:0}
+.fancybox-lock .fancybox-overlay {overflow:auto;overflow-y:scroll}
+.fancybox-title {visibility:hidden;font:normal 13px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;position:relative;text-shadow:none;z-index:8050}
+.fancybox-opened .fancybox-title {visibility:visible}
+.fancybox-title-float-wrap {	position:absolute;bottom:0;right:50%;margin-bottom:-35px;z-index:8050;text-align:center}
+.fancybox-title-float-wrap .child {display:inline-block;margin-right:-100%;padding:2px 20px;background:transparent;background:rgba(0, 0, 0, 0.8);-webkit-border-radius:15px;-moz-border-radius:15px;border-radius:15px;text-shadow:0 1px 2px #222;color:#FFF;font-weight:bold;line-height:24px;white-space:nowrap}
+.fancybox-title-outside-wrap {position:relative;	margin-top:10px;color:#fff}
+.fancybox-title-inside-wrap {padding-top:10px}
+.fancybox-title-over-wrap {position:absolute;bottom:0;left:0;color:#fff;padding:10px;background:#000;background:rgba(0, 0, 0, .8)}
+@media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min--moz-device-pixel-ratio: 1.5), only screen and (min-device-pixel-ratio: 1.5){
+	#fancybox-loading, .fancybox-close, .fancybox-prev span, .fancybox-next span {background-image:url('images/fancybox/fancybox_sprite@2x.png');background-size:44px 152px}
+	#fancybox-loading div {background-image:url('images/fancybox/fancybox_loading@2x.gif');background-size:24px 24px}
+}
 
 /*==========================================plugin=====================================================*/
Index: extensions/Slim/themeconf.inc.php
===================================================================
--- extensions/Slim/themeconf.inc.php	(revision 28543)
+++ extensions/Slim/themeconf.inc.php	(revision 28556)
@@ -33,16 +33,16 @@
 	{
 	global $user, $page, $conf;
-		$user['nb_image_page']=999;
 		$page['nb_image_page']=999;
 		$conf['nb_categories_page']=999;
 	}
 }
-add_event_handler('get_categories_menu_sql_where', 'mic_get_categories_menu_sql_where', EVENT_HANDLER_PRIORITY_NEUTRAL, 3 );
-if(!function_exists('mic_get_categories_menu_sql_where'))
+
+add_event_handler('loc_begin_index', 'block_expand');
+if(!function_exists('block_expand'))
 {
-	function mic_get_categories_menu_sql_where($where){	
-		global $page;
-			$where = '1';
-		return $where;
+	function block_expand()
+	{
+	global $user;
+		$user['expand']=true;
 	}
 }
