summaryrefslogtreecommitdiffstats
path: root/bubble.js
diff options
context:
space:
mode:
Diffstat (limited to 'bubble.js')
-rw-r--r--bubble.js33
1 files changed, 18 insertions, 15 deletions
diff --git a/bubble.js b/bubble.js
index 600407b..1d715b1 100644
--- a/bubble.js
+++ b/bubble.js
@@ -39,9 +39,11 @@ function bindBubbles(e){
if(window.addEventListener){
lbActions[i].addEventListener("mouseover",attachBubble,false);
lbActions[i].addEventListener("mouseout",detachBubble,false);
+ lbActions[i].addEventListener("click",detachBubble,false);
}else{
lbActions[i].attachEvent("onmouseover",attachBubble);
lbActions[i].attachEvent("onmouseout",detachBubble);
+ lbActions[i].attachEvent("onclick",detachBubble);
}
}
}
@@ -67,26 +69,26 @@ function attachBubble(_b){
// should the bubble be displayed above or below the object
if(cur_height >= get_page_height()) {
- var _f=findPos(_c)[1]-283;
- var _mT=16;
- var _mL=12;
+ var _f=findPos(_c)[1]-363;
+ var _mL=2;
+ var _mT=39;
bubbleImage = bubbleImageUp;
}
else {
var _f=findPos(_c)[1]+17;
- var _mT=27;
- var _mL=12;
+ var _mL=2;
+ var _mT=34;
bubbleImage = bubbleImageDown;
}
if (BrowserDetect.browser == 'Explorer') {
- _10.style.width="240px";
+ _10.style.width="275px";
_10.style.position="absolute";
_10.style.top=_f;
_10.style.zIndex=99999;
_10.style.left=_e;
_10.style.textAlign="left";
- _10.style.height="190px";
+ _10.style.height="275px";
_10.style.paddingTop="0";
_10.style.paddingLeft="0";
_10.style.paddingBottom="0";
@@ -97,17 +99,24 @@ function attachBubble(_b){
_10.style.marginRight="0";
_10.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + bubbleImage + "',sizingMethod='image')";
} else {
- _10.setAttribute("style","text-align: center; z-index: 99999; position: absolute; top: "+_f+"px ; left: "+_e+"px ; background: url("+ bubbleImage +") no-repeat; width: 240px; height: 190px; padding: 0; margin: 0;");
+ _10.setAttribute("style","text-align: center; z-index: 99999; position: absolute; top: "+_f+"px ; left: "+_e+"px ; background: url("+ bubbleImage +") no-repeat; width: 275px; height: 275px; padding: 0; margin: 0;");
}
if (BrowserDetect.browser == 'Safari' || BrowserDetect.browser == 'Konqueror' ) {
var _height = _f;
- _10.setAttribute("style","text-align: center; z-index: 99999; position: absolute; top: "+ _height +"px ; left: "+_e+"px ; background: url("+ bubbleImage +") no-repeat; width: 240px; height: 190px; padding: 0; margin: 0;");
+ _10.setAttribute("style","text-align: center; z-index: 99999; position: absolute; top: "+ _height +"px ; left: "+_e+"px ; background: url("+ bubbleImage +") no-repeat; width: 275px; height: 275px; padding: 0; margin: 0;");
}
+ if(cur_height >= get_page_height())
+ showBubbleDetails(_10, _c.id, 'up');
+ else
+ showBubbleDetails(_10, _c.id, 'down');
+
+ return;
+
var img=document.createElement("img");
_10.appendChild(img);
@@ -141,12 +150,6 @@ function detachBubble(_12){
}
}
-/*if(window.addEventListener){
- addEventListener("load",bindBubbles,false);
-}else{
- attachEvent("onload",bindBubbles);
-}*/
-
function findPos(obj){
var _14=curtop=0;
if(obj.offsetParent){