Patches item #1491547, was opened at 2006-05-19 15:11 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=684977&aid=1491547&group_id=119783
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: core Group: 1.2 Status: Open Resolution: None Priority: 5 Submitted By: Karri-Pekka Laakso (kplaakso) Assigned to: Nobody/Anonymous (nobody) Summary: Autocomplete menu position is miscalculated Initial Comment: The current wicket-autocomplete.js relies on the fact that setting the CSS attribute "position: absolute" really positions the autocomplete menu in relation to the document or the body element. However, this is *not* how CSS positioning works. Absolute position is calculated relative to the nearest parent element of the current element that is positioned either absolutely or relatively. This means that for an absolutely positioned element, the coordinates set by object.style.left and object.style.top are not always in relation to the document top left cornert. In wicket-autocomplete.js the menu coordinates are calculated using offsets, which results in coordinates relative to the document body. However, if the autocomplete menu (the container div) is not a direct child of the body element and one its parents is either absolutely or relatively positioned, the menu is displaced by the difference of its relative coordinate system origo and the document origo. This is actually a very useful feature in CSS, since its possible to create new coordinate systems. In this case, however, it causes a minor challenge. My fix proposal is to generate the container div in JavaScript as a direct descendant of the body element. This is a de-facto standard JavaScript popup component trick that has been used in popup calendars, for example. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=684977&aid=1491547&group_id=119783 ------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Wicket-develop mailing list Wicket-develop@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-develop