![]() |
MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
|
This is a simple interaction mode for handling grab pan.
The user's application creates an instance of one these classes and adds it to a TSLInteractionModeManager.
When an LButtonDown event occurs, the mode stores the event position. If the mouse moves more that 3 pixels from the starting position, then a grab pan begins and the drawing surface is redrawn at each mouse move event, with the original press location anchored below the cursor. Dynamic arc maps may exhibit offsets during grab pan.
When an RButtonUp event occurs, the mode resets to the default mode.
Public Member Functions | |
TSLInteractionModeGrab (int modeID, bool feedbackOnDrag=true, const char *prompt="Left button drag move view, Right button click to finish", bool middleButtonPansToPoint=true) | |
~TSLInteractionModeGrab () | |
void | activate () |
void | deactivate () |
virtual bool | onLButtonDown (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onLButtonUp (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onMouseMove (TSLButtonType button, TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onRButtonUp (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
TSLCursorStyle | queryCursor () |
virtual const char * | queryPrompt () |
void * | operator new (size_t size) TSL_NO_THROW |
void | operator delete (void *self) |
void * | operator new (size_t size, char *filename, int line) |
![]() | |
virtual | ~TSLInteractionMode () |
virtual void | onDraw (TSLDeviceUnits x1, TSLDeviceUnits y1, TSLDeviceUnits x2, TSLDeviceUnits y2) |
virtual bool | onMButtonDown (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onMButtonUp (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onMouseWheel (short delta, TSLDeviceUnits x, TSLDeviceUnits y, int zoomPercentage, bool lockCursorLocation) |
virtual bool | onRButtonDown (TSLDeviceUnits x, TSLDeviceUnits y, bool shift, bool control) |
virtual bool | onGestureZoom (TSLDeviceUnits cx, TSLDeviceUnits cy, double zoomFactor) |
virtual bool | onGesturePan (TSLDeviceUnits startx, TSLDeviceUnits starty, TSLDeviceUnits endx, TSLDeviceUnits endy) |
virtual bool | onGestureRotate (TSLDeviceUnits cx, TSLDeviceUnits cy, double dblAngle) |
virtual bool | onGestureTap (TSLDeviceUnits x, TSLDeviceUnits y) |
virtual bool | onGesturePressAndTap (TSLDeviceUnits firstFingerX, TSLDeviceUnits firstFingerY, long lDelta) |
virtual bool | onGestureTwoFingerTap (TSLDeviceUnits cx, TSLDeviceUnits cy) |
virtual void | onSize (TSLDeviceUnits cx, TSLDeviceUnits cy) |
virtual void | setDisplay (TSLInteractionModeDisplay *display) |
int | id () |
Additional Inherited Members | |
![]() | |
TSLInteractionMode (int modeID, bool middleButtonPansToPoint=true) | |
![]() | |
int | m_id |
TSLDrawingSurface * | m_drawingSurface |
bool | m_middleButtonPansToPoint |
TSLInteractionModeDisplay * | m_display |
TSLInteractionModeGrab::TSLInteractionModeGrab | ( | int | modeID, |
bool | feedbackOnDrag = true, | ||
const char * | prompt = "Left button drag move view, Right button click to finish", | ||
bool | middleButtonPansToPoint = true ) |
Constructor for grab interaction mode class.
modeID | This ID is not used by the mode itself, but is used as a unique identified by the mode manager. |
feedbackOnDrag | Default true. Flag to indicate whether viewChanged feedback should be sent during the drag. The view is not placed on the view stack until the release event. |
prompt | Defaulted to interaction description. Prompt to return from queryPrompt method. |
middleButtonPansToPoint | Defaults to true. This flag allows modes to easily provide standard behaviour for pressing of the middle button - typically the mouse wheel. |
TSLInteractionModeGrab::~TSLInteractionModeGrab | ( | ) |
See this class description and base class method description for further details
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
void TSLInteractionModeGrab::operator delete | ( | void * | self | ) |
void * TSLInteractionModeGrab::operator new | ( | size_t | size | ) |
void * TSLInteractionModeGrab::operator new | ( | size_t | size, |
char * | filename, | ||
int | line ) |
When included in an MFC application in debug mode, the debug new expects this to be here. Override it and return the same as the normal one. The library must include it when compiled in release mode, since the user's application may be in debug mode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.
|
virtual |
See this class description and base class method description for further details
Reimplemented from TSLInteractionMode.