org.eclipse.gmf.runtime.diagram.ui.editparts
Class ShapeEditPart
java.lang.Object
org.eclipse.gef.editparts.AbstractEditPart
org.eclipse.gef.editparts.AbstractGraphicalEditPart
org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart
org.eclipse.gmf.runtime.diagram.ui.editparts.TopGraphicEditPart
org.eclipse.gmf.runtime.diagram.ui.editparts.ShapeEditPart
- All Implemented Interfaces:
- EditPart, GraphicalEditPart, IAdaptable, IAdaptableSelection, org.eclipse.gmf.runtime.diagram.ui.internal.editparts.IContainedEditPart, org.eclipse.gmf.runtime.diagram.ui.internal.editparts.IEditableEditPart, IGraphicalEditPart, IPrimaryEditPart, NotificationListener, RequestConstants
- Direct Known Subclasses:
- ShapeNodeEditPart
- public abstract class ShapeEditPart
- extends TopGraphicEditPart
- implements IPrimaryEditPart
the base controler for shapes
| 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 |
| Methods inherited from class org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart |
activate, addChild, addListenerFilter, addListenerFilter, addNotationalListeners, addSemanticListeners, basicGetModel, createConnection, createEditPolicies, createFigure, deactivate, disableEditMode, enableEditMode, eraseSourceFeedback, eraseTargetFeedback, executeCommand, findEditPart, getAccessibleEditPart, getAdapter, getChildBySemanticHint, getChildBySemanticHintOnPrimaryView, getChildViewBySemanticHint, getCommand, getContentPaneFor, getDiagramEditDomain, getDiagramPreferencesHint, getDiagramView, getDragTracker, getEditDomain, getEditingDomain, getMapMode, getModel, getModelChildren, getNotationView, getPreferredValue, getPrimaryChildEditPart, getPrimaryView, getResourceManager, getRoot, getStructuralFeatureValue, getTopGraphicEditPart, handleMajorSemanticChange, hasNotationView, isCanonical, isEditModeEnabled, isSelectable, notifyChanged, performRequest, reactivateSemanticModel, refresh, refreshBackgroundColor, refreshChild, refreshFont, refreshFontColor, refreshForegroundColor, refreshSourceConnection, refreshTargetConnection, refreshVisibility, registerModel, removeListenerFilter, removeNotationalListeners, removeNotify, removeSemanticListeners, resolveSemanticElement, setBackgroundColor, setFont, setFontColor, setForegroundColor, setModel, setStructuralFeatureValue, setVisibility, showSourceFeedback, showTargetFeedback, transactionAboutToCommit, unregisterModel |
| Methods inherited from class org.eclipse.gef.editparts.AbstractGraphicalEditPart |
addChildVisual, addNodeListener, addNotify, addSourceConnection, addTargetConnection, createOrFindConnection, fireRemovingSourceConnection, fireRemovingTargetConnection, fireSourceConnectionAdded, fireTargetConnectionAdded, getContentPane, getFigure, getLayer, getModelSourceConnections, getModelTargetConnections, getSourceConnections, getTargetConnections, primAddSourceConnection, primAddTargetConnection, primRemoveSourceConnection, primRemoveTargetConnection, refreshSourceConnections, refreshTargetConnections, registerVisuals, removeChildVisual, removeNodeListener, removeSourceConnection, removeTargetConnection, reorderChild, reorderSourceConnection, reorderTargetConnection, setFigure, setLayoutConstraint, unregisterVisuals |
| Methods inherited from class org.eclipse.gef.editparts.AbstractEditPart |
activateEditPolicies, addEditPartListener, createChild, deactivateEditPolicies, debug, debugFeedback, fireActivated, fireChildAdded, fireDeactivated, fireRemovingChild, fireSelectionChanged, getChildren, getEditPolicy, getEditPolicyIterator, getEventListeners, getFlag, getParent, getSelected, getTargetEditPart, getViewer, hasFocus, installEditPolicy, isActive, refreshChildren, register, registerAccessibility, removeChild, removeEditPartListener, removeEditPolicy, setFlag, setFocus, setParent, setSelected, toString, unregister, unregisterAccessibility |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.eclipse.gef.EditPart |
addEditPartListener, addNotify, getChildren, getEditPolicy, getParent, getSelected, getTargetEditPart, getViewer, hasFocus, installEditPolicy, isActive, removeEditPartListener, removeEditPolicy, setFocus, setParent, setSelected |
ShapeEditPart
public ShapeEditPart(View view)
- copnstructor
- Parameters:
view - the view controlled by this edit part
createDefaultEditPolicies
protected void createDefaultEditPolicies()
- Description copied from class:
GraphicalEditPart
- Should be overridden to install editpolicies programmatically.
- Overrides:
createDefaultEditPolicies in class TopGraphicEditPart
getLocation
public final Point getLocation()
- gets the location of this edit part's Figure
- Returns:
Point
getSize
public final Dimension getSize()
- gets the size of this edit part's Figure
- Returns:
Dimension
handleNotificationEvent
protected void handleNotificationEvent(Notification notification)
- Description copied from class:
GraphicalEditPart
- Handles the property changed event. Clients should override to
respond to the specific notification events they are interested.
Note: This method may get called on a non-UI thread. Clients should
either ensure that their code is thread safe and/or doesn't make
unsupported calls (i.e. Display.getCurrent() ) assuming they are on
the main thread. Alternatively if this is not possible, then the
client can wrap their handler within the Display.synchExec runnable
to ensure synchronization and subsequent execution on the main thread.
- Overrides:
handleNotificationEvent in class GraphicalEditPart
- Parameters:
notification - the Notification object that is the property changed event
refreshBounds
protected void refreshBounds()
- refresh the bounds
refreshVisuals
protected void refreshVisuals()
- Description copied from class:
GraphicalEditPart
- Refresh the editpart's figure visual properties.
- Overrides:
refreshVisuals in class GraphicalEditPart
getPrimaryDragEditPolicy
public EditPolicy getPrimaryDragEditPolicy()
- Return the editpolicy to be installed as an
EditPolicy#PRIMARY_DRAG_ROLE
role. This method is typically called by LayoutEditPolicy#createChildEditPolicy()
- Returns:
- EditPolicy
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.