Class EditorImageDefinition

All Implemented Interfaces:
IEditorImage, ILastVerified, IExtendsSelection, IPropDesigner, IPropUndoContext, EventListener, IAssetReferenceListener, IGProp<GProp<?>[]>, IImageTarget, IPropCnr, Cloneable, org.eclipse.core.runtime.IAdaptable

public class EditorImageDefinition extends ImageDefinition implements IPropDesigner, IPropUndoContext, IExtendsSelection, ILastVerified, IEditorImage
This Image Definition part property container for the Editor.
 Single Image Definition:
 ------------------------

  EditorImageDefinition
      !
      +-- EditorImageStyle
 
  • Constructor Details

    • EditorImageDefinition

      public EditorImageDefinition()
      Creates the Image Definition property container without a name. The name must be set in all cases using the setPropertyAtom call.
    • EditorImageDefinition

      public EditorImageDefinition(Atom propertyAtom)
      Creates the Image Definition property container with the specified name. All system-reserved names for components begins with "$".
      Parameters:
      propertyAtom - the name of the component, unique within it's parent.
  • Method Details

    • getCNImage

      public org.eclipse.swt.graphics.Image getCNImage()
      Gets the image for the Common Navigator.
      Specified by:
      getCNImage in interface IEditorImage
    • getCNType

      public String getCNType()
      Gets the type for the Common Navigator.
      Specified by:
      getCNType in interface IEditorImage
    • getCNText

      public String getCNText(int column)
      Gets the label text for the Common Navigator.
      Specified by:
      getCNText in interface IEditorImage
    • createTooltip

      public org.eclipse.swt.widgets.Composite createTooltip(org.eclipse.swt.widgets.Composite parent)
      Creates the tooltip.
      Specified by:
      createTooltip in interface IEditorImage
    • getLastVerified

      public LastVerified getLastVerified()
      Gets the last verified instance.
      Specified by:
      getLastVerified in interface ILastVerified
    • getDesigner

      public ImageDesignerProp getDesigner()
      Gets the Designer Extension for Properties.
      Specified by:
      getDesigner in interface IPropDesigner
      Returns:
      The instance of the Designer Extension.
    • getUndoContext

      public org.eclipse.core.commands.operations.IUndoContext getUndoContext()
      Gets the undo context.
      Specified by:
      getUndoContext in interface IPropUndoContext
      Returns:
      The undo context for the Editor part(s) for this container.
    • clone

      Clone must be overridden.
      Overrides:
      clone in class ImageDefinition
      Throws:
      CloneNotSupportedException - If a subclass doesn't allow cloning, e.g. the client properties.
    • getPossibleChildren

      public Class<?>[] getPossibleChildren()
      Gets the acceptable children property classes that can be used in conjunction with e.g. a Paste operation.
      Specified by:
      getPossibleChildren in interface IPropCnr
      Overrides:
      getPossibleChildren in class PropCnr
      Returns:
      An array containing the classes of possible children, or null for no support.
    • getExtendsPossibleClasses

      public Class<?>[] getExtendsPossibleClasses()
      Gets the possible classes this container supports for the Extends Framework. The default implementation is to return null.
      Specified by:
      getExtendsPossibleClasses in interface IPropCnr
      Overrides:
      getExtendsPossibleClasses in class PropCnr
      Returns:
      List of supported classes, or null for none.
    • getSelectPropDialogTitle

      public String getSelectPropDialogTitle()
      Gets the title for selection dialog.
      Specified by:
      getSelectPropDialogTitle in interface IExtendsSelection
    • getSelectPropViewerFilter

      public org.eclipse.jface.viewers.ViewerFilter getSelectPropViewerFilter()
      Gets the viewer filter for the tree in the dialog for selecting extends property name.
      Specified by:
      getSelectPropViewerFilter in interface IExtendsSelection
    • onAssetReferenceChanged

      public void onAssetReferenceChanged(AssetReference ref)
      Called when an asset file has been changed, either using new reference or the file contents. This enables verification of e.g. image size.
      Specified by:
      onAssetReferenceChanged in interface IAssetReferenceListener
      Overrides:
      onAssetReferenceChanged in class ImageDefinition
    • verify

      public boolean verify(PropVerification verification)
      Verifies this property container. The check performed is the extension of classes and that no circular reference is present.
      Specified by:
      verify in interface IGProp<GProp<?>[]>
      Overrides:
      verify in class PropCnr
      Parameters:
      verification - The property verification class.
      Returns:
      true if verification should proceed, false if disposed of and verification should not take place.