BUGFIX:
authorRobert Lemke <robert.lemke@typo3.org>
Fri, 17 Oct 2003 12:47:50 +0000 (12:47 +0000)
committerRobert Lemke <robert.lemke@typo3.org>
Fri, 17 Oct 2003 12:47:50 +0000 (12:47 +0000)
Clickmenu did not appear or did appear on the wrong position in the filelist module using Mozilla. (I only tested that bug with Mozilla / Linux).

REASON:
In the JavaScript function setLayerObj I discovered that when the menu does not appear, the tempLayerObjCss.top and tempLayerObjCss.left properties contained nothing. It turned out that explicitly setting their values to "10px" instead of "10" made the menu appear correctly.

SOLUTION:
I haven't found yet another place in the core which might be affected by this bug, so I only changed the lines in the JavaScript function. Maybe someoneelse knows about other places we have to look at?

git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@29 709f56b5-9817-0410-a4d7-c38de5d9e867

typo3/template.php

index 923b6f2..83282b1 100755 (executable)
@@ -1187,9 +1187,9 @@ trim($this->form);
                                }
                                        // outsideLayer(level)
                                function outsideLayer(level)    {
-                                       return GLV_x+GLV_gap-GLV_curLayerX[level] <0 || 
-                                                       GLV_y+GLV_gap-GLV_curLayerY[level] <0 || 
-                                                       GLV_curLayerX[level]+GLV_curLayerWidth[level]+GLV_gap-GLV_x <0 || 
+                                       return GLV_x+GLV_gap-GLV_curLayerX[level] <0 ||
+                                                       GLV_y+GLV_gap-GLV_curLayerY[level] <0 ||
+                                                       GLV_curLayerX[level]+GLV_curLayerWidth[level]+GLV_gap-GLV_x <0 ||
                                                        GLV_curLayerY[level]+GLV_curLayerHeight[level]+GLV_gap-GLV_y <0;
                                }
                                        // setLayerObj(html,level)
@@ -1202,8 +1202,10 @@ trim($this->form);
                                                tempLayerObj.height= (bw.ie4||bw.ie5||bw.ns6||bw.konq||bw.op7)?this.el.offsetHeight:bw.ns4?this.ref.height:bw.op?this.css.pixelHeight:0;
                                                tempLayerObj.width= (bw.ie4||bw.ie5||bw.ns6||bw.konq||bw.op7)?this.el.offsetWidth:bw.ns4?this.ref.width:bw.op?this.css.pixelWidth:0;
 
-                                               tempLayerObjCss.left = GLV_curLayerX[level] = GLV_x;
-                                               tempLayerObjCss.top = GLV_curLayerY[level] = GLV_y;
+                                               GLV_curLayerX[level] = GLV_x;
+                                               GLV_curLayerY[level] = GLV_y;
+                                               tempLayerObjCss.left = GLV_x+"px";
+                                               tempLayerObjCss.top = GLV_y+"px";
                                                tempLayerObjCss.visibility = "visible";
 
                                                GLV_isVisible[level]=1;