Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvlorenzo2013-01-10 16:55:50 +0000
committervlorenzo2013-01-10 16:55:50 +0000
commit14a80b6d43b4862250e7406251408e755d9fe841 (patch)
treea59b0164f54c875193b71046eeab44ed0df116c7 /sandbox
parent41cda7bd60c57d062a61c85ca1ba4c48d61b429a (diff)
downloadorg.eclipse.papyrus-14a80b6d43b4862250e7406251408e755d9fe841.tar.gz
org.eclipse.papyrus-14a80b6d43b4862250e7406251408e755d9fe841.tar.xz
org.eclipse.papyrus-14a80b6d43b4862250e7406251408e755d9fe841.zip
Initial import.
Diffstat (limited to 'sandbox')
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.classpath7
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.project28
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/META-INF/MANIFEST.MF15
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/build.properties5
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.gifbin0 -> 891 bytes
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.pngbin0 -> 1245 bytes
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/plugin.xml99
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/Activator.java50
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/editor/GenericUMLNattableEditor.java21
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/factory/GenericUMLNattableEditorFactory.java37
-rw-r--r--sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/handlers/CreateNattableEditorCommand.java35
11 files changed, 297 insertions, 0 deletions
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.classpath b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.classpath
new file mode 100644
index 00000000000..2d1a4302f04
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.classpath
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.project b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.project
new file mode 100644
index 00000000000..bff06e5cbd7
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/.project
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.papyrus.uml.nattable.generic</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/META-INF/MANIFEST.MF b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/META-INF/MANIFEST.MF
new file mode 100644
index 00000000000..a81459a81cc
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/META-INF/MANIFEST.MF
@@ -0,0 +1,15 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: Generic Table for UML (Incubation)
+Bundle-SymbolicName: org.eclipse.papyrus.uml.nattable.generic;singleton:=true
+Bundle-Version: 0.10.0.qualifier
+Bundle-Activator: org.eclipse.papyrus.uml.nattable.generic.Activator
+Bundle-Vendor: Eclispe Modeling Tools
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.eclipse.papyrus.infra.core.log;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.nattable.model;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.nattable.common;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.core
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Bundle-ActivationPolicy: lazy
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/build.properties b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/build.properties
new file mode 100644
index 00000000000..6f20375d6c7
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/build.properties
@@ -0,0 +1,5 @@
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+ .,\
+ plugin.xml
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.gif b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.gif
new file mode 100644
index 00000000000..7dba0a044de
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.gif
Binary files differ
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.png b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.png
new file mode 100644
index 00000000000..4bec73c4147
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/icons/uml_generic_table.png
Binary files differ
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/plugin.xml b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/plugin.xml
new file mode 100644
index 00000000000..5384e9b0304
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/plugin.xml
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+ <extension
+ point="org.eclipse.papyrus.infra.core.papyrusDiagram">
+ <editorDiagram
+ factoryClass="org.eclipse.papyrus.uml.nattable.generic.factory.GenericUMLNattableEditorFactory"
+ icon="icons/uml_generic_table.png">
+ </editorDiagram>
+ </extension>
+ <extension
+ point="org.eclipse.ui.commands">
+ <command
+ categoryId="org.eclipse.papyrus.editor.category"
+ description="Create a UML Generic NatTable Editor"
+ id="org.eclipse.papyrus.uml.nattable.generic.create.command"
+ name="Create a UML Generic NatTable Editor">
+ </command>
+ </extension>
+ <extension
+ point="org.eclipse.ui.handlers">
+ <handler
+ class="org.eclipse.papyrus.uml.nattable.generic.handlers.CreateNattableEditorCommand"
+ commandId="org.eclipse.papyrus.uml.nattable.generic.create.command">
+ <activeWhen>
+ <or>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.infra.core.papyrusEditor">
+ </equals>
+ </with>
+ </or>
+ </activeWhen>
+ </handler>
+ </extension>
+ <extension
+ id="create.table.menus"
+ name="Create Table Menus"
+ point="org.eclipse.ui.menus">
+ <menuContribution
+ allPopups="false"
+ locationURI="popup:org.eclipse.papyrus.infra.nattable.popupmenu.createnattable">
+ <command
+ commandId="org.eclipse.papyrus.uml.nattable.generic.create.command"
+ icon="icons/uml_generic_table.png"
+ label="UML Generic NatTable"
+ mnemonic="&amp;G"
+ style="push">
+ <visibleWhen>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.infra.core.papyrusEditor">
+ </equals>
+ </with>
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ allPopups="false"
+ locationURI="menu:org.eclipse.papyrus.infra.nattable.menu.createnattable">
+ <command
+ commandId="org.eclipse.papyrus.uml.nattable.generic.create.command"
+ icon="icons/uml_generic_table.png"
+ label="UML Generic NatTable"
+ mnemonic="&amp;G"
+ style="push">
+ <visibleWhen>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.infra.core.papyrusEditor">
+ </equals>
+ </with>
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ <menuContribution
+ allPopups="false"
+ locationURI="toolbar:org.eclipse.papyrus.infra.nattable.toolbar.createnattable">
+ <command
+ commandId="org.eclipse.papyrus.uml.nattable.generic.create.command"
+ icon="icons/uml_generic_table.gif"
+ label="UML Generic NatTable"
+ mnemonic="&amp;G"
+ style="push">
+ <visibleWhen>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.infra.core.papyrusEditor">
+ </equals>
+ </with>
+ </visibleWhen>
+ </command>
+ </menuContribution>
+ </extension>
+</plugin>
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/Activator.java b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/Activator.java
new file mode 100644
index 00000000000..3feca3f3d7a
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/Activator.java
@@ -0,0 +1,50 @@
+package org.eclipse.papyrus.uml.nattable.generic;
+
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends AbstractUIPlugin {
+
+ // The plug-in ID
+ public static final String PLUGIN_ID = "org.eclipse.papyrus.uml.nattable.generic"; //$NON-NLS-1$
+
+ // The shared instance
+ private static Activator plugin;
+
+ /**
+ * The constructor
+ */
+ public Activator() {
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
+ */
+ public void start(BundleContext context) throws Exception {
+ super.start(context);
+ plugin = this;
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
+ */
+ public void stop(BundleContext context) throws Exception {
+ plugin = null;
+ super.stop(context);
+ }
+
+ /**
+ * Returns the shared instance
+ *
+ * @return the shared instance
+ */
+ public static Activator getDefault() {
+ return plugin;
+ }
+
+}
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/editor/GenericUMLNattableEditor.java b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/editor/GenericUMLNattableEditor.java
new file mode 100644
index 00000000000..96e2fbb0279
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/editor/GenericUMLNattableEditor.java
@@ -0,0 +1,21 @@
+package org.eclipse.papyrus.uml.nattable.generic.editor;
+
+import org.eclipse.papyrus.infra.core.services.ServicesRegistry;
+import org.eclipse.papyrus.infra.nattable.common.editor.AbstractPapyrusNattableEditor;
+import org.eclipse.papyrus.infra.nattable.model.nattablepackage.Table;
+
+public class GenericUMLNattableEditor extends AbstractPapyrusNattableEditor {
+
+ /** the type of the editor */
+ public static final String EDITOR_TYPE = "PapyruGenericNattable"; //$NON-NLS-1$
+
+ /** the default name for this table */
+ public static final String DEFAULT_NAME = "GenericUMLTable"; //$NON-NLS-1$
+
+ public GenericUMLNattableEditor(ServicesRegistry servicesRegistry, final Table rawModel) {
+ super(servicesRegistry, rawModel);
+ }
+
+
+
+}
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/factory/GenericUMLNattableEditorFactory.java b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/factory/GenericUMLNattableEditorFactory.java
new file mode 100644
index 00000000000..e203fbbe45f
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/factory/GenericUMLNattableEditorFactory.java
@@ -0,0 +1,37 @@
+/*****************************************************************************
+ * Copyright (c) 2011 LIFL & CEA LIST.
+ *
+ *
+ * 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:
+ * Cedric Dumoulin (LIFL) cedric.dumoulin@lifl.fr - Initial API and implementation
+ * Vincent Lorenzo (CEA-LIST) vincent.lorenzo@cea.fr
+ *****************************************************************************/
+
+package org.eclipse.papyrus.uml.nattable.generic.factory;
+
+import org.eclipse.papyrus.infra.nattable.common.factory.AbstractNattableEditorFactory;
+import org.eclipse.papyrus.uml.nattable.generic.editor.GenericUMLNattableEditor;
+
+
+
+
+public class GenericUMLNattableEditorFactory extends AbstractNattableEditorFactory {
+
+
+ /**
+ * Constructor.
+ *
+ * @param diagramClass
+ * @param expectedType
+ */
+ public GenericUMLNattableEditorFactory() {
+ super(GenericUMLNattableEditor.class, GenericUMLNattableEditor.EDITOR_TYPE);
+ }
+
+
+}
diff --git a/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/handlers/CreateNattableEditorCommand.java b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/handlers/CreateNattableEditorCommand.java
new file mode 100644
index 00000000000..7a82f102574
--- /dev/null
+++ b/sandbox/TableV3/org.eclipse.papyrus.uml.nattable.generic/src/org/eclipse/papyrus/uml/nattable/generic/handlers/CreateNattableEditorCommand.java
@@ -0,0 +1,35 @@
+/*****************************************************************************
+ * Copyright (c) 2011 LIFL & CEA LIST.
+ *
+ *
+ * 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:
+ * Cedric Dumoulin (LIFL) cedric.dumoulin@lifl.fr - Initial API and implementation
+ * Vincent Lorenzo (CEA-LIST) vincent.lorenzo@cea.fr
+ *****************************************************************************/
+
+package org.eclipse.papyrus.uml.nattable.generic.handlers;
+
+import org.eclipse.papyrus.infra.nattable.common.editor.handlers.AbstractCreateNattableEditorHandler;
+import org.eclipse.papyrus.uml.nattable.generic.editor.GenericUMLNattableEditor;
+
+/**
+ * @author dumoulin
+ *
+ */
+public class CreateNattableEditorCommand extends AbstractCreateNattableEditorHandler {
+
+ /**
+ *
+ * Constructor.
+ *
+ */
+ public CreateNattableEditorCommand() {
+ super(GenericUMLNattableEditor.EDITOR_TYPE, GenericUMLNattableEditor.DEFAULT_NAME);
+ }
+
+}

Back to the top