Class TLcdGXYTouchNavigateController
- All Implemented Interfaces:
ILcdAWTEventListener,ILcdStatusSource,ILcdGXYChainableController,ILcdGXYController,Serializable
TLcdTouchPoints which are not-consumed, and marks the
TLcdTouchPoints it uses as consumed, similar to the ALcdGXYTouchChainableController.- Since:
- 10.0
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new navigation controller with a defaultTLcdGXYNavigateControllerModel.TLcdGXYTouchNavigateController(TLcdGXYNavigateControllerModel aControllerModel) Creates a new navigation controller based onaControllerModel.TLcdGXYTouchNavigateController(TLcdGXYNavigateControllerModel aControllerModel, boolean aShouldRotate, boolean aShouldScale, boolean aShouldTranslate) Creates a new navigation controller based onaControllerModel. -
Method Summary
Modifier and TypeMethodDescriptionvoidThis method will append the passed controller to the end of the chain.intReturns the threshold for move events.Returns a reference to the controller that is located after this one in a chain, or null if this controller is the last element of the chain.voidhandleAWTEvent(AWTEvent aEvent) This is method is called when the target of the listener has a new AWTEvent available.voidEnables the controller to give visual feedback on the current user interactions.protected voidThe specific implementation ofpaintfor this controller.protected voidsetGXYView(ILcdGXYView aGXYView) Sets theILcdGXYViewthe controller is interacting with.voidsetMoveThreshold(int aMoveThreshold) Sets the threshold for move events.voidThis method sets the next controller in the chain for this controller.voidstartInteraction(ILcdGXYView aGXYView) Sets up the controller to receive input through the view passed.protected voidstartInteractionImpl(ILcdGXYView aGXYView) The specific implementation ofstartInteractionfor this controller.voidterminateInteraction(ILcdGXYView aGXYView) Releases a few items.protected voidterminateInteractionImpl(ILcdGXYView aGXYView) The specific implementation ofterminateInteractionfor this controller.Methods inherited from class com.luciad.view.gxy.controller.ALcdGXYChainableController
addStatusListener, removeStatusListenerMethods inherited from class com.luciad.view.gxy.controller.ALcdGXYController
asGXYController, fireStatusEvent, getCursor, getGXYView, getIcon, getName, getShortDescription, isTraceOn, registerInstance, retrieveGXYViewXYWorldTransformation, setClassTraceOn, setCursor, setIcon, setName, setShortDescription, setTraceOn, viewRepaintMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.luciad.view.gxy.ILcdGXYController
getCursor, getIcon, getLayered, getName, getShortDescription, viewRepaint
-
Constructor Details
-
TLcdGXYTouchNavigateController
public TLcdGXYTouchNavigateController()Creates a new navigation controller with a defaultTLcdGXYNavigateControllerModel.
-
-
Method Details
-
getNextGXYController
Description copied from interface:ILcdGXYChainableControllerReturns a reference to the controller that is located after this one in a chain, or null if this controller is the last element of the chain.- Specified by:
getNextGXYControllerin interfaceILcdGXYChainableController- Overrides:
getNextGXYControllerin classALcdGXYChainableController- Returns:
- a reference to the next controller.
- See Also:
-
setNextGXYController
Description copied from interface:ILcdGXYChainableControllerThis method sets the next controller in the chain for this controller. You can set null if you want the chain to end. This method does not start or terminate any interaction. If you need to replace a controller while it's being used you are responsible for properly terminating and starting it yourself.- Specified by:
setNextGXYControllerin interfaceILcdGXYChainableController- Overrides:
setNextGXYControllerin classALcdGXYChainableController- Parameters:
aNext- the reference to the controller that will be the next element in the chain- See Also:
-
appendGXYController
Description copied from interface:ILcdGXYChainableControllerThis method will append the passed controller to the end of the chain. The controller will be the stored as the next controller in the last element of the current chain.- Specified by:
appendGXYControllerin interfaceILcdGXYChainableController- Overrides:
appendGXYControllerin classALcdGXYChainableController- Parameters:
aEnd- the controller to be appended to the end of the chain.
-
startInteractionImpl
Description copied from class:ALcdGXYChainableControllerThe specific implementation ofstartInteractionfor this controller.- Overrides:
startInteractionImplin classALcdGXYChainableController- Parameters:
aGXYView- the view to start interaction with.
-
terminateInteractionImpl
Description copied from class:ALcdGXYChainableControllerThe specific implementation ofterminateInteractionfor this controller.- Overrides:
terminateInteractionImplin classALcdGXYChainableController- Parameters:
aGXYView- the view to terminate interaction with.
-
paintImpl
Description copied from class:ALcdGXYChainableControllerThe specific implementation ofpaintfor this controller.- Overrides:
paintImplin classALcdGXYChainableController- Parameters:
aGraphics- the graphics to be used for painting.
-
startInteraction
Description copied from class:ALcdGXYChainableControllerSets up the controller to receive input through the view passed.All
ILcdGXYViewimplementations that support interaction call this method when the controller has been made active withsetGXYControlleron the view, so this method shouldn't normally be called directly. Note that most view implementations add the controller as listener if appropriate before calling this method.Sets the cursor on the view and sets the view for which this controller is now active. Sends out a status event based on the
short description.This method also calls
ALcdGXYChainableController.startInteraction(com.luciad.view.gxy.ILcdGXYView)on the next controller. OverrideALcdGXYChainableController.startInteractionImpl(com.luciad.view.gxy.ILcdGXYView)if you want to add your own behavior to this controller.- Specified by:
startInteractionin interfaceILcdGXYController- Overrides:
startInteractionin classALcdGXYChainableController- Parameters:
aGXYView- theILcdGXYViewthisILcdGXYControllerwill interact with.- See Also:
-
terminateInteraction
Description copied from class:ALcdGXYChainableControllerReleases a few items. Can be redefined but this 'super' method should be called too.This method also calls
ALcdGXYChainableController.terminateInteraction(com.luciad.view.gxy.ILcdGXYView)on the next controller. OverrideALcdGXYChainableController.terminateInteractionImpl(com.luciad.view.gxy.ILcdGXYView)if you want to add your own behavior to this controller.- Specified by:
terminateInteractionin interfaceILcdGXYController- Overrides:
terminateInteractionin classALcdGXYChainableController- Parameters:
aGXYView- theILcdGXYViewthisILcdGXYControllerinteracted with.- See Also:
-
paint
Description copied from class:ALcdGXYChainableControllerEnables the controller to give visual feedback on the current user interactions. Note that the controller is responsible for repainting the view.Empty implementation. Redefine this method to render on the Graphics on which the view is rendered.
This method also calls
ALcdGXYChainableController.paint(java.awt.Graphics)on the next controller. OverrideALcdGXYChainableController.paintImpl(java.awt.Graphics)if you want to add your own behavior to this controller.- Specified by:
paintin interfaceILcdGXYController- Overrides:
paintin classALcdGXYChainableController- Parameters:
aGraphics- the Graphics on which the view was rendered.- See Also:
-
setGXYView
Description copied from class:ALcdGXYControllerSets theILcdGXYViewthe controller is interacting with.This method is called when
ILcdGXYView.setGXYControlleris used to set anILcdGXYControlleractive on anILcdGXYView.- Overrides:
setGXYViewin classALcdGXYController- Parameters:
aGXYView- the view the controller is interacting with- See Also:
-
handleAWTEvent
Description copied from interface:ILcdAWTEventListenerThis is method is called when the target of the listener has a new AWTEvent available.- Parameters:
aEvent- The event to be handled.
-
setMoveThreshold
public void setMoveThreshold(int aMoveThreshold) Sets the threshold for move events.
A move event will only be handled if the move exceeds the threshold in either the x or y direction.
- Parameters:
aMoveThreshold- the move threshold- See Also:
-
getMoveThreshold
public int getMoveThreshold()Returns the threshold for move events.
- Returns:
- the threshold for move events
- See Also:
-