Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/toolsmiths/gmf-tooling/org.eclipse.papyrus.gmf.codegen/templates/xpt/editor/ActionBarContributor.xpt')
-rw-r--r--plugins/toolsmiths/gmf-tooling/org.eclipse.papyrus.gmf.codegen/templates/xpt/editor/ActionBarContributor.xpt73
1 files changed, 0 insertions, 73 deletions
diff --git a/plugins/toolsmiths/gmf-tooling/org.eclipse.papyrus.gmf.codegen/templates/xpt/editor/ActionBarContributor.xpt b/plugins/toolsmiths/gmf-tooling/org.eclipse.papyrus.gmf.codegen/templates/xpt/editor/ActionBarContributor.xpt
deleted file mode 100644
index 50948f55f08..00000000000
--- a/plugins/toolsmiths/gmf-tooling/org.eclipse.papyrus.gmf.codegen/templates/xpt/editor/ActionBarContributor.xpt
+++ /dev/null
@@ -1,73 +0,0 @@
-/******************************************************************************
- * Copyright (c) 2007, 2020 Borland Software Corporation, CEA LIST, Artal
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Aurelien Didier (ARTAL) - aurelien.didier51@gmail.com - Bug 569174
- *****************************************************************************/
-«IMPORT 'http://www.eclipse.org/papyrus/gmf/2020/GenModel'»
-
-«EXTENSION xpt::GenEditorGenerator»
-
-«DEFINE ActionBarContributor FOR gmfgen::GenEditorView-»
-«EXPAND xpt::Common::copyright FOR editorGen-»
-package «packageName»;
-
-«EXPAND xpt::Common::generatedClassComment»
-public class «actionBarContributorClassName»«EXPAND extendsList» {
-
- «EXPAND xpt::Common::generatedMemberComment»
- protected Class getEditorClass() {
- return «getQualifiedClassName()».class;
- }
-
- «EXPAND xpt::Common::generatedMemberComment»
- protected String getEditorId() {
- return «getQualifiedClassName()».ID;
- }
- «EXPAND initMethod-»
- «EXPAND additions-»
-}
-«ENDDEFINE»
-
-«DEFINE extendsList FOR gmfgen::GenEditorView» extends org.eclipse.gmf.runtime.diagram.ui.parts.DiagramActionBarContributor«ENDDEFINE»
-
-«DEFINE initMethod FOR gmfgen::GenEditorView»
- «EXPAND xpt::Common::generatedMemberComment»
- public void init(org.eclipse.ui.IActionBars bars, org.eclipse.ui.IWorkbenchPage page) {
- super.init(bars, page);
- // print preview
- org.eclipse.jface.action.IMenuManager fileMenu = bars.getMenuManager().findMenuUsingPath(org.eclipse.ui.IWorkbenchActionConstants.M_FILE);
- «EXPAND xpt::Common::_assert('fileMenu != null')-»
-«IF editorGen.plugin.printingEnabled-»
- org.eclipse.jface.action.IAction printPreviewAction = new org.eclipse.gmf.runtime.diagram.ui.printing.render.actions.RenderedPrintPreviewAction(new org.eclipse.gmf.runtime.diagram.ui.printing.render.actions.EnhancedPrintActionHelper());
- fileMenu.insertBefore("print", printPreviewAction);«EXPAND xpt::Common::nonNLS»
-«ELSE-»
- fileMenu.remove("pageSetupAction");«EXPAND xpt::Common::nonNLS»
-«ENDIF-»
-«IF /*hasAudits || hasMetrics */editorGen.diagram.validationEnabled or hasAudits(editorGen) or (editorGen.metrics <> null and editorGen.metrics.metrics->size() > 0)-»
- org.eclipse.jface.action.IMenuManager editMenu = bars.getMenuManager().findMenuUsingPath(org.eclipse.ui.IWorkbenchActionConstants.M_EDIT);
- «EXPAND xpt::Common::_assert('editMenu != null')-»
- if (editMenu.find("validationGroup") == null) {«EXPAND xpt::Common::nonNLS»
- editMenu.add(new org.eclipse.jface.action.GroupMarker("validationGroup"));«EXPAND xpt::Common::nonNLS»
- }
-«IF editorGen.diagram.validationEnabled or hasAudits(editorGen)-»
- org.eclipse.jface.action.IAction validateAction = new «EXPAND xpt::editor::ValidateAction::qualifiedClassName FOR editorGen.diagram»(page);
- editMenu.appendToGroup("validationGroup", validateAction);«EXPAND xpt::Common::nonNLS»
-«ENDIF-»
-«IF editorGen.metrics <> null and editorGen.metrics.metrics->size() > 0-»
- org.eclipse.jface.action.IAction metricsAction = new «editorGen.diagram.getMetricProviderQualifiedClassName()».MetricsAction(page);
- editMenu.appendToGroup("validationGroup", metricsAction);«EXPAND xpt::Common::nonNLS»
-«ENDIF-»
-«ENDIF /*hasAudits || hasMetrics */-»
- }
-«ENDDEFINE»
-
-«DEFINE additions FOR gmfgen::GenEditorView»«ENDDEFINE»

Back to the top