[Laszlo-checkins] r10849 - openlaszlo/trunk/lps/includes/source
max@openlaszlo.org
max at openlaszlo.org
Tue Sep 2 12:24:52 PDT 2008
Author: max
Date: 2008-09-02 12:24:46 -0700 (Tue, 02 Sep 2008)
New Revision: 10849
Modified:
openlaszlo/trunk/lps/includes/source/embednew.js
Log:
Change 20080902-maxcarlson-v by maxcarlson at Bank on 2008-09-02 11:32:41 PDT
in /Users/maxcarlson/openlaszlo/trunk-clean
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix braino in lz.embed.getAbsolutePosition()
Bugs Fixed: LPP-6917 - dhtml: lzpix photo dragging broken in Safari as of r10798
Technical Reviewer: hminsky
QA Reviewer: promanik
Details: Fix braino - can't rely on this.quirks to exist! Changed to return result immediately when a position is final.
Tests: See LPP-6917
Modified: openlaszlo/trunk/lps/includes/source/embednew.js
===================================================================
--- openlaszlo/trunk/lps/includes/source/embednew.js 2008-09-02 18:46:50 UTC (rev 10848)
+++ openlaszlo/trunk/lps/includes/source/embednew.js 2008-09-02 19:24:46 UTC (rev 10849)
@@ -677,7 +677,8 @@
}
// opera & (safari absolute) incorrectly account for body offsetTop
- if ( this.quirks.absolute_position_accounts_for_offset && this.hasOwnProperty('getStyle') && this.getStyle(el, 'position') == 'absolute' ) {
+ // used quirks.absolute_position_accounts_for_offset before...
+ if ( (lz.embed.browser.isSafari || lz.embed.browser.isOpera) && this.hasOwnProperty('getStyle') && this.getStyle(el, 'position') == 'absolute' ) {
pos.y -= document.body.offsetTop;
}
}
@@ -685,7 +686,7 @@
if (el.parentNode) {
parent = el.parentNode;
} else {
- parent = null;
+ return pos;
}
while (parent && parent.tagName != 'BODY' && parent.tagName != 'HTML') {
@@ -695,7 +696,7 @@
if (parent.parentNode) {
parent = parent.parentNode;
} else {
- parent = null;
+ return pos;
}
}
return pos;
More information about the Laszlo-checkins
mailing list