Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMickael ADAM2014-10-28 14:43:32 +0000
committerMickael ADAM2014-10-28 14:43:32 +0000
commit3c48bebecda0aea43d18d21b45d605b8d26c43a0 (patch)
tree5d1e35b8c83a0cc9f10778b79a874088d6787c46 /plugins/developer/org.eclipse.papyrus.def
parent7c2b3c623fda6d0aa674dba86348eac99a8d8808 (diff)
parent971bab65f2d9b629c915e90e4cd88417958937c4 (diff)
downloadorg.eclipse.papyrus-3c48bebecda0aea43d18d21b45d605b8d26c43a0.tar.gz
org.eclipse.papyrus-3c48bebecda0aea43d18d21b45d605b8d26c43a0.tar.xz
org.eclipse.papyrus-3c48bebecda0aea43d18d21b45d605b8d26c43a0.zip
Merge remote-tracking branch 'origin/bugs/440230_440226'
Conflicts: extraplugins/migration/org.eclipse.papyrus.migration.rsa/META-INF/MANIFEST.MF extraplugins/migration/org.eclipse.papyrus.migration.rsa/transform/RSARTToPapyrusRT.qvto plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz/META-INF/MANIFEST.MF plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.communication/META-INF/MANIFEST.MF plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.communication/model/communicationdiagram.gmfgen plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.component/model/ComponentDiagram.gmfgen plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.deployment/META-INF/MANIFEST.MF plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.deployment/src/org/eclipse/papyrus/uml/diagram/deployment/edit/parts/CommentEditPart.java plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.deployment/src/org/eclipse/papyrus/uml/diagram/deployment/edit/parts/CommentEditPartCN.java plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.profile/META-INF/MANIFEST.MF plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.profile/model/profilediagram.gmfgen plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence/custom-src/org/eclipse/papyrus/uml/diagram/sequence/edit/parts/CustomCombinedFragmentEditPart.java plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.statemachine/model/stateMachineDiagram.gmfgen plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.usecase/META-INF/MANIFEST.MF plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.usecase/models/usecaseDiagram.gmfgen releng/top-pom-dev.xml releng/top-pom-extra-tests.xml releng/top-pom-extras.xml releng/top-pom-main-tests.xml releng/top-pom-main.xml releng/top-pom-rcp.xml Change-Id: I8ff25c7122808fabff36f18df448007a68a2bd9c Signed-off-by: Mickael ADAM <mickael.adam@ALL4TEC.net>
Diffstat (limited to 'plugins/developer/org.eclipse.papyrus.def')
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend37
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend2
2 files changed, 30 insertions, 9 deletions
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend
index 92a862615da..03513d7a8c8 100644
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend
+++ b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend
@@ -11,14 +11,15 @@
* Alexander Shatalin (Borland) - initial API and implementation
* Michael Golubev (Montages) - #386838 - migrate to Xtend2
*/
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLinkLabel
-import org.eclipse.papyrus.papyrusgmfgenextension.LabelVisibilityPreference
-import xpt.Common
-
+package aspects.diagram.editparts
+
+import com.google.inject.Inject
+import com.google.inject.Singleton
+import org.eclipse.gmf.codegen.gmfgen.GenLinkLabel
+import org.eclipse.papyrus.papyrusgmfgenextension.LabelVisibilityPreference
+import xpt.Common
+import org.eclipse.gmf.codegen.gmfgen.CustomBehaviour
+
@Singleton class LinkLabelEditPart extends diagram.editparts.LinkLabelEditPart{
@Inject extension Common;
@@ -50,4 +51,24 @@ import xpt.Common
'''
override extendsList(GenLinkLabel it) '''extends org.eclipse.papyrus.infra.gmfdiag.common.editpart.PapyrusLabelEditPart'''
+
+ override createDefaultEditPolicies(GenLinkLabel it) '''
+ /**
+ * @generated Papyrus Generation
+ */
+ @Override
+ protected void createDefaultEditPolicies() {
+ super.createDefaultEditPolicies();
+ installEditPolicy(EditPolicy.DIRECT_EDIT_ROLE, new LabelDirectEditPolicy());
+ installEditPolicy(EditPolicy.SELECTION_FEEDBACK_ROLE, new «diagram.getTextSelectionEditPolicyQualifiedClassName()»());
+ ««« BEGIN: PapyrusGenCode
+ installEditPolicy(EditPolicy.PRIMARY_DRAG_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.PapyrusLinkLabelDragPolicy());
+ ««« END: PapyrusGenCode
+ ««« Get the added custom behavoir
+ «FOR CustomBehaviour:it.behaviour.filter(typeof (CustomBehaviour))»
+ installEditPolicy(«CustomBehaviour.key», new «CustomBehaviour.editPolicyQualifiedClassName»());
+ «ENDFOR»
+ }
+ '''
+
}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend
index 98166be601d..753a66250a3 100644
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend
+++ b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend
@@ -570,7 +570,7 @@ override refreshLabel(GenCommonBase it , GenDiagram diagram )'''
maskLabelPolicy = getEditPolicy(org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.IndirectMaskLabelEditPolicy.INDRIRECT_MASK_MANAGED_LABEL);
}
if (maskLabelPolicy == null) {
- View view = (View)getModel();
+ org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View)getModel();
if(view.isVisible()) {
setLabelTextHelper(getFigure(), getLabelText());
setLabelIconHelper(getFigure(), getLabelIcon());

Back to the top