Track Mouse Coordinates Outside Window

A

atn2002

How can I track the mouse coordinates outside the active window? No
one can tell me its not possible because Google Spreadsheets and
EditGrid both do it. When you drag down to select cells these
spreadsheet programs are capable of properly selecting the cells based
on where the mouse is, even though the mouse is way outside the
browser. I haven't been able to find any info on it or figure it out
myself. How is this possible?
 
E

Elegie

(e-mail address removed) wrote:

Hi,
How can I track the mouse coordinates outside the active window? No
one can tell me its not possible because Google Spreadsheets and
EditGrid both do it.

Sure I can :)

That is not possible, sorry. The MOUSEMOVE listener has to be registered
on some DOM element, and it won't follow the mouse moves that happens
outside of this element.

I have just tried Google Spreadsheets, using Firefox 1.5. I have reduced
the window so that it occupies 1/4 of my desktop, have started some
selection in the sheet and then have moused outside of the window. The
program does not follow the mouse moves, it simply continues moving the
selection towards the direction I had set when I left the window (in the
meanwhile I've been clicking and writing to another window, some MS Word
document, and the selection kept expanding).

Could you explain why you need this feature? People around here have
been solving lots of design issues, and yours may already have received
some nice solution!


Kind regards,
Elegie.

PS : If you're working in some secure and known environment, you could
probably design some external component that would capture the mouse
position, and use it directly from your script. The technology used
would depend on the targeted platform and browser.
 
A

atn2002

Didn't mean to be rude :)

Actually you're right, it doesn't work in Firefox but it does work in
Internet Explorer, so IE must have a proprietary thing going on. I
should have mentioned that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,733
Messages
2,569,440
Members
44,832
Latest member
GlennSmall

Latest Threads

Top