简体   繁体   English

通过Firebug控制台时的鼠标事件

[英]Mouse events when over firebug console

I'm trying to implement a panning (drag&drop) functionality on my site google maps. 我正在尝试在我的网站google地图上实现平移(拖放)功能。 For that I use the standard mouse-events (mousedown, mousemove, mouseup). 为此,我使用了标准的鼠标事件(mousedown,mousemove,mouseup)。

It works while moving the mouse inside the browser, even with leaving the browser while still panning, as the browser recognizes the mouse-events even outside the browser. 它可以在浏览器内部移动鼠标时工作,即使浏览器仍在平移时也不会移动,因为浏览器甚至可以在浏览器外部识别鼠标事件。 But it does not work when moving the mouse over the Firebug console. 但是将鼠标移到Firebug控制台上时不起作用。

Google maps also stops the panning when the mouse moves over the Firebug console, but how does it know when the mouse is there? 当鼠标移到Firebug控制台上时,Google地图也会停止平移,但是如何知道鼠标何时在那儿呢? It needs to know it, because event if I do not release the mouse button and move back to the map, the panning is not active anymore. 它需要知道它,因为如果我不释放鼠标按钮并移回地图,则平移不再有效。 So how does the google-map know when the mouse went to the console? 那么,谷歌地图如何知道鼠标何时进入控制台?

It's not Google Maps that knows about the mouse cursor being over the Firebug window. 不是Google Maps知道鼠标光标在Firebug窗口上方。

Instead I suspect it's Firebug catching and cancelling the mousemove and mouseover event. 相反,我怀疑是Firebug捕获并取消了mousemovemouseover事件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM