|
|||||
| SUMMARY: FIELD | CONSTR | METHOD| EVENT | DETAIL: FIELD | CONSTR | METHOD| EVENT | ||||
A widget which visualizes the currently visible area of another GraphCanvas on an overview canvas and enables viewpoint dragging in the overview.
The ViewPortMarker is realized by a transparent <div> element with the
CSS class yFilesViewPortMarker. Its appearance can be modified by updating or overriding
the CSS rule for this class.
| Field Summary | |
|---|---|
GraphCanvas |
canvas
The graph canvas whose visible area this widget visualizes. |
String |
canvasId
widget id of the observed GraphCanvas |
Number |
dragDelay
The delay between actual viewport changes caused by subsequent drag moves, in milliseconds. The delay will only be used in bitmap mode in order to limit the amount of tile requests while dragging the viewport marker. The default value is 30. |
Object |
lastBounds
An object with the properties x, y, width, height and zoom that describes the
most recent bounds and zoom value of the overview. |
HTMLDivElement |
marker
The top-level element representing this widget. |
HTMLElement |
markerParent
The element that represents the overview widget. |
String |
overviewId
widget id of the overview GraphCanvas |
String |
templateString
The template that is used to create the HTML for this widget. |
| Method Summary | |
|---|---|
|
_onMouseDown(/*Event*/ evt)
Called when the left mouse button has been pressed on the viewport visualization. |
|
_onMouseUp(/*Event*/ evt)
Called when the left mouse button has been released on the overview canvas. |
|
canvasChanged(/*Number*/ x, /*Number*/ y, /*Number*/ width, /*Number*/ height, /*Number*/ zoom)
Callback that is invoked when the viewport of the canvas was changed. |
|
centerMarker(/*MouseEvent*/ evt)
Callback that centers the viewport visualization around the specified event position. |
dojo.dnd.Moveable |
createMovable()
Create the dojo.dnd.Moveable instance that will be used by the instance to drag the viewport visualization. |
|
lateInitialization(/*Object*/ widget)
Called when any widget has been added to the canvas in order to resolve the main canvas, using the provided canvas id. |
|
markerChanged(/*dojo.dnd.Mover*/ mover, /*Object*/ leftTop)
Callback that is invoked when the viewport visualization was moved. |
|
overviewChanged()
Callback that is invoked when the viewport of the overview was changed. |
|
postCreate()
|
| Field Detail |
|---|
/*GraphCanvas*/ canvas
/*String*/ canvasId
/*Number*/ dragDelay
30.
/*Object*/ lastBounds
x, y, width, height and zoom that describes the
most recent bounds and zoom value of the overview.
/*HTMLDivElement*/ marker
/*HTMLElement*/ markerParent
/*String*/ overviewId
/*String*/ templateString
| Method Detail |
|---|
_onMouseDown(/*Event*/ evt)
evt - The mouse down event
_onMouseUp(/*Event*/ evt)
evt - The mouse up event
canvasChanged(/*Number*/ x, /*Number*/ y, /*Number*/ width, /*Number*/ height, /*Number*/ zoom)
x - The new x coordinate of the canvas.
y - The new y coordinate of the canvas.
width - The new width of the canvas.
height - The new height of the canvas.
zoom - The new zoom of the canvas.
centerMarker(/*MouseEvent*/ evt)
evt - The event specifying the coordinates where the viewport should be centered.
dojo.dnd.Moveable createMovable()
dojo.dnd.Moveable instance that will be used by the instance to drag the viewport visualization.lateInitialization(/*Object*/ widget)
widget - A widget that has just been added to the document.
markerChanged(/*dojo.dnd.Mover*/ mover, /*Object*/ leftTop)
mover - The Mover subclass that is used to drag the viewport visualization
leftTop - An object with l and t properties specifying the topleft coordinates of the Mover.
overviewChanged()
postCreate()