svn commit: r948698 - in /ofbiz/branches/release10.04: ./ framework/images/webapp/images/fieldlookup.js

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r948698 - in /ofbiz/branches/release10.04: ./ framework/images/webapp/images/fieldlookup.js

jleroux@apache.org
Author: jleroux
Date: Thu May 27 07:20:42 2010
New Revision: 948698

URL: http://svn.apache.org/viewvc?rev=948698&view=rev
Log:
"Applied fix from trunk for revision: 948694"
------------------------------------------------------------------------
r948694 | jleroux | 2010-05-27 09:07:05 +0200 (jeu. 27 mai 2010) | 3 lignes

A patch from Sascha Rodekamp "The position attribute (at least center) does not work when used in a lookup called from another lookup " (https://issues.apache.org/jira/browse/OFBIZ-3781) - OFBIZ-3781

Here is a little patch to fix the center issue. I had to remove some code which is not needed anymore.
------------------------------------------------------------------------


Modified:
    ofbiz/branches/release10.04/   (props changed)
    ofbiz/branches/release10.04/framework/images/webapp/images/fieldlookup.js

Propchange: ofbiz/branches/release10.04/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu May 27 07:20:42 2010
@@ -1,3 +1,3 @@
 /ofbiz/branches/addbirt:831210-885099,885686-886087
 /ofbiz/branches/multitenant20100310:921280-927264
-/ofbiz/trunk:939988,939990,939999,940025,940053,940234,940248,940309,940401,940410,940425,940779,940815,940849,941007,941047,941109,941177,941199,941261,941440,941600,941999,942084,942406,942414,942671,942883-942884,943168,943271-943272,944614,944621,944623,944647,944669,944797,944895,945010,945018,945026,945118,945573,945578,945580,945582,945610,945619,945848,945852,945857,946061,946066,946073,946075,946080,946309,946313,946320,946322,946596,947004-947005,947392,947424,947679,947988,948017
+/ofbiz/trunk:939988,939990,939999,940025,940053,940234,940248,940309,940401,940410,940425,940779,940815,940849,941007,941047,941109,941177,941199,941261,941440,941600,941999,942084,942406,942414,942671,942883-942884,943168,943271-943272,944614,944621,944623,944647,944669,944797,944895,945010,945018,945026,945118,945573,945578,945580,945582,945610,945619,945848,945852,945857,946061,946066,946073,946075,946080,946309,946313,946320,946322,946596,947004-947005,947392,947424,947679,947988,948017,948694

Modified: ofbiz/branches/release10.04/framework/images/webapp/images/fieldlookup.js
URL: http://svn.apache.org/viewvc/ofbiz/branches/release10.04/framework/images/webapp/images/fieldlookup.js?rev=948698&r1=948697&r2=948698&view=diff
==============================================================================
--- ofbiz/branches/release10.04/framework/images/webapp/images/fieldlookup.js (original)
+++ ofbiz/branches/release10.04/framework/images/webapp/images/fieldlookup.js Thu May 27 07:20:42 2010
@@ -370,20 +370,12 @@ var FieldLookupPopup = Class.create({
         //set layer position
         var bdy = document.body;
         if (this.position == "center") {
-            if (ACTIVATED_LOOKUP != null) {
-                obj = GLOBAL_LOOKUP_REF.getReference(ACTIVATED_LOOKUP);
-                obj.divRef.appendChild(lookupDiv);
-                lookupLeft = 0;
-                lookupTop = 0;
-            }
-            else {        
-                bdy.appendChild(lookupDiv);
-                var dimensions = lookupDiv.getDimensions();
-                lookupLeft = (bdy.offsetWidth / 2) - (dimensions.width / 2);
-                var scrollOffY = document.viewport.getScrollOffsets().top;
-                var winHeight = document.viewport.getHeight();
-                lookupTop = (scrollOffY + winHeight / 2) - (dimensions.height / 2);
-            }
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = (bdy.offsetWidth / 2) - (dimensions.width / 2);
+            var scrollOffY = document.viewport.getScrollOffsets().top;
+            var winHeight = document.viewport.getHeight();
+            lookupTop = (scrollOffY + winHeight / 2) - (dimensions.height / 2);
             
             lookupDiv.style.left = lookupLeft + "px";
             lookupDiv.style.top = lookupTop + "px";