Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoratikhomirov2010-04-30 22:02:44 +0000
committeratikhomirov2010-04-30 22:02:44 +0000
commit75fdfc8f64fd5cb4fd9bf2f409849fd2171545d9 (patch)
tree3e72ca3909b04366165f36c2fb9f11a1991ce62d /plugins
parent8e8cd91cb51b3b3c6493272ab8daf153a4d5b5fb (diff)
downloadorg.eclipse.gmf-tooling-75fdfc8f64fd5cb4fd9bf2f409849fd2171545d9.tar.gz
org.eclipse.gmf-tooling-75fdfc8f64fd5cb4fd9bf2f409849fd2171545d9.tar.xz
org.eclipse.gmf-tooling-75fdfc8f64fd5cb4fd9bf2f409849fd2171545d9.zip
[188329] Java 5 code
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.gmf.codegen/templates/impl/diagram/editparts/DiagramEditPart.xpt6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/org.eclipse.gmf.codegen/templates/impl/diagram/editparts/DiagramEditPart.xpt b/plugins/org.eclipse.gmf.codegen/templates/impl/diagram/editparts/DiagramEditPart.xpt
index 2892e82ef..4223e28e6 100644
--- a/plugins/org.eclipse.gmf.codegen/templates/impl/diagram/editparts/DiagramEditPart.xpt
+++ b/plugins/org.eclipse.gmf.codegen/templates/impl/diagram/editparts/DiagramEditPart.xpt
@@ -28,8 +28,8 @@
«IF generateCreateShortcutAction() and null = editorGen.application-»
installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.DRAG_DROP_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.DiagramDragDropEditPolicy() {
public org.eclipse.gef.commands.Command getDropObjectsCommand(org.eclipse.gmf.runtime.diagram.ui.requests.DropObjectsRequest dropRequest) {
- java.util.List viewDescriptors = new java.util.ArrayList();
- for (java.util.Iterator it = dropRequest.getObjects().iterator(); it.hasNext();) {
+ «EXPAND CodeStyle::newGenericInstance('viewDescriptors', 'java.util.ArrayList', 'org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor')»();
+ for («EXPAND CodeStyle::G('java.util.Iterator', '?')» it = dropRequest.getObjects().iterator(); it.hasNext();) {
Object nextObject = it.next();
if (false == nextObject instanceof org.eclipse.emf.ecore.EObject) {
continue;
@@ -39,7 +39,7 @@
return createShortcutsCommand(dropRequest, viewDescriptors);
}
- private org.eclipse.gef.commands.Command createShortcutsCommand(org.eclipse.gmf.runtime.diagram.ui.requests.DropObjectsRequest dropRequest, java.util.List viewDescriptors) {
+ private org.eclipse.gef.commands.Command createShortcutsCommand(org.eclipse.gmf.runtime.diagram.ui.requests.DropObjectsRequest dropRequest, «EXPAND CodeStyle::G('java.util.List', 'org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor')» viewDescriptors) {
org.eclipse.gef.commands.Command command = createViewsAndArrangeCommand(dropRequest, viewDescriptors);
if (command != null) {
return command.chain(new org.eclipse.gmf.runtime.diagram.ui.commands.ICommandProxy(new «getCreateShortcutDecorationsCommandQualifiedClassName()»(getEditingDomain(), (org.eclipse.gmf.runtime.notation.View) getModel(), viewDescriptors)));

Back to the top