|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.gef.util.FlagSupport
org.eclipse.gef.tools.AbstractTool
org.eclipse.gef.tools.TargetingTool
sk.uniba.euromath.editor.xmlEditor.tools.XMLStructureDragTracker
sk.uniba.euromath.editor.textEditor.tools.TextDragTracker
public class TextDragTracker
Works like super, but pointer translation is performed to always point into
node's text. This is achieved by accepting as target and source editpart only
ITextPieceKeeper.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.eclipse.gef.tools.AbstractTool |
|---|
org.eclipse.gef.tools.AbstractTool.Input |
| Field Summary |
|---|
| Fields inherited from class org.eclipse.gef.tools.TargetingTool |
|---|
MAX_FLAG |
| Fields inherited from class org.eclipse.gef.tools.AbstractTool |
|---|
MAX_STATE, MOUSE_BUTTON_ANY, MOUSE_BUTTON1, MOUSE_BUTTON2, MOUSE_BUTTON3, PROPERTY_UNLOAD_WHEN_FINISHED, STATE_ACCESSIBLE_DRAG, STATE_ACCESSIBLE_DRAG_IN_PROGRESS, STATE_DRAG, STATE_DRAG_IN_PROGRESS, STATE_INITIAL, STATE_INVALID, STATE_TERMINAL |
| Fields inherited from interface org.eclipse.gef.RequestConstants |
|---|
REQ_ADD, REQ_ALIGN, REQ_ALIGN_CHILDREN, REQ_CLONE, REQ_CONNECTION_END, REQ_CONNECTION_START, REQ_CREATE, REQ_CREATE_BENDPOINT, REQ_DELETE, REQ_DELETE_DEPENDANT, REQ_DIRECT_EDIT, REQ_MOVE, REQ_MOVE_BENDPOINT, REQ_MOVE_CHILDREN, REQ_OPEN, REQ_ORPHAN, REQ_ORPHAN_CHILDREN, REQ_RECONNECT_SOURCE, REQ_RECONNECT_TARGET, REQ_RESIZE, REQ_RESIZE_CHILDREN, REQ_SELECTION, REQ_SELECTION_HOVER |
| Constructor Summary | |
|---|---|
TextDragTracker(TextEditPart source,
org.eclipse.draw2d.geometry.Point startLocation,
CaretManager cManager)
|
|
| Method Summary | |
|---|---|
protected DOMIntervalSet |
computeLocalSelection()
Computes local selection corresponding to drag. |
protected boolean |
evaluate(org.eclipse.gef.EditPart editpart)
Test editpart, if is acceptable as end point of selection under mouse. |
protected void |
finishDrag()
Is called at termination of drag to perfom and finish selection and drag related tasks. |
protected boolean |
handleButtonDown(int button)
|
protected boolean |
handleDragInProgress()
|
protected boolean |
handleDragStarted()
|
protected boolean |
handleEnteredEditPart()
Not needed - all done in handleDragInProgress. |
protected boolean |
handleExitingEditPart()
Not needed - all done in handleDragInProgress. |
protected DomPointer |
locationToDomPointer(org.eclipse.draw2d.geometry.Point p,
ITextPieceKeeper keeper)
Translates point in editpart to DOMPointer. |
protected void |
updateCaret()
Updates caret position to location of mouse cursor if possible. |
| Methods inherited from class sk.uniba.euromath.editor.xmlEditor.tools.XMLStructureDragTracker |
|---|
computeGlobalSelection, getCommandName, getSourceEditPart, getXMLAccess, getXMLGraphicalViewer, handleButtonUp, handleDrag, handleKeyDown, handleKeyUp, setViewer, updateTargetUnderMouse |
| Methods inherited from class org.eclipse.gef.tools.TargetingTool |
|---|
createTargetRequest, deactivate, doAutoexpose, eraseTargetFeedback, getCommand, getExclusionSet, getTargetEditPart, getTargetingConditional, getTargetRequest, handleAutoexpose, handleHoverStop, handleInvalidInput, handleLeavingEditPart, handleViewerExited, isShowingTargetFeedback, isTargetLocked, lockTargetEditPart, resetFlags, setAutoexposeHelper, setTargetEditPart, setTargetRequest, showTargetFeedback, unlockTargetEditPart, updateAutoexposeHelper, updateTargetRequest |
| Methods inherited from class org.eclipse.gef.tools.AbstractTool |
|---|
activate, addFeedback, applyProperty, calculateCursor, commitDrag, createOperationSet, debug, executeCommand, executeCurrentCommand, focusGained, focusLost, getCurrentCommand, getCurrentInput, getCurrentViewer, getDebugName, getDebugNameForState, getDefaultCursor, getDisabledCursor, getDomain, getDragMoveDelta, getLocation, getOperationSet, getStartLocation, getState, handleCommandStackChanged, handleDoubleClick, handleFinished, handleFocusGained, handleFocusLost, handleHover, handleKeyTraversed, handleMove, handleNativeDragFinished, handleNativeDragStarted, handleViewerEntered, isActive, isHoverActive, isInState, isViewerImportant, keyDown, keyTraversed, keyUp, mouseDoubleClick, mouseDown, mouseDrag, mouseHover, mouseMove, mouseUp, mouseWheelScrolled, movedPastThreshold, nativeDragFinished, nativeDragStarted, performViewerMouseWheel, reactivate, refreshCursor, releaseToolCapture, removeFeedback, setCurrentCommand, setCursor, setDefaultCursor, setDisabledCursor, setEditDomain, setHoverActive, setProperties, setStartLocation, setState, setToolCapture, setUnloadWhenFinished, stateTransition, unloadWhenFinished, viewerEntered, viewerExited |
| Methods inherited from class org.eclipse.gef.util.FlagSupport |
|---|
getFlag, setFlag |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.gef.DragTracker |
|---|
commitDrag |
| Methods inherited from interface org.eclipse.gef.Tool |
|---|
activate, deactivate, focusGained, focusLost, keyDown, keyTraversed, keyUp, mouseDoubleClick, mouseDown, mouseDrag, mouseHover, mouseMove, mouseUp, mouseWheelScrolled, nativeDragFinished, nativeDragStarted, setEditDomain, setProperties, viewerEntered, viewerExited |
| Constructor Detail |
|---|
public TextDragTracker(TextEditPart source,
org.eclipse.draw2d.geometry.Point startLocation,
CaretManager cManager)
owner - startLocation - location where this DragTracker starts it work| Method Detail |
|---|
protected boolean handleEnteredEditPart()
handleEnteredEditPart in class XMLStructureDragTrackerprotected boolean handleExitingEditPart()
handleExitingEditPart in class XMLStructureDragTrackerprotected boolean handleButtonDown(int button)
handleButtonDown in class XMLStructureDragTrackerprotected boolean handleDragStarted()
handleDragStarted in class XMLStructureDragTrackerprotected boolean handleDragInProgress()
handleDragInProgress in class XMLStructureDragTrackerprotected void updateCaret()
protected DOMIntervalSet computeLocalSelection()
XMLStructureDragTracker
computeLocalSelection in class XMLStructureDragTracker
protected DomPointer locationToDomPointer(org.eclipse.draw2d.geometry.Point p,
ITextPieceKeeper keeper)
p - point in editpartpart - editpart where point is
protected boolean evaluate(org.eclipse.gef.EditPart editpart)
XMLStructureDragTracker
evaluate in class XMLStructureDragTrackereditpart - to test for potential target - end point of selection
protected void finishDrag()
XMLStructureDragTracker
finishDrag in class XMLStructureDragTracker
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||