samanime — 2011-03-03T12:28:42-05:00 — #1
I have problem that should be stupidly simple... but I seem to be a extra stupid. =p
Basically I'm implementing the Google Maps API (v3). I've set up an event so when it's right-clicked, a context menu pops up.
Now, the problem: I want to get the x/y of the mouse (so I can center the context menu). However, Google seems to have stripped this out of the MouseEvent which they send (no pageX/pageY).
So, how can I get the mouse position? (Not the LatLng, that's easy. =p)
monurohila — 2011-03-03T12:34:06-05:00 — #2
basically Google provides us the facility to create a Google map mouse position means we can target a specific location for our business on google map.
samanime — 2011-03-03T12:49:57-05:00 — #3
Ah, answered my own question. It seems there is a pixel object, which is a point that has an x and y property which has the mouse X and Y. Doesn't look to be documented anywhere, but it's there.