Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to distinguish mice in JavaScript?

I am wanting to hook up several mice - each one used for different types of input. Is there a way in JavaScript to distinguish between each mouse?

I know that JS may not seem like the right language for this, but I want to use one mouse for web navigation, and the other for Google-earth navigation. Because the Google-API is already using JS, I figured I try to keep all the code together.

like image 246
ChronoFish Avatar asked Nov 27 '25 01:11

ChronoFish


1 Answers

This is not possible with JavaScript. The JS would have to have low-level access to the clients machine to make this type of distinction. Obviously, this would be a huge security risk.

like image 89
James Hill Avatar answered Nov 28 '25 16:11

James Hill



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!