Runtime

org.eclipse.gmf.runtime.diagram.ui.editparts
Class CompartmentEditPart

java.lang.Object
  extended byorg.eclipse.gef.editparts.AbstractEditPart
      extended byorg.eclipse.gef.editparts.AbstractGraphicalEditPart
          extended byorg.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart
              extended byorg.eclipse.gmf.runtime.diagram.ui.editparts.CompartmentEditPart
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, NotificationListener, RequestConstants
Direct Known Subclasses:
ResizableCompartmentEditPart, TextCompartmentEditPart

public abstract class CompartmentEditPart
extends GraphicalEditPart
implements org.eclipse.gmf.runtime.diagram.ui.internal.editparts.IContainedEditPart


Nested Class Summary
 
Nested classes inherited from class org.eclipse.gef.editparts.AbstractGraphicalEditPart
AbstractGraphicalEditPart.AccessibleGraphicalEditPart, AbstractGraphicalEditPart.DefaultAccessibleAnchorProvider
 
Nested classes inherited from class org.eclipse.gef.editparts.AbstractEditPart
AbstractEditPart.EditPolicyIterator
 
Field Summary
 
Fields inherited from class org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart
accessibleEP, elementGuid
 
Fields inherited from class org.eclipse.gef.editparts.AbstractGraphicalEditPart
figure, sourceConnections, targetConnections
 
Fields inherited from class org.eclipse.gef.editparts.AbstractEditPart
children, FLAG_ACTIVE, FLAG_FOCUS, MAX_FLAG
 
Fields inherited from interface org.eclipse.gef.EditPart
SELECTED, SELECTED_NONE, SELECTED_PRIMARY
 
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
CompartmentEditPart(EObject model)
          Constructs a new compartment edit part
 
Method Summary
protected  void createDefaultEditPolicies()
          Should be overridden to install editpolicies programmatically.
 DragTracker getDragTracker(Request request)
           
 boolean isSelectable()
          By default, all compartment edit parts get selectable only if the compartment's top level container matches the top level container of the editpart that currently has the keyboard focus i.e: you need to select the shape first before selecting a compartment but once a compartment is selected, a peer compartment can also be selected
 
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, getEditDomain, getEditingDomain, getMapMode, getModel, getModelChildren, getNotationView, getPreferredValue, getPrimaryChildEditPart, getPrimaryView, getResourceManager, getRoot, getStructuralFeatureValue, getTopGraphicEditPart, handleMajorSemanticChange, handleNotificationEvent, hasNotationView, isCanonical, isEditModeEnabled, notifyChanged, performDirectEditRequest, performRequest, reactivateSemanticModel, refresh, refreshBackgroundColor, refreshChild, refreshFont, refreshFontColor, refreshForegroundColor, refreshSourceConnection, refreshTargetConnection, refreshVisibility, refreshVisuals, 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, understandsRequest, 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.GraphicalEditPart
addNodeListener, getContentPane, getFigure, getSourceConnections, getTargetConnections, removeNodeListener, setLayoutConstraint
 
Methods inherited from interface org.eclipse.gef.EditPart
addEditPartListener, addNotify, getChildren, getEditPolicy, getParent, getSelected, getTargetEditPart, getViewer, hasFocus, installEditPolicy, isActive, removeEditPartListener, removeEditPolicy, setFocus, setParent, setSelected, understandsRequest
 

Constructor Detail

CompartmentEditPart

public CompartmentEditPart(EObject model)
Constructs a new compartment edit part

Method Detail

createDefaultEditPolicies

protected void createDefaultEditPolicies()
Description copied from class: GraphicalEditPart
Should be overridden to install editpolicies programmatically.

Overrides:
createDefaultEditPolicies in class GraphicalEditPart
See Also:
AbstractEditPart.createEditPolicies()

isSelectable

public boolean isSelectable()
By default, all compartment edit parts get selectable only if the compartment's top level container matches the top level container of the editpart that currently has the keyboard focus i.e: you need to select the shape first before selecting a compartment but once a compartment is selected, a peer compartment can also be selected

Specified by:
isSelectable in interface EditPart
Overrides:
isSelectable in class GraphicalEditPart
See Also:
EditPart.isSelectable()

getDragTracker

public DragTracker getDragTracker(Request request)
Specified by:
getDragTracker in interface EditPart
Overrides:
getDragTracker in class GraphicalEditPart
See Also:
EditPart.getDragTracker(org.eclipse.gef.Request)

Runtime

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.