moveToMousePosition jQuery Plugin

This plug-in moves a specified element to the current mouse position based on an event object passed in. Note that an event like click or mouse move on the element is required in order to get the current mouse position and the event object is passed as a parameter

This plug-in is useful for creating hover windows and it's used internally with the wwHoverPanel class to position the window at the mouse cursor.

jQuery.fn.moveToMousePosition = function(evt,options)

evt
A jQuery event object. This is required because it's the only way to retrieve the mouse position.

Options
The options parameter allows specify a left and right offset from the current mouse position:

var opt = { left: 0; top: 0 };

Class Members

See also:

Class modalDialog

© West Wind Technologies, 1996-2024 • Updated: 12/19/15
Comment or report problem with topic