From 6d182e241055bffa3bf04adcc1aef5db530fe4cd Mon Sep 17 00:00:00 2001 From: raylu Date: Sun, 3 Jul 2011 04:32:10 -0700 Subject: run fromdos on all the php, css, and js files --- webroot/js/dd_belatedpng.js | 654 +++++++++++++++++----------------- webroot/js/functions.js | 92 ++--- webroot/js/jquery.anchor.js | 76 ++-- webroot/js/jquery.form.js | 72 ++-- webroot/js/jquery.lightbox-0.5.min.js | 82 ++--- 5 files changed, 488 insertions(+), 488 deletions(-) (limited to 'webroot/js') diff --git a/webroot/js/dd_belatedpng.js b/webroot/js/dd_belatedpng.js index 7e38cc3..58ae134 100644 --- a/webroot/js/dd_belatedpng.js +++ b/webroot/js/dd_belatedpng.js @@ -1,328 +1,328 @@ -/** -* DD_belatedPNG: Adds IE6 support: PNG images for CSS background-image and HTML . -* Author: Drew Diller -* Email: drew.diller@gmail.com -* URL: http://www.dillerdesign.com/experiment/DD_belatedPNG/ -* Version: 0.0.8a -* Licensed under the MIT License: http://dillerdesign.com/experiment/DD_belatedPNG/#license -* -* Example usage: -* DD_belatedPNG.fix('.png_bg'); // argument is a CSS selector -* DD_belatedPNG.fixPng( someNode ); // argument is an HTMLDomElement -**/ - -/* -PLEASE READ: -Absolutely everything in this script is SILLY. I know this. IE's rendering of certain pixels doesn't make sense, so neither does this code! -*/ - -var DD_belatedPNG = { - ns: 'DD_belatedPNG', - imgSize: {}, - delay: 10, - nodesFixed: 0, - createVmlNameSpace: function () { /* enable VML */ - if (document.namespaces && !document.namespaces[this.ns]) { - document.namespaces.add(this.ns, 'urn:schemas-microsoft-com:vml'); - } - }, - createVmlStyleSheet: function () { /* style VML, enable behaviors */ - /* - Just in case lots of other developers have added - lots of other stylesheets using document.createStyleSheet - and hit the 31-limit mark, let's not use that method! - further reading: http://msdn.microsoft.com/en-us/library/ms531194(VS.85).aspx - */ - var screenStyleSheet, printStyleSheet; - screenStyleSheet = document.createElement('style'); - screenStyleSheet.setAttribute('media', 'screen'); - document.documentElement.firstChild.insertBefore(screenStyleSheet, document.documentElement.firstChild.firstChild); - if (screenStyleSheet.styleSheet) { - screenStyleSheet = screenStyleSheet.styleSheet; - screenStyleSheet.addRule(this.ns + '\\:*', '{behavior:url(#default#VML)}'); - screenStyleSheet.addRule(this.ns + '\\:shape', 'position:absolute;'); - screenStyleSheet.addRule('img.' + this.ns + '_sizeFinder', 'behavior:none; border:none; position:absolute; z-index:-1; top:-10000px; visibility:hidden;'); /* large negative top value for avoiding vertical scrollbars for large images, suggested by James O'Brien, http://www.thanatopsic.org/hendrik/ */ - this.screenStyleSheet = screenStyleSheet; - - /* Add a print-media stylesheet, for preventing VML artifacts from showing up in print (including preview). */ - /* Thanks to Rémi Prévost for automating this! */ - printStyleSheet = document.createElement('style'); - printStyleSheet.setAttribute('media', 'print'); - document.documentElement.firstChild.insertBefore(printStyleSheet, document.documentElement.firstChild.firstChild); - printStyleSheet = printStyleSheet.styleSheet; - printStyleSheet.addRule(this.ns + '\\:*', '{display: none !important;}'); - printStyleSheet.addRule('img.' + this.ns + '_sizeFinder', '{display: none !important;}'); - } - }, - readPropertyChange: function () { - var el, display, v; - el = event.srcElement; - if (!el.vmlInitiated) { - return; - } - if (event.propertyName.search('background') != -1 || event.propertyName.search('border') != -1) { - DD_belatedPNG.applyVML(el); - } - if (event.propertyName == 'style.display') { - display = (el.currentStyle.display == 'none') ? 'none' : 'block'; - for (v in el.vml) { - if (el.vml.hasOwnProperty(v)) { - el.vml[v].shape.style.display = display; - } - } - } - if (event.propertyName.search('filter') != -1) { - DD_belatedPNG.vmlOpacity(el); - } - }, - vmlOpacity: function (el) { - if (el.currentStyle.filter.search('lpha') != -1) { - var trans = el.currentStyle.filter; - trans = parseInt(trans.substring(trans.lastIndexOf('=')+1, trans.lastIndexOf(')')), 10)/100; - el.vml.color.shape.style.filter = el.currentStyle.filter; /* complete guesswork */ - el.vml.image.fill.opacity = trans; /* complete guesswork */ - } - }, - handlePseudoHover: function (el) { - setTimeout(function () { /* wouldn't work as intended without setTimeout */ - DD_belatedPNG.applyVML(el); - }, 1); - }, - /** - * This is the method to use in a document. - * @param {String} selector - REQUIRED - a CSS selector, such as '#doc .container' - **/ - fix: function (selector) { - if (this.screenStyleSheet) { - var selectors, i; - selectors = selector.split(','); /* multiple selectors supported, no need for multiple calls to this anymore */ - for (i=0; i size.H) { - c.B = size.H; - } - el.vml.image.shape.style.clip = 'rect('+c.T+'px '+(c.R+fudge)+'px '+c.B+'px '+(c.L+fudge)+'px)'; - } - else { - el.vml.image.shape.style.clip = 'rect('+dC.T+'px '+dC.R+'px '+dC.B+'px '+dC.L+'px)'; - } - }, - figurePercentage: function (bg, size, axis, position) { - var horizontal, fraction; - fraction = true; - horizontal = (axis == 'X'); - switch(position) { - case 'left': - case 'top': - bg[axis] = 0; - break; - case 'center': - bg[axis] = 0.5; - break; - case 'right': - case 'bottom': - bg[axis] = 1; - break; - default: - if (position.search('%') != -1) { - bg[axis] = parseInt(position, 10) / 100; - } - else { - fraction = false; - } - } - bg[axis] = Math.ceil( fraction ? ( (size[horizontal?'W': 'H'] * bg[axis]) - (size[horizontal?'w': 'h'] * bg[axis]) ) : parseInt(position, 10) ); - if (bg[axis] % 2 === 0) { - bg[axis]++; - } - return bg[axis]; - }, - fixPng: function (el) { - el.style.behavior = 'none'; - var lib, els, nodeStr, v, e; - if (el.nodeName == 'BODY' || el.nodeName == 'TD' || el.nodeName == 'TR') { /* elements not supported yet */ - return; - } - el.isImg = false; - if (el.nodeName == 'IMG') { - if(el.src.toLowerCase().search(/\.png$/) != -1) { - el.isImg = true; - el.style.visibility = 'hidden'; - } - else { - return; - } - } - else if (el.currentStyle.backgroundImage.toLowerCase().search('.png') == -1) { - return; - } - lib = DD_belatedPNG; - el.vml = {color: {}, image: {}}; - els = {shape: {}, fill: {}}; - for (v in el.vml) { - if (el.vml.hasOwnProperty(v)) { - for (e in els) { - if (els.hasOwnProperty(e)) { - nodeStr = lib.ns + ':' + e; - el.vml[v][e] = document.createElement(nodeStr); - } - } - el.vml[v].shape.stroked = false; - el.vml[v].shape.appendChild(el.vml[v].fill); - el.parentNode.insertBefore(el.vml[v].shape, el); - } - } - el.vml.image.shape.fillcolor = 'none'; /* Don't show blank white shapeangle when waiting for image to load. */ - el.vml.image.fill.type = 'tile'; /* Makes image show up. */ - el.vml.color.fill.on = false; /* Actually going to apply vml element's style.backgroundColor, so hide the whiteness. */ - lib.attachHandlers(el); - lib.giveLayout(el); - lib.giveLayout(el.offsetParent); - el.vmlInitiated = true; - lib.applyVML(el); /* Render! */ - } -}; -try { - document.execCommand("BackgroundImageCache", false, true); /* TredoSoft Multiple IE doesn't like this, so try{} it */ -} catch(r) {} -DD_belatedPNG.createVmlNameSpace(); +/** +* DD_belatedPNG: Adds IE6 support: PNG images for CSS background-image and HTML . +* Author: Drew Diller +* Email: drew.diller@gmail.com +* URL: http://www.dillerdesign.com/experiment/DD_belatedPNG/ +* Version: 0.0.8a +* Licensed under the MIT License: http://dillerdesign.com/experiment/DD_belatedPNG/#license +* +* Example usage: +* DD_belatedPNG.fix('.png_bg'); // argument is a CSS selector +* DD_belatedPNG.fixPng( someNode ); // argument is an HTMLDomElement +**/ + +/* +PLEASE READ: +Absolutely everything in this script is SILLY. I know this. IE's rendering of certain pixels doesn't make sense, so neither does this code! +*/ + +var DD_belatedPNG = { + ns: 'DD_belatedPNG', + imgSize: {}, + delay: 10, + nodesFixed: 0, + createVmlNameSpace: function () { /* enable VML */ + if (document.namespaces && !document.namespaces[this.ns]) { + document.namespaces.add(this.ns, 'urn:schemas-microsoft-com:vml'); + } + }, + createVmlStyleSheet: function () { /* style VML, enable behaviors */ + /* + Just in case lots of other developers have added + lots of other stylesheets using document.createStyleSheet + and hit the 31-limit mark, let's not use that method! + further reading: http://msdn.microsoft.com/en-us/library/ms531194(VS.85).aspx + */ + var screenStyleSheet, printStyleSheet; + screenStyleSheet = document.createElement('style'); + screenStyleSheet.setAttribute('media', 'screen'); + document.documentElement.firstChild.insertBefore(screenStyleSheet, document.documentElement.firstChild.firstChild); + if (screenStyleSheet.styleSheet) { + screenStyleSheet = screenStyleSheet.styleSheet; + screenStyleSheet.addRule(this.ns + '\\:*', '{behavior:url(#default#VML)}'); + screenStyleSheet.addRule(this.ns + '\\:shape', 'position:absolute;'); + screenStyleSheet.addRule('img.' + this.ns + '_sizeFinder', 'behavior:none; border:none; position:absolute; z-index:-1; top:-10000px; visibility:hidden;'); /* large negative top value for avoiding vertical scrollbars for large images, suggested by James O'Brien, http://www.thanatopsic.org/hendrik/ */ + this.screenStyleSheet = screenStyleSheet; + + /* Add a print-media stylesheet, for preventing VML artifacts from showing up in print (including preview). */ + /* Thanks to Rémi Prévost for automating this! */ + printStyleSheet = document.createElement('style'); + printStyleSheet.setAttribute('media', 'print'); + document.documentElement.firstChild.insertBefore(printStyleSheet, document.documentElement.firstChild.firstChild); + printStyleSheet = printStyleSheet.styleSheet; + printStyleSheet.addRule(this.ns + '\\:*', '{display: none !important;}'); + printStyleSheet.addRule('img.' + this.ns + '_sizeFinder', '{display: none !important;}'); + } + }, + readPropertyChange: function () { + var el, display, v; + el = event.srcElement; + if (!el.vmlInitiated) { + return; + } + if (event.propertyName.search('background') != -1 || event.propertyName.search('border') != -1) { + DD_belatedPNG.applyVML(el); + } + if (event.propertyName == 'style.display') { + display = (el.currentStyle.display == 'none') ? 'none' : 'block'; + for (v in el.vml) { + if (el.vml.hasOwnProperty(v)) { + el.vml[v].shape.style.display = display; + } + } + } + if (event.propertyName.search('filter') != -1) { + DD_belatedPNG.vmlOpacity(el); + } + }, + vmlOpacity: function (el) { + if (el.currentStyle.filter.search('lpha') != -1) { + var trans = el.currentStyle.filter; + trans = parseInt(trans.substring(trans.lastIndexOf('=')+1, trans.lastIndexOf(')')), 10)/100; + el.vml.color.shape.style.filter = el.currentStyle.filter; /* complete guesswork */ + el.vml.image.fill.opacity = trans; /* complete guesswork */ + } + }, + handlePseudoHover: function (el) { + setTimeout(function () { /* wouldn't work as intended without setTimeout */ + DD_belatedPNG.applyVML(el); + }, 1); + }, + /** + * This is the method to use in a document. + * @param {String} selector - REQUIRED - a CSS selector, such as '#doc .container' + **/ + fix: function (selector) { + if (this.screenStyleSheet) { + var selectors, i; + selectors = selector.split(','); /* multiple selectors supported, no need for multiple calls to this anymore */ + for (i=0; i size.H) { + c.B = size.H; + } + el.vml.image.shape.style.clip = 'rect('+c.T+'px '+(c.R+fudge)+'px '+c.B+'px '+(c.L+fudge)+'px)'; + } + else { + el.vml.image.shape.style.clip = 'rect('+dC.T+'px '+dC.R+'px '+dC.B+'px '+dC.L+'px)'; + } + }, + figurePercentage: function (bg, size, axis, position) { + var horizontal, fraction; + fraction = true; + horizontal = (axis == 'X'); + switch(position) { + case 'left': + case 'top': + bg[axis] = 0; + break; + case 'center': + bg[axis] = 0.5; + break; + case 'right': + case 'bottom': + bg[axis] = 1; + break; + default: + if (position.search('%') != -1) { + bg[axis] = parseInt(position, 10) / 100; + } + else { + fraction = false; + } + } + bg[axis] = Math.ceil( fraction ? ( (size[horizontal?'W': 'H'] * bg[axis]) - (size[horizontal?'w': 'h'] * bg[axis]) ) : parseInt(position, 10) ); + if (bg[axis] % 2 === 0) { + bg[axis]++; + } + return bg[axis]; + }, + fixPng: function (el) { + el.style.behavior = 'none'; + var lib, els, nodeStr, v, e; + if (el.nodeName == 'BODY' || el.nodeName == 'TD' || el.nodeName == 'TR') { /* elements not supported yet */ + return; + } + el.isImg = false; + if (el.nodeName == 'IMG') { + if(el.src.toLowerCase().search(/\.png$/) != -1) { + el.isImg = true; + el.style.visibility = 'hidden'; + } + else { + return; + } + } + else if (el.currentStyle.backgroundImage.toLowerCase().search('.png') == -1) { + return; + } + lib = DD_belatedPNG; + el.vml = {color: {}, image: {}}; + els = {shape: {}, fill: {}}; + for (v in el.vml) { + if (el.vml.hasOwnProperty(v)) { + for (e in els) { + if (els.hasOwnProperty(e)) { + nodeStr = lib.ns + ':' + e; + el.vml[v][e] = document.createElement(nodeStr); + } + } + el.vml[v].shape.stroked = false; + el.vml[v].shape.appendChild(el.vml[v].fill); + el.parentNode.insertBefore(el.vml[v].shape, el); + } + } + el.vml.image.shape.fillcolor = 'none'; /* Don't show blank white shapeangle when waiting for image to load. */ + el.vml.image.fill.type = 'tile'; /* Makes image show up. */ + el.vml.color.fill.on = false; /* Actually going to apply vml element's style.backgroundColor, so hide the whiteness. */ + lib.attachHandlers(el); + lib.giveLayout(el); + lib.giveLayout(el.offsetParent); + el.vmlInitiated = true; + lib.applyVML(el); /* Render! */ + } +}; +try { + document.execCommand("BackgroundImageCache", false, true); /* TredoSoft Multiple IE doesn't like this, so try{} it */ +} catch(r) {} +DD_belatedPNG.createVmlNameSpace(); DD_belatedPNG.createVmlStyleSheet(); \ No newline at end of file diff --git a/webroot/js/functions.js b/webroot/js/functions.js index 02319d8..be9a9bb 100644 --- a/webroot/js/functions.js +++ b/webroot/js/functions.js @@ -1,46 +1,46 @@ -// Kameleon Template -//Author: Chris Mooney (http://themeforest.net/user/ChrisMooney) - -// Cufon Setup -jQuery(document).ready(function($) { -Cufon.replace('h3,h4,h5,.process,#tagline '); - - -//Portfolio Hover Effect - $('.portfolio-small li img, .portfolio-list li img').hover(function() { - - $(this).children('a').show(); - $('.portfolio-small li img, .portfolio-list li img').stop().animate({ opacity: .5 }, 300); - $(this).stop().css('opacity', 1); - - }, function() { - $('.portfolio-small li img, .portfolio-list li img').stop().animate({ opacity: 1 }, 300); - - }); - -//Homepage Screenshot Scroll -$(".scrollable").scrollable(); - - -//LightBox Setup - $('.portfolio-small a, .portfolio-list a').lightBox({ - fixedNavigation:true, - overlayOpacity: 0.8, - imageLoading: 'img/lightbox/lightbox-ico-loading.gif', - imageBtnClose: 'img/lightbox/lightbox-btn-close.gif', - imageBtnPrev: 'img/lightbox/lightbox-btn-prev.gif', - imageBtnNext: 'img/lightbox/lightbox-btn-next.gif', - imageBlank: 'img/lightbox/lightbox-blank.gif' - - }); - -// Tipsy Tooltips -$('.tooltip').tipsy({fade: true}); -$('.tooltip.north').tipsy({fade: true, gravity: 's'}); -$('.tooltip.east').tipsy({fade: true, gravity: 'w'}); -$('.tooltip.west').tipsy({fade: true, gravity: 'e'}); -// Form Tooltips -$('form [title]').tipsy({fade: true, trigger: 'focus', gravity: 'w'}); - - -}); +// Kameleon Template +//Author: Chris Mooney (http://themeforest.net/user/ChrisMooney) + +// Cufon Setup +jQuery(document).ready(function($) { +Cufon.replace('h3,h4,h5,.process,#tagline '); + + +//Portfolio Hover Effect + $('.portfolio-small li img, .portfolio-list li img').hover(function() { + + $(this).children('a').show(); + $('.portfolio-small li img, .portfolio-list li img').stop().animate({ opacity: .5 }, 300); + $(this).stop().css('opacity', 1); + + }, function() { + $('.portfolio-small li img, .portfolio-list li img').stop().animate({ opacity: 1 }, 300); + + }); + +//Homepage Screenshot Scroll +$(".scrollable").scrollable(); + + +//LightBox Setup + $('.portfolio-small a, .portfolio-list a').lightBox({ + fixedNavigation:true, + overlayOpacity: 0.8, + imageLoading: 'img/lightbox/lightbox-ico-loading.gif', + imageBtnClose: 'img/lightbox/lightbox-btn-close.gif', + imageBtnPrev: 'img/lightbox/lightbox-btn-prev.gif', + imageBtnNext: 'img/lightbox/lightbox-btn-next.gif', + imageBlank: 'img/lightbox/lightbox-blank.gif' + + }); + +// Tipsy Tooltips +$('.tooltip').tipsy({fade: true}); +$('.tooltip.north').tipsy({fade: true, gravity: 's'}); +$('.tooltip.east').tipsy({fade: true, gravity: 'w'}); +$('.tooltip.west').tipsy({fade: true, gravity: 'e'}); +// Form Tooltips +$('form [title]').tipsy({fade: true, trigger: 'focus', gravity: 'w'}); + + +}); diff --git a/webroot/js/jquery.anchor.js b/webroot/js/jquery.anchor.js index d6db7ab..63bcee3 100644 --- a/webroot/js/jquery.anchor.js +++ b/webroot/js/jquery.anchor.js @@ -1,39 +1,39 @@ -/******* - - *** Anchor Slider by Cedric Dugas *** - *** Http://www.position-absolute.com *** - - Never have an anchor jumping your content, slide it. - - Don't forget to put an id to your anchor ! - You can use and modify this script for any project you want, but please leave this comment as credit. - -*****/ - - - -$(document).ready(function() { - $("a.anchorLink").anchorAnimate() -}); - -jQuery.fn.anchorAnimate = function(settings) { - - settings = jQuery.extend({ - speed : 1100 - }, settings); - - return this.each(function(){ - var caller = this - $(caller).click(function (event) { - event.preventDefault() - var locationHref = window.location.href - var elementClick = $(caller).attr("href") - - var destination = $(elementClick).offset().top; - $("html:not(:animated),body:not(:animated)").animate({ scrollTop: destination}, settings.speed, function() { - window.location.hash = elementClick - }); - return false; - }) - }) +/******* + + *** Anchor Slider by Cedric Dugas *** + *** Http://www.position-absolute.com *** + + Never have an anchor jumping your content, slide it. + + Don't forget to put an id to your anchor ! + You can use and modify this script for any project you want, but please leave this comment as credit. + +*****/ + + + +$(document).ready(function() { + $("a.anchorLink").anchorAnimate() +}); + +jQuery.fn.anchorAnimate = function(settings) { + + settings = jQuery.extend({ + speed : 1100 + }, settings); + + return this.each(function(){ + var caller = this + $(caller).click(function (event) { + event.preventDefault() + var locationHref = window.location.href + var elementClick = $(caller).attr("href") + + var destination = $(elementClick).offset().top; + $("html:not(:animated),body:not(:animated)").animate({ scrollTop: destination}, settings.speed, function() { + window.location.hash = elementClick + }); + return false; + }) + }) } \ No newline at end of file diff --git a/webroot/js/jquery.form.js b/webroot/js/jquery.form.js index e9d5df5..d0e118e 100644 --- a/webroot/js/jquery.form.js +++ b/webroot/js/jquery.form.js @@ -1,37 +1,37 @@ -jQuery(document).ready(function(){ - - $('#contactform').submit(function(){ - - var action = $(this).attr('action'); - - $("#message").slideUp(750,function() { - $('#message').hide(); - - $('#submit') - .after('') - .attr('disabled','disabled'); - - $.post(action, { - name: $('#name').val(), - email: $('#email').val(), - subject: $('#subject').val(), - comments: $('#comments').val(), - verify: $('#verify').val() - }, - function(data){ - document.getElementById('message').innerHTML = data; - $('#message').slideDown('slow'); - $('#contactform img.loader').fadeOut('slow',function(){$(this).remove()}); - $('#contactform #submit').attr('disabled',''); - if(data.match('success') != null) $('#contactform').slideUp('slow'); - - } - ); - - }); - - return false; - - }); - +jQuery(document).ready(function(){ + + $('#contactform').submit(function(){ + + var action = $(this).attr('action'); + + $("#message").slideUp(750,function() { + $('#message').hide(); + + $('#submit') + .after('') + .attr('disabled','disabled'); + + $.post(action, { + name: $('#name').val(), + email: $('#email').val(), + subject: $('#subject').val(), + comments: $('#comments').val(), + verify: $('#verify').val() + }, + function(data){ + document.getElementById('message').innerHTML = data; + $('#message').slideDown('slow'); + $('#contactform img.loader').fadeOut('slow',function(){$(this).remove()}); + $('#contactform #submit').attr('disabled',''); + if(data.match('success') != null) $('#contactform').slideUp('slow'); + + } + ); + + }); + + return false; + + }); + }); \ No newline at end of file diff --git a/webroot/js/jquery.lightbox-0.5.min.js b/webroot/js/jquery.lightbox-0.5.min.js index 5f13b0b..429f0c5 100644 --- a/webroot/js/jquery.lightbox-0.5.min.js +++ b/webroot/js/jquery.lightbox-0.5.min.js @@ -1,42 +1,42 @@ -/** - * jQuery lightBox plugin - * This jQuery plugin was inspired and based on Lightbox 2 by Lokesh Dhakar (http://www.huddletogether.com/projects/lightbox2/) - * and adapted to me for use like a plugin from jQuery. - * @name jquery-lightbox-0.5.js - * @author Leandro Vieira Pinho - http://leandrovieira.com - * @version 0.5 - * @date April 11, 2008 - * @category jQuery plugin - * @copyright (c) 2008 Leandro Vieira Pinho (leandrovieira.com) - * @license CCAttribution-ShareAlike 2.5 Brazil - http://creativecommons.org/licenses/by-sa/2.5/br/deed.en_US - * @example Visit http://leandrovieira.com/projects/jquery/lightbox/ for more informations about this jQuery plugin - */ -(function($){$.fn.lightBox=function(settings){settings=jQuery.extend({overlayBgColor:'#000',overlayOpacity:0.8,fixedNavigation:false,imageLoading:'images/lightbox-ico-loading.gif',imageBtnPrev:'images/lightbox-btn-prev.gif',imageBtnNext:'images/lightbox-btn-next.gif',imageBtnClose:'images/lightbox-btn-close.gif',imageBlank:'images/lightbox-blank.gif',containerBorderSize:10,containerResizeSpeed:400,txtImage:'Image',txtOf:'of',keyToClose:'c',keyToPrev:'p',keyToNext:'n',imageArray:[],activeImage:0},settings);var jQueryMatchedObj=this;function _initialize(){_start(this,jQueryMatchedObj);return false;} -function _start(objClicked,jQueryMatchedObj){$('embed, object, select').css({'visibility':'hidden'});_set_interface();settings.imageArray.length=0;settings.activeImage=0;if(jQueryMatchedObj.length==1){settings.imageArray.push(new Array(objClicked.getAttribute('href'),objClicked.getAttribute('title')));}else{for(var i=0;i
');var arrPageSizes=___getPageSize();$('#jquery-overlay').css({backgroundColor:settings.overlayBgColor,opacity:settings.overlayOpacity,width:arrPageSizes[0],height:arrPageSizes[1]}).fadeIn();var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]}).show();$('#jquery-overlay,#jquery-lightbox').click(function(){_finish();});$('#lightbox-loading-link,#lightbox-secNav-btnClose').click(function(){_finish();return false;});$(window).resize(function(){var arrPageSizes=___getPageSize();$('#jquery-overlay').css({width:arrPageSizes[0],height:arrPageSizes[1]});var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]});});} -function _set_image_to_view(){$('#lightbox-loading').show();if(settings.fixedNavigation){$('#lightbox-image,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();}else{$('#lightbox-image,#lightbox-nav,#lightbox-nav-btnPrev,#lightbox-nav-btnNext,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();} -var objImagePreloader=new Image();objImagePreloader.onload=function(){$('#lightbox-image').attr('src',settings.imageArray[settings.activeImage][0]);_resize_container_image_box(objImagePreloader.width,objImagePreloader.height);objImagePreloader.onload=function(){};};objImagePreloader.src=settings.imageArray[settings.activeImage][0];};function _resize_container_image_box(intImageWidth,intImageHeight){var intCurrentWidth=$('#lightbox-container-image-box').width();var intCurrentHeight=$('#lightbox-container-image-box').height();var intWidth=(intImageWidth+(settings.containerBorderSize*2));var intHeight=(intImageHeight+(settings.containerBorderSize*2));var intDiffW=intCurrentWidth-intWidth;var intDiffH=intCurrentHeight-intHeight;$('#lightbox-container-image-box').animate({width:intWidth,height:intHeight},settings.containerResizeSpeed,function(){_show_image();});if((intDiffW==0)&&(intDiffH==0)){if($.browser.msie){___pause(250);}else{___pause(100);}} -$('#lightbox-container-image-data-box').css({width:intImageWidth});$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({height:intImageHeight+(settings.containerBorderSize*2)});};function _show_image(){$('#lightbox-loading').hide();$('#lightbox-image').fadeIn(function(){_show_image_data();_set_navigation();});_preload_neighbor_images();};function _show_image_data(){$('#lightbox-container-image-data-box').slideDown('fast');$('#lightbox-image-details-caption').hide();if(settings.imageArray[settings.activeImage][1]){$('#lightbox-image-details-caption').html(settings.imageArray[settings.activeImage][1]).show();} -if(settings.imageArray.length>1){$('#lightbox-image-details-currentNumber').html(settings.txtImage+' '+(settings.activeImage+1)+' '+settings.txtOf+' '+settings.imageArray.length).show();}} -function _set_navigation(){$('#lightbox-nav').show();$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({'background':'transparent url('+settings.imageBlank+') no-repeat'});if(settings.activeImage!=0){if(settings.fixedNavigation){$('#lightbox-nav-btnPrev').css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnPrev').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}} -if(settings.activeImage!=(settings.imageArray.length-1)){if(settings.fixedNavigation){$('#lightbox-nav-btnNext').css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnNext').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}} -_enable_keyboard_navigation();} -function _enable_keyboard_navigation(){$(document).keydown(function(objEvent){_keyboard_action(objEvent);});} -function _disable_keyboard_navigation(){$(document).unbind();} -function _keyboard_action(objEvent){if(objEvent==null){keycode=event.keyCode;escapeKey=27;}else{keycode=objEvent.keyCode;escapeKey=objEvent.DOM_VK_ESCAPE;} -key=String.fromCharCode(keycode).toLowerCase();if((key==settings.keyToClose)||(key=='x')||(keycode==escapeKey)){_finish();} -if((key==settings.keyToPrev)||(keycode==37)){if(settings.activeImage!=0){settings.activeImage=settings.activeImage-1;_set_image_to_view();_disable_keyboard_navigation();}} -if((key==settings.keyToNext)||(keycode==39)){if(settings.activeImage!=(settings.imageArray.length-1)){settings.activeImage=settings.activeImage+1;_set_image_to_view();_disable_keyboard_navigation();}}} -function _preload_neighbor_images(){if((settings.imageArray.length-1)>settings.activeImage){objNext=new Image();objNext.src=settings.imageArray[settings.activeImage+1][0];} -if(settings.activeImage>0){objPrev=new Image();objPrev.src=settings.imageArray[settings.activeImage-1][0];}} -function _finish(){$('#jquery-lightbox').remove();$('#jquery-overlay').fadeOut(function(){$('#jquery-overlay').remove();});$('embed, object, select').css({'visibility':'visible'});} -function ___getPageSize(){var xScroll,yScroll;if(window.innerHeight&&window.scrollMaxY){xScroll=window.innerWidth+window.scrollMaxX;yScroll=window.innerHeight+window.scrollMaxY;}else if(document.body.scrollHeight>document.body.offsetHeight){xScroll=document.body.scrollWidth;yScroll=document.body.scrollHeight;}else{xScroll=document.body.offsetWidth;yScroll=document.body.offsetHeight;} -var windowWidth,windowHeight;if(self.innerHeight){if(document.documentElement.clientWidth){windowWidth=document.documentElement.clientWidth;}else{windowWidth=self.innerWidth;} -windowHeight=self.innerHeight;}else if(document.documentElement&&document.documentElement.clientHeight){windowWidth=document.documentElement.clientWidth;windowHeight=document.documentElement.clientHeight;}else if(document.body){windowWidth=document.body.clientWidth;windowHeight=document.body.clientHeight;} -if(yScroll
');var arrPageSizes=___getPageSize();$('#jquery-overlay').css({backgroundColor:settings.overlayBgColor,opacity:settings.overlayOpacity,width:arrPageSizes[0],height:arrPageSizes[1]}).fadeIn();var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]}).show();$('#jquery-overlay,#jquery-lightbox').click(function(){_finish();});$('#lightbox-loading-link,#lightbox-secNav-btnClose').click(function(){_finish();return false;});$(window).resize(function(){var arrPageSizes=___getPageSize();$('#jquery-overlay').css({width:arrPageSizes[0],height:arrPageSizes[1]});var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]});});} +function _set_image_to_view(){$('#lightbox-loading').show();if(settings.fixedNavigation){$('#lightbox-image,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();}else{$('#lightbox-image,#lightbox-nav,#lightbox-nav-btnPrev,#lightbox-nav-btnNext,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();} +var objImagePreloader=new Image();objImagePreloader.onload=function(){$('#lightbox-image').attr('src',settings.imageArray[settings.activeImage][0]);_resize_container_image_box(objImagePreloader.width,objImagePreloader.height);objImagePreloader.onload=function(){};};objImagePreloader.src=settings.imageArray[settings.activeImage][0];};function _resize_container_image_box(intImageWidth,intImageHeight){var intCurrentWidth=$('#lightbox-container-image-box').width();var intCurrentHeight=$('#lightbox-container-image-box').height();var intWidth=(intImageWidth+(settings.containerBorderSize*2));var intHeight=(intImageHeight+(settings.containerBorderSize*2));var intDiffW=intCurrentWidth-intWidth;var intDiffH=intCurrentHeight-intHeight;$('#lightbox-container-image-box').animate({width:intWidth,height:intHeight},settings.containerResizeSpeed,function(){_show_image();});if((intDiffW==0)&&(intDiffH==0)){if($.browser.msie){___pause(250);}else{___pause(100);}} +$('#lightbox-container-image-data-box').css({width:intImageWidth});$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({height:intImageHeight+(settings.containerBorderSize*2)});};function _show_image(){$('#lightbox-loading').hide();$('#lightbox-image').fadeIn(function(){_show_image_data();_set_navigation();});_preload_neighbor_images();};function _show_image_data(){$('#lightbox-container-image-data-box').slideDown('fast');$('#lightbox-image-details-caption').hide();if(settings.imageArray[settings.activeImage][1]){$('#lightbox-image-details-caption').html(settings.imageArray[settings.activeImage][1]).show();} +if(settings.imageArray.length>1){$('#lightbox-image-details-currentNumber').html(settings.txtImage+' '+(settings.activeImage+1)+' '+settings.txtOf+' '+settings.imageArray.length).show();}} +function _set_navigation(){$('#lightbox-nav').show();$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({'background':'transparent url('+settings.imageBlank+') no-repeat'});if(settings.activeImage!=0){if(settings.fixedNavigation){$('#lightbox-nav-btnPrev').css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnPrev').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}} +if(settings.activeImage!=(settings.imageArray.length-1)){if(settings.fixedNavigation){$('#lightbox-nav-btnNext').css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnNext').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}} +_enable_keyboard_navigation();} +function _enable_keyboard_navigation(){$(document).keydown(function(objEvent){_keyboard_action(objEvent);});} +function _disable_keyboard_navigation(){$(document).unbind();} +function _keyboard_action(objEvent){if(objEvent==null){keycode=event.keyCode;escapeKey=27;}else{keycode=objEvent.keyCode;escapeKey=objEvent.DOM_VK_ESCAPE;} +key=String.fromCharCode(keycode).toLowerCase();if((key==settings.keyToClose)||(key=='x')||(keycode==escapeKey)){_finish();} +if((key==settings.keyToPrev)||(keycode==37)){if(settings.activeImage!=0){settings.activeImage=settings.activeImage-1;_set_image_to_view();_disable_keyboard_navigation();}} +if((key==settings.keyToNext)||(keycode==39)){if(settings.activeImage!=(settings.imageArray.length-1)){settings.activeImage=settings.activeImage+1;_set_image_to_view();_disable_keyboard_navigation();}}} +function _preload_neighbor_images(){if((settings.imageArray.length-1)>settings.activeImage){objNext=new Image();objNext.src=settings.imageArray[settings.activeImage+1][0];} +if(settings.activeImage>0){objPrev=new Image();objPrev.src=settings.imageArray[settings.activeImage-1][0];}} +function _finish(){$('#jquery-lightbox').remove();$('#jquery-overlay').fadeOut(function(){$('#jquery-overlay').remove();});$('embed, object, select').css({'visibility':'visible'});} +function ___getPageSize(){var xScroll,yScroll;if(window.innerHeight&&window.scrollMaxY){xScroll=window.innerWidth+window.scrollMaxX;yScroll=window.innerHeight+window.scrollMaxY;}else if(document.body.scrollHeight>document.body.offsetHeight){xScroll=document.body.scrollWidth;yScroll=document.body.scrollHeight;}else{xScroll=document.body.offsetWidth;yScroll=document.body.offsetHeight;} +var windowWidth,windowHeight;if(self.innerHeight){if(document.documentElement.clientWidth){windowWidth=document.documentElement.clientWidth;}else{windowWidth=self.innerWidth;} +windowHeight=self.innerHeight;}else if(document.documentElement&&document.documentElement.clientHeight){windowWidth=document.documentElement.clientWidth;windowHeight=document.documentElement.clientHeight;}else if(document.body){windowWidth=document.body.clientWidth;windowHeight=document.body.clientHeight;} +if(yScroll