Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/developer/org.eclipse.papyrus.def/.svn/pristine/e2/e2541063afa0f72d551f6d30770becdc043c6797.svn-base')
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.svn/pristine/e2/e2541063afa0f72d551f6d30770becdc043c6797.svn-base64
1 files changed, 0 insertions, 64 deletions
diff --git a/plugins/developer/org.eclipse.papyrus.def/.svn/pristine/e2/e2541063afa0f72d551f6d30770becdc043c6797.svn-base b/plugins/developer/org.eclipse.papyrus.def/.svn/pristine/e2/e2541063afa0f72d551f6d30770becdc043c6797.svn-base
deleted file mode 100644
index 4cfc8ddcaf9..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.svn/pristine/e2/e2541063afa0f72d551f6d30770becdc043c6797.svn-base
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) 2007, 2009 Borland Software Corporation
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Ansgar Radermacher (CEA LIST) - added support for EMF validation
- */
-
-«IMPORT 'http://www.eclipse.org/gmf/2009/GenModel'»
-
-«DEFINE ValidationDecoratorProvider FOR gmfgen::GenDiagram-»
-«EXPAND xpt::Common::copyright FOR editorGen-»
-package «providersPackageName»;
-
-«EXPAND xpt::Common::generatedClassComment»
-public class «validationDecoratorProviderClassName»
- extends org.eclipse.papyrus.uml.diagram.common.providers.ValidationDecoratorProvider
- implements org.eclipse.gmf.runtime.diagram.ui.services.decorator.IDecoratorProvider {
-
- «EXPAND xpt::Common::generatedMemberComment»
- public void createDecorators(org.eclipse.gmf.runtime.diagram.ui.services.decorator.IDecoratorTarget decoratorTarget) {
- org.eclipse.gef.EditPart editPart = (org.eclipse.gef.EditPart) decoratorTarget.getAdapter(org.eclipse.gef.EditPart.class);
- if (editPart instanceof org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart ||
- editPart instanceof org.eclipse.gef.editparts.AbstractConnectionEditPart) {
- Object model = editPart.getModel();
- if ((model instanceof org.eclipse.gmf.runtime.notation.View)) {
- org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View) model;
- if (!(view instanceof org.eclipse.gmf.runtime.notation.Edge) && !view.isSetElement()) {
- return;
- }
- }
- org.eclipse.gef.EditDomain ed = editPart.getViewer().getEditDomain();
- if (!(ed instanceof org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditDomain)) {
- return;
- }
- if (((org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditDomain) ed).getEditorPart() instanceof
- «editorGen.editor.getQualifiedClassName()») {
- decoratorTarget.installDecorator(KEY, new StatusDecorator(decoratorTarget));
- }
- }
- }
-
- «EXPAND xpt::Common::generatedMemberComment»
- public boolean provides(org.eclipse.gmf.runtime.common.core.service.IOperation operation) {
- if (!(operation instanceof org.eclipse.gmf.runtime.diagram.ui.services.decorator.CreateDecoratorsOperation)) {
- return false;
- }
- org.eclipse.gmf.runtime.diagram.ui.services.decorator.IDecoratorTarget decoratorTarget =
- ((org.eclipse.gmf.runtime.diagram.ui.services.decorator.CreateDecoratorsOperation) operation).getDecoratorTarget();
- org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View) decoratorTarget.getAdapter(
- org.eclipse.gmf.runtime.notation.View.class);
- return view != null && «EXPAND xpt::editor::VisualIDRegistry::modelID».equals(«EXPAND xpt::editor::VisualIDRegistry::getModelIDMethodCall»(view));
- }
-
- «EXPAND additions-»
-}
-«ENDDEFINE»
-
-«DEFINE additions FOR gmfgen::GenDiagram»«ENDDEFINE»

Back to the top