Examples of EditPart


Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_3033) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.PhaseAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_2012) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.StructuralDatatypeAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_3040) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.SubKindAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

     * @generated NOT
     */
    private void updateContents() {
      SubKindEditPart editpart = SubKindEditPart.this;
      Classifier element = (Classifier) editpart.resolveSemanticElement();
      EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
          .getType(OntoUML.diagram.edit.parts.SubKindAttributeCompartmentEditPart.VISUAL_ID));
      if (compartmentEditPart != null) {
        if (element.getAttribute().size() == 0)
          ((View) compartmentEditPart.getModel()).setVisible(false);
        else {
          if (((View) compartmentEditPart.getModel()).isVisible() == false)
            ((View) compartmentEditPart.getModel())
                .setVisible(true);
          else {
            View view = (((View) (compartmentEditPart).getModel()));
            DrawerStyle drawerStyle = (DrawerStyle) view
                .getStyle(NotationPackage.eINSTANCE
View Full Code Here

Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_2009) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.RoleAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_2011) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.SimpleDatatypeAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

      if (selectedView == null) {
        return;
      }
      GraphicalViewer graphicalViewer = (GraphicalViewer) diagramEditor
          .getAdapter(GraphicalViewer.class);
      EditPart selectedEditPart = (EditPart) graphicalViewer
          .getEditPartRegistry().get(selectedView);
      if (selectedEditPart != null) {
        graphicalViewer.select(selectedEditPart);
      }
    }
View Full Code Here

Examples of org.eclipse.gef.EditPart

                    .getViewAndElementDescriptor()
                    .getCreateElementRequestAdapter();
                IElementType type = (IElementType) adapter
                    .getAdapter(IElementType.class);
                if (type == OntoUML.diagram.providers.OntoUMLElementTypes.Property_2001) {
                  EditPart compartmentEditPart = getChildBySemanticHint(OntoUML.diagram.part.OntoUMLVisualIDRegistry
                      .getType(OntoUML.diagram.edit.parts.CategoryAttributeCompartmentEditPart.VISUAL_ID));
                  return compartmentEditPart == null ? null
                      : compartmentEditPart
                          .getCommand(request);
                }
              }
              return super.getCommand(request);
            }
View Full Code Here

Examples of org.eclipse.gef.EditPart

  /**
   * @generated
   */
  public void createDecorators(IDecoratorTarget decoratorTarget) {
    EditPart editPart = (EditPart) decoratorTarget
        .getAdapter(EditPart.class);
    if (editPart instanceof GraphicalEditPart
        || editPart instanceof AbstractConnectionEditPart) {
      Object model = editPart.getModel();
      if ((model instanceof View)) {
        View view = (View) model;
        if (!(view instanceof Edge) && !view.isSetElement()) {
          return;
        }
      }
      EditDomain ed = editPart.getViewer().getEditDomain();
      if (!(ed instanceof DiagramEditDomain)) {
        return;
      }
      if (((DiagramEditDomain) ed).getEditorPart() instanceof OntoUML.diagram.part.OntoUMLDiagramEditor) {
        decoratorTarget.installDecorator(KEY, new StatusDecorator(
View Full Code Here

Examples of org.eclipse.gef.EditPart

      removeDecoration();
      View view = (View) getDecoratorTarget().getAdapter(View.class);
      if (view == null || view.eResource() == null) {
        return;
      }
      EditPart editPart = (EditPart) getDecoratorTarget().getAdapter(
          EditPart.class);
      if (editPart == null || editPart.getViewer() == null) {
        return;
      }

      // query for all the validation markers of the current resource
      int severity = IStatus.INFO;
      OntoUML.diagram.part.ValidationMarker foundMarker = null;
      OntoUML.diagram.part.ValidationMarker[] markers = OntoUML.diagram.part.ValidationMarker
          .getMarkers(editPart.getViewer(), viewId);
      if (markers == null || markers.length == 0) {
        return;
      }
      Label toolTip = null;
      for (int i = 0; i < markers.length; i++) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.