protected void createDragHandle(List handles, int direction) { if (isDragAllowed()) { // display 'resize' handles to allow dragging (drag tracker) NonResizableHandleKit.addHandle((GraphicalEditPart) getHost(), handles, direction, getDragTracker(), SharedCursors.SIZEALL); } else { // display 'resize' handles to indicate selection only (selection // tracker) NonResizableHandleKit.addHandle((GraphicalEditPart) getHost(), handles, direction, getSelectTracker(), SharedCursors.ARROW); } }
/** * Creates a 'resize'/'drag' handle, which uses a * {@link DragEditPartsTracker} in case {@link #isDragAllowed()} returns * true, and a {@link SelectEditPartTracker} otherwise. * * @param handles * The list of handles to add the resize handle to * @param direction * A position constant indicating the direction to create the * handle for * @since 3.7 */ protected void createDragHandle(List handles, int direction) { if (isDragAllowed()) { // display 'resize' handles to allow dragging (drag tracker) NonResizableHandleKit .addHandle((GraphicalEditPart) getHost(), handles, direction, getDragTracker(), SharedCursors.SIZEALL); } else { // display 'resize' handles to indicate selection only (selection // tracker) NonResizableHandleKit .addHandle((GraphicalEditPart) getHost(), handles, direction, getSelectTracker(), SharedCursors.ARROW); } }