public class FXChangeViewportPolicy extends AbstractTransactionPolicy<javafx.scene.Node>
| Constructor and Description |
|---|
FXChangeViewportPolicy() |
| Modifier and Type | Method and Description |
|---|---|
protected ITransactionalOperation |
createOperation()
Creates an
ITransactionalOperation that is used to encapsulate
the changes that are applied by this AbstractTransactionPolicy
through its "work" methods. |
protected FXChangeViewportOperation |
getChangeViewportOperation()
Returns an
FXChangeViewportOperation that is extracted from the
operation created by createOperation(). |
void |
scrollRelative(double deltaTranslateX,
double deltaTranslateY)
Advances the viewport transformation by the given translation values.
|
void |
zoomRelative(double relativeZoom,
double sceneX,
double sceneY)
Concatenates a scaling transformation to the current viewport
transformation.
|
checkInitialized, commit, getOperation, init, isInitialized, locallyExecuteOperation, rollbackgetAdaptable, getHost, setAdaptableprotected ITransactionalOperation createOperation()
AbstractTransactionPolicyITransactionalOperation that is used to encapsulate
the changes that are applied by this AbstractTransactionPolicy
through its "work" methods. The created operation should allow for
local execution at each time.createOperation in class AbstractTransactionPolicy<javafx.scene.Node>ITransactionalOperation to encapsulate all applied
changes.protected FXChangeViewportOperation getChangeViewportOperation()
FXChangeViewportOperation that is extracted from the
operation created by createOperation().FXChangeViewportOperation that is extracted from the
operation created by createOperation().public void scrollRelative(double deltaTranslateX,
double deltaTranslateY)
deltaTranslateX - The horizontal translation delta.deltaTranslateY - The vertical translation delta.public void zoomRelative(double relativeZoom,
double sceneX,
double sceneY)
relativeZoom - The scale factor.sceneX - The pivot x-coordinate.sceneY - The pivot y-coordinate.Copyright (c) 2014 itemis AG and others. All rights reserved.