Thank you very much, that solved the problem.

As a note, I tweaked the solution slightly and it is a bit simpler and works just fine:

// Calculate pageX/Y if missing and clientX/Y available
if ( event.pageX == null && event.clientX != null ) {
var e = document.documentElement, b = document.body;
event.pageX = event.clientX + (e && e.scrollLeft || b && b.scrollLeft || 0);
event.pageY = event.clientY + (e && e.scrollTop || b && b.scrollTop || 0);
}

JK
----- Original Message ----- From: "John Resig" <[EMAIL PROTECTED]>
To: <jquery-en@googlegroups.com>
Sent: Monday, July 16, 2007 4:47 PM
Subject: [jQuery] Re: Problem with jQuery.fix in event model



This one seems to have a working patch:
http://dev.jquery.com/ticket/1402

--John

On 7/16/07, Jeffrey Kretz <[EMAIL PROTECTED]> wrote:

Thanks very much, this is great to know.

In case 1.1.4 is delayed, is there a workaround or a patch I can use on a
temporary basis?

JK
----- Original Message -----
From: "John Resig" <[EMAIL PROTECTED]>
To: <jquery-en@googlegroups.com>
Sent: Monday, July 16, 2007 2:45 PM
Subject: [jQuery] Re: Problem with jQuery.fix in event model


>
> This is a bug in jQuery that will be fixed in 1.1.4 (which should be
> coming out soon). There's a ticket open on it now, and we're working
> to resolve it.
>
> --John
>
> On 7/16/07, Jeffrey Kretz <[EMAIL PROTECTED]> wrote:
>>
>> I am trying an integration of Ext and jQuery for a new project.
>>
>> In doing a simple demo page, I've run into a problem whereby the
>> jQuery.fix
>> method for events is firing on a mousemove before the DOM is loaded.
>>
>> Sample page at:
>>
>> http://dev.scorpiondesign.com/Clients/Test.htm
>>
>> Tested in IE7 (not sure if the problem exists in other browsers).
>>
>> To reproduce error:
>>
>> Once the page is loaded, refresh the page ensuring the mouse doesn't >> move
>> at
>> all.  Page loads fine, button script executes.
>>
>> Next, start a page refresh and move the mouse while the page is being
>> loaded.
>> An error occurs on line 1445 jquery.js, where document.body is null, >> as
>> the
>> mousemove event is firing before DOM is loaded.
>>
>> Is this is a flaw in Ext or jQuery? What would be the best approach >> to
>> handle it?
>>
>> JK
>>
>>
>




Reply via email to