From fb15deeef32d80ef922a578d742ff49633d5f94e Mon Sep 17 00:00:00 2001 From: Andreas Unterkircher Date: Thu, 7 Jun 2007 08:48:43 +0000 Subject: nice bubble preview in photo index view git-svn-id: file:///var/lib/svn/phpfspot/trunk@33 fa6a889d-dae6-447d-9e79-4ba9a3039384 --- bubble.js | 261 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 261 insertions(+) create mode 100644 bubble.js (limited to 'bubble.js') diff --git a/bubble.js b/bubble.js new file mode 100644 index 0000000..39ae03e --- /dev/null +++ b/bubble.js @@ -0,0 +1,261 @@ +/* + WebSnapr - Preview Bubble Javascript + Written by Juan Xavier Larrea + http://www.websnapr.com - xavier@websnapr.com + +*/ + +// Point this variable to the correct location of the bg.png file +var bubbleImagePath = 'resources/bubble_bg.png'; + +if(typeof Array.prototype.push!="function"){ + Array.prototype.push=ArrayPush; + + function ArrayPush(_1){ + this[this.length]=_1; + } +} + +function WSR_getElementsByClassName(_2,_3,_4){ + + var _5=(_3=="*"&&_2.all)?_2.all:_2.getElementsByTagName(_3); + var _6=new Array(); + _4=_4.replace(/\-/g,"\\-"); + var _7=new RegExp("(^|\\s)"+_4+"(\\s|$)"); + var _8; + for(var i=0;i<_5.length;i++){ + _8=_5[i]; + if(_7.test(_8.className)){ + _6.push(_8); + } + } + return (_6); +} + +function bindBubbles(e){ + lbActions=WSR_getElementsByClassName(document,"a","bubble"); + for(i=0;i