Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorashatalin2008-12-29 07:41:38 -0500
committerashatalin2008-12-29 07:41:38 -0500
commitfc1dfb3b462e159eec1b6031bb41ab79c762474b (patch)
tree66acb7873f68640147106dcd919a5041ecbc918b /plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt
parent7f3bb1960b122d5d9c4edae8dc1c330032c9cf60 (diff)
downloadorg.eclipse.gmf-tooling-fc1dfb3b462e159eec1b6031bb41ab79c762474b.tar.gz
org.eclipse.gmf-tooling-fc1dfb3b462e159eec1b6031bb41ab79c762474b.tar.xz
org.eclipse.gmf-tooling-fc1dfb3b462e159eec1b6031bb41ab79c762474b.zip
QVTO-based xpand implementation was merged to HEAD
Diffstat (limited to 'plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt')
-rw-r--r--plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt43
1 files changed, 43 insertions, 0 deletions
diff --git a/plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt b/plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt
new file mode 100644
index 000000000..a1c0d643f
--- /dev/null
+++ b/plugins/org.eclipse.gmf.codegen/templates.migrated/impl/diagram/editparts/ChildNodeLabelEditPart.xpt
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2006, 2007 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
+ * Alexander Shatalin (Borland) - initial API and implementation
+ */
+
+«IMPORT 'http://www.eclipse.org/gmf/2008/GenModel'»
+
+«DEFINE contsructor FOR gmfgen::GenChildLabelNode-»
+ «EXPAND xpt::Common::generatedMemberComment»
+ public «editPartClassName»(org.eclipse.gmf.runtime.notation.View view) {
+ super(view);
+ }
+«ENDDEFINE»
+
+«DEFINE getDragTrackerBody FOR gmfgen::GenChildLabelNode-»
+ if (request instanceof org.eclipse.gef.requests.SelectionRequest && ((org.eclipse.gef.requests.SelectionRequest) request).getLastButtonPressed() == 3) {
+ return null;
+ }
+ return new org.eclipse.gmf.runtime.diagram.ui.tools.DragEditPartsTrackerEx(this);
+«ENDDEFINE»
+
+«DEFINE createDefaultEditPoliciesBody FOR gmfgen::GenChildLabelNode-»
+ super.createDefaultEditPolicies();
+ installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.SEMANTIC_ROLE, new «getItemSemanticEditPolicyQualifiedClassName()»());
+ installEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE, new «getDiagram().getTextNonResizableEditPolicyQualifiedClassName()»());
+ installEditPolicy(org.eclipse.gef.EditPolicy.COMPONENT_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.ListItemComponentEditPolicy());
+ installEditPolicy(org.eclipse.gef.EditPolicy.DIRECT_EDIT_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.LabelDirectEditPolicy());
+ «EXPAND xpt::diagram::editparts::Common::behaviour FOR self-»
+«ENDDEFINE»
+
+«DEFINE handleNotificationEventBody FOR gmfgen::GenChildLabelNode-»
+ Object feature = event.getFeature();
+ «EXPAND xpt::diagram::editparts::Common::handleText FOR self-»
+ super.handleNotificationEvent(event);
+«ENDDEFINE» \ No newline at end of file

Back to the top