Holds the current horizontal offset.
Holds the current vertical offset.
Holds the event names and associated listeners in an array. The array contains the event name followed by the respective listener for each registered listener.
Specifies if events can be fired. Default is true.
Optional source for events. Default is null.
Reference to the enclosing Graph.
Specifies if panning should be active even if there is a cell under the mousepointer. Default is false.
Specifies the maximum scale. Default is 8.
Specifies the minimum scale. Default is 0.01.
Specifies if panning should be enabled. Default is false.
Specifies if pinch gestures should be handled as zoom. Default is true.
Specifies if the panning should be previewed. Default is true.
Holds the x-coordinate of the start point.
Holds the y-coordinate of the start point.
Specifies if the panning steps should be aligned to the grid size. Default is false.
Specifies if panning should be active for the left mouse button. Setting this to true may conflict with Rubberband. Default is false.
Specifies if Event#isPopupTrigger should also be used for panning.
Static
pluginBinds the specified function to the given event name. If no event name is given, then the listener is registered for all events.
The parameters of the listener are the sender and an EventObject.
Consumes the given MouseEvent if it was a panning trigger in ouseDown. The default is to invoke MouseEvent#consume. Note that this will block any further event processing. If you haven't disabled built-in context menus and require immediate selection of the cell on mouseDown in Safari and/or on the Mac, then use the following code:
consumePanningTrigger(me)
{
if (me.evt.preventDefault)
{
me.evt.preventDefault();
}
// Stops event processing in IE
me.evt.returnValue = false;
// Sets local consumed state
if (!Client.IS_SF && !Client.IS_MAC)
{
me.consumed = true;
}
};
Dispatches the given event to the listeners which are registered for the event. The sender argument is optional. The current execution scope ("this") is used for the listener invocation (see Utils#bind).
Example:
fireEvent(new mxEventObject("eventName", key1, val1, .., keyN, valN))
EventObject that represents the event.
Optional sender to be passed to the listener. Default value is
the return value of
Handles the event by initiating the panning. By consuming the event all subsequent events of the gesture are redirected to this handler.
Handles the event by updating the panning on the graph.
Handles the event by setting the translation on the view or showing the popupmenu.
Event handler that pans and creates popupmenus. To use the left mouse button for panning without interfering with cell moving and resizing, use and . For grid size
steps while panning, use .
When registered in the Graph.constructor plugins list, it can be enabled using Graph.setPanning.
Event: mxEvent.PAN_START
Fires when the panning handler changes its state to true. The
event
property contains the corresponding MouseEvent.Event: mxEvent.PAN
Fires while handle is processing events. The
event
property contains the corresponding MouseEvent.Event: mxEvent.PAN_END
Fires when the panning handler changes its state to false. The
event
property contains the corresponding MouseEvent.