Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'examples/core')
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.classpath14
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.project56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/about.html56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/build.properties14
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.properties24
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.xml28
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.lifecycleevents/src/org/eclipse/papyrus/example/core/lifecycleevents/Activator.java100
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.classpath14
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.project56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/about.html56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/build.properties16
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.properties28
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.xml264
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/Activator.java154
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java180
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java188
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/TabTextEditor.java78
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.classpath14
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.project56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/about.html56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/build.properties16
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/plugin.xml56
-rw-r--r--examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/core/sashwindows/simpleeditor/Activator.java154
23 files changed, 839 insertions, 839 deletions
diff --git a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.classpath b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.classpath
index 2d1a4302f04..64c5e31b7a2 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.classpath
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.classpath
@@ -1,7 +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>
+<?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/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.project b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.project
index a165d6f55aa..2f4cccd69e8 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.project
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/.project
@@ -1,28 +1,28 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.example.core.lifecycleevents</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>
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.papyrus.example.core.lifecycleevents</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/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/about.html b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/about.html
index 82d49bf5f81..d35d5aed64c 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/about.html
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/about.html
@@ -1,28 +1,28 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June 5, 2007</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was
-provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+
+<p>June 5, 2007</p>
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content. Check the Redistributor's license that was
+provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
diff --git a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/build.properties b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/build.properties
index c659c55e85e..ae22b3b40a0 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/build.properties
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/build.properties
@@ -1,7 +1,7 @@
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- about.html,\
- plugin.properties,\
- plugin.xml
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+ .,\
+ about.html,\
+ plugin.properties,\
+ plugin.xml
diff --git a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.properties b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.properties
index 92fb944ece9..8639dfa7d41 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.properties
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.properties
@@ -1,12 +1,12 @@
-#################################################################################
-# Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
-##################################################################################
-pluginName=Papyrus Editor Life Cycle Example
-providerName=Eclipse Modeling Project
+#################################################################################
+# Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+##################################################################################
+pluginName=Papyrus Editor Life Cycle Example
+providerName=Eclipse Modeling Project
diff --git a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.xml b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.xml
index 440f62d150d..b443b5e486d 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.xml
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/plugin.xml
@@ -1,14 +1,14 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
- <extension
- point="org.eclipse.papyrus.infra.core.service">
- <service
- classname="org.eclipse.papyrus.example.core.lifecycleevents.LifeCycleEventsMonitorService"
- priority="1"
- startKind="startup"
- useClassTypeAsKey="true">
- </service>
- </extension>
-
-</plugin>
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+ <extension
+ point="org.eclipse.papyrus.infra.core.service">
+ <service
+ classname="org.eclipse.papyrus.example.core.lifecycleevents.LifeCycleEventsMonitorService"
+ priority="1"
+ startKind="startup"
+ useClassTypeAsKey="true">
+ </service>
+ </extension>
+
+</plugin>
diff --git a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/src/org/eclipse/papyrus/example/core/lifecycleevents/Activator.java b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/src/org/eclipse/papyrus/example/core/lifecycleevents/Activator.java
index 609e586337e..797fe9ddc7f 100644
--- a/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/src/org/eclipse/papyrus/example/core/lifecycleevents/Activator.java
+++ b/examples/core/org.eclipse.papyrus.example.core.lifecycleevents/src/org/eclipse/papyrus/example/core/lifecycleevents/Activator.java
@@ -1,50 +1,50 @@
-package org.eclipse.papyrus.example.core.lifecycleevents;
-
-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.example.core.lifecycleevents";
-
- // 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;
- }
-
-}
+package org.eclipse.papyrus.example.core.lifecycleevents;
+
+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.example.core.lifecycleevents";
+
+ // 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/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.classpath b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.classpath
index 2d1a4302f04..64c5e31b7a2 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.classpath
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.classpath
@@ -1,7 +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>
+<?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/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.project b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.project
index b58a111b857..1f85d50b3ec 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.project
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/.project
@@ -1,28 +1,28 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.example.core.sashwindows.fulleditor</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>
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.papyrus.example.core.sashwindows.fulleditor</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/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/about.html b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/about.html
index 82d49bf5f81..d35d5aed64c 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/about.html
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/about.html
@@ -1,28 +1,28 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June 5, 2007</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was
-provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+
+<p>June 5, 2007</p>
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content. Check the Redistributor's license that was
+provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/build.properties b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/build.properties
index d4e63335e69..74f4c7d7af6 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/build.properties
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/build.properties
@@ -1,8 +1,8 @@
-source.. = src/
-output.. = bin/
-bin.includes = plugin.xml,\
- META-INF/,\
- .,\
- icons/,\
- about.html,\
- plugin.properties
+source.. = src/
+output.. = bin/
+bin.includes = plugin.xml,\
+ META-INF/,\
+ .,\
+ icons/,\
+ about.html,\
+ plugin.properties
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.properties b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.properties
index 3f6aa859af3..0797e9ffbde 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.properties
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.properties
@@ -1,14 +1,14 @@
-#################################################################################
-# Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
-##################################################################################
-pluginName=Papyrus sashwindows full editor example
-providerName=Eclipse Modeling Project
-
-wizardSash= Sash Windows Full Editor
+#################################################################################
+# Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+##################################################################################
+pluginName=Papyrus sashwindows full editor example
+providerName=Eclipse Modeling Project
+
+wizardSash= Sash Windows Full Editor
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.xml b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.xml
index e8baf5a9809..d4ed4311242 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.xml
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/plugin.xml
@@ -1,132 +1,132 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
-
- <extension
- point="org.eclipse.ui.editors">
- <editor
- name="Sash Windows Full Editor"
- extensions="fullEditor"
- icon="icons/sample.gif"
- contributorClass="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditorContributor"
- class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditor"
- id="org.eclipse.papyrus.example.sashwindows.FullEditor">
- </editor>
- <editor
- class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.DiMultiTextEditor"
- contributorClass="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditorContributor"
- extensions="fullEditor"
- icon="icons/sample.gif"
- id="org.eclipse.papyrus.example.sashwindows.DiFullEditor"
- name="Sash Windows Full Editor (Di ContentProvider)">
- </editor>
- </extension>
- <extension
- point="org.eclipse.ui.newWizards">
- <!-- @generated NOT -->
- <wizard
- name="%wizardSash"
- icon="icons/sample.gif"
- category="org.eclipse.papyrus.wizards.category/org.eclipse.papyrus.examples"
- class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.wizards.MultiTextNewWizard"
- id="org.eclipse.papyrus.example.sashwindows.wizards.FullEditor">
- </wizard>
- </extension>
- <extension
- point="org.eclipse.ui.menus">
- <menuContribution
- locationURI="popup:org.eclipse.papyrus.dev.ui.menu">
- <menu
- id="org.eclipse.example.multitext.ui.menu"
- label="Sash Windows Full Editor">
- <menu
- id="org.eclipse.example.multitext.ui.menu.create"
- label="Create Tab">
- <command
- commandId="org.eclipse.example.multitext.ui.command.createTestEditor"
- icon="icons/TextEditor.gif"
- label="Create New Text Editor"
- style="push">
- </command>
- <command
- commandId="org.eclipse.example.multitext.ui.command.createMsgControl"
- icon="icons/MsgTab.gif"
- label="Create Msg Tab"
- style="push">
- </command>
- </menu>
- </menu>
- </menuContribution>
- <menuContribution
- locationURI="toolbar:org.eclipse.ui.main.toolbar">
- <toolbar
- id="org.eclipse.example.multitext.ui.toolbar">
- <command
- commandId="org.eclipse.example.multitext.ui.command.createTestEditor"
- icon="icons/TextEditor.gif"
- style="push">
- </command>
- <command
- commandId="org.eclipse.example.multitext.ui.command.createMsgControl"
- icon="icons/MsgTab.gif"
- style="push">
- </command>
- </toolbar>
- </menuContribution>
- </extension>
- <extension
- point="org.eclipse.ui.commands">
- <command
- id="org.eclipse.example.multitext.ui.command.createTestEditor"
- name="Create New Text Editor">
- </command>
- <command
- id="org.eclipse.example.multitext.ui.command.createMsgControl"
- name="Create Msg Tab">
- </command>
- </extension>
- <extension
- point="org.eclipse.ui.handlers">
- <handler
- class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor.CreateTextEditorCommandHandler"
- commandId="org.eclipse.example.multitext.ui.command.createTestEditor">
- <activeWhen>
- <or>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.example.sashwindows.FullEditor">
- </equals>
- </with>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.example.sashwindows.DiFullEditor">
- </equals>
- </with>
- </or>
- </activeWhen>
- </handler>
- <handler
- class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.msgpage.CreateMessageCommandHandler"
- commandId="org.eclipse.example.multitext.ui.command.createMsgControl">
- <activeWhen>
- <or>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.example.sashwindows.FullEditor">
- </equals>
- </with>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.example.sashwindows.DiFullEditor">
- </equals>
- </with>
- </or>
- </activeWhen>
- </handler>
- </extension>
-
-</plugin>
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.2"?>
+<plugin>
+
+ <extension
+ point="org.eclipse.ui.editors">
+ <editor
+ name="Sash Windows Full Editor"
+ extensions="fullEditor"
+ icon="icons/sample.gif"
+ contributorClass="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditorContributor"
+ class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditor"
+ id="org.eclipse.papyrus.example.sashwindows.FullEditor">
+ </editor>
+ <editor
+ class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.DiMultiTextEditor"
+ contributorClass="org.eclipse.papyrus.example.core.sashwindows.fulleditor.editor.MultiTextEditorContributor"
+ extensions="fullEditor"
+ icon="icons/sample.gif"
+ id="org.eclipse.papyrus.example.sashwindows.DiFullEditor"
+ name="Sash Windows Full Editor (Di ContentProvider)">
+ </editor>
+ </extension>
+ <extension
+ point="org.eclipse.ui.newWizards">
+ <!-- @generated NOT -->
+ <wizard
+ name="%wizardSash"
+ icon="icons/sample.gif"
+ category="org.eclipse.papyrus.wizards.category/org.eclipse.papyrus.examples"
+ class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.wizards.MultiTextNewWizard"
+ id="org.eclipse.papyrus.example.sashwindows.wizards.FullEditor">
+ </wizard>
+ </extension>
+ <extension
+ point="org.eclipse.ui.menus">
+ <menuContribution
+ locationURI="popup:org.eclipse.papyrus.dev.ui.menu">
+ <menu
+ id="org.eclipse.example.multitext.ui.menu"
+ label="Sash Windows Full Editor">
+ <menu
+ id="org.eclipse.example.multitext.ui.menu.create"
+ label="Create Tab">
+ <command
+ commandId="org.eclipse.example.multitext.ui.command.createTestEditor"
+ icon="icons/TextEditor.gif"
+ label="Create New Text Editor"
+ style="push">
+ </command>
+ <command
+ commandId="org.eclipse.example.multitext.ui.command.createMsgControl"
+ icon="icons/MsgTab.gif"
+ label="Create Msg Tab"
+ style="push">
+ </command>
+ </menu>
+ </menu>
+ </menuContribution>
+ <menuContribution
+ locationURI="toolbar:org.eclipse.ui.main.toolbar">
+ <toolbar
+ id="org.eclipse.example.multitext.ui.toolbar">
+ <command
+ commandId="org.eclipse.example.multitext.ui.command.createTestEditor"
+ icon="icons/TextEditor.gif"
+ style="push">
+ </command>
+ <command
+ commandId="org.eclipse.example.multitext.ui.command.createMsgControl"
+ icon="icons/MsgTab.gif"
+ style="push">
+ </command>
+ </toolbar>
+ </menuContribution>
+ </extension>
+ <extension
+ point="org.eclipse.ui.commands">
+ <command
+ id="org.eclipse.example.multitext.ui.command.createTestEditor"
+ name="Create New Text Editor">
+ </command>
+ <command
+ id="org.eclipse.example.multitext.ui.command.createMsgControl"
+ name="Create Msg Tab">
+ </command>
+ </extension>
+ <extension
+ point="org.eclipse.ui.handlers">
+ <handler
+ class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor.CreateTextEditorCommandHandler"
+ commandId="org.eclipse.example.multitext.ui.command.createTestEditor">
+ <activeWhen>
+ <or>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.example.sashwindows.FullEditor">
+ </equals>
+ </with>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.example.sashwindows.DiFullEditor">
+ </equals>
+ </with>
+ </or>
+ </activeWhen>
+ </handler>
+ <handler
+ class="org.eclipse.papyrus.example.core.sashwindows.fulleditor.msgpage.CreateMessageCommandHandler"
+ commandId="org.eclipse.example.multitext.ui.command.createMsgControl">
+ <activeWhen>
+ <or>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.example.sashwindows.FullEditor">
+ </equals>
+ </with>
+ <with
+ variable="activeEditorId">
+ <equals
+ value="org.eclipse.papyrus.example.sashwindows.DiFullEditor">
+ </equals>
+ </with>
+ </or>
+ </activeWhen>
+ </handler>
+ </extension>
+
+</plugin>
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/Activator.java b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/Activator.java
index a4abea49c3c..3ae91d6e1cf 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/Activator.java
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/Activator.java
@@ -1,77 +1,77 @@
-/*****************************************************************************
- * Copyright (c) 2009 CEA LIST & LIFL
- *
- *
- * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.example.core.sashwindows.fulleditor;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-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.example.core.sashwindows.fulleditor";
-
- // 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;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path
- *
- * @param path
- * the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return imageDescriptorFromPlugin(PLUGIN_ID, path);
- }
-}
+/*****************************************************************************
+ * Copyright (c) 2009 CEA LIST & LIFL
+ *
+ *
+ * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrus.example.core.sashwindows.fulleditor;
+
+import org.eclipse.jface.resource.ImageDescriptor;
+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.example.core.sashwindows.fulleditor";
+
+ // 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;
+ }
+
+ /**
+ * Returns an image descriptor for the image file at the given
+ * plug-in relative path
+ *
+ * @param path
+ * the path
+ * @return the image descriptor
+ */
+ public static ImageDescriptor getImageDescriptor(String path) {
+ return imageDescriptorFromPlugin(PLUGIN_ID, path);
+ }
+}
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java
index 769abe80d3f..1600e144b3c 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java
@@ -1,90 +1,90 @@
-/*****************************************************************************
- * Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.example.core.sashwindows.fulleditor.msgpage;
-
-import org.eclipse.core.commands.AbstractHandler;
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.commands.IHandler;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IComponentModel;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ISashWindowsContentProvider;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.MessageBox;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Command to create a new TextEditor.
- * The command create a new IEditorModel and add it to the Sashwindow repository model.
- *
- * @author dumoulin
- */
-public class CreateMessageCommandHandler extends AbstractHandler implements IHandler {
-
- /**
- * Method called when the command is invoked.
- */
- public Object execute(ExecutionEvent event) throws ExecutionException {
-
- // Create the Editor Model
- IComponentModel model = new MessagePartModel("Message !!!");
- // Get the Sashwindow model
- ISashWindowsContentProvider contentProvider = getSashWindowsContentProvider();
- if(contentProvider == null) {
- showErrorDialog("Can't create Editor. Reason: Can't get current editor ContentProvider.");
- }
- // Add it to the current folder
- contentProvider.addPage(model);
- return null;
- }
-
-
- /**
- * Show an ErrorDialog.
- *
- * @param string
- */
- private void showErrorDialog(String text) {
- MessageBox dialog = new MessageBox(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.ICON_WARNING | SWT.OK | SWT.APPLICATION_MODAL);
- dialog.setText(text);
- dialog.open();
- return;
- }
-
-
- /**
- * Get the current MultiDiagramEditor.
- *
- * @return
- */
- protected IEditorPart getMultiDiagramEditor() {
- IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
- IEditorPart editorPart = page.getActiveEditor();
- return editorPart;
- }
-
- /**
- * Get the shared object.
- *
- * @return
- */
- protected ISashWindowsContentProvider getSashWindowsContentProvider() {
- IEditorPart editor = getMultiDiagramEditor();
-
- ISashWindowsContentProvider contentProvider = (ISashWindowsContentProvider)editor.getAdapter(ISashWindowsContentProvider.class);
- return contentProvider;
- }
-
-}
+/*****************************************************************************
+ * Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrus.example.core.sashwindows.fulleditor.msgpage;
+
+import org.eclipse.core.commands.AbstractHandler;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.commands.IHandler;
+import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IComponentModel;
+import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ISashWindowsContentProvider;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.MessageBox;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * Command to create a new TextEditor.
+ * The command create a new IEditorModel and add it to the Sashwindow repository model.
+ *
+ * @author dumoulin
+ */
+public class CreateMessageCommandHandler extends AbstractHandler implements IHandler {
+
+ /**
+ * Method called when the command is invoked.
+ */
+ public Object execute(ExecutionEvent event) throws ExecutionException {
+
+ // Create the Editor Model
+ IComponentModel model = new MessagePartModel("Message !!!");
+ // Get the Sashwindow model
+ ISashWindowsContentProvider contentProvider = getSashWindowsContentProvider();
+ if(contentProvider == null) {
+ showErrorDialog("Can't create Editor. Reason: Can't get current editor ContentProvider.");
+ }
+ // Add it to the current folder
+ contentProvider.addPage(model);
+ return null;
+ }
+
+
+ /**
+ * Show an ErrorDialog.
+ *
+ * @param string
+ */
+ private void showErrorDialog(String text) {
+ MessageBox dialog = new MessageBox(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.ICON_WARNING | SWT.OK | SWT.APPLICATION_MODAL);
+ dialog.setText(text);
+ dialog.open();
+ return;
+ }
+
+
+ /**
+ * Get the current MultiDiagramEditor.
+ *
+ * @return
+ */
+ protected IEditorPart getMultiDiagramEditor() {
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ IEditorPart editorPart = page.getActiveEditor();
+ return editorPart;
+ }
+
+ /**
+ * Get the shared object.
+ *
+ * @return
+ */
+ protected ISashWindowsContentProvider getSashWindowsContentProvider() {
+ IEditorPart editor = getMultiDiagramEditor();
+
+ ISashWindowsContentProvider contentProvider = (ISashWindowsContentProvider)editor.getAdapter(ISashWindowsContentProvider.class);
+ return contentProvider;
+ }
+
+}
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java
index b308d2719ff..ee13a0860ee 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java
@@ -1,94 +1,94 @@
-/*****************************************************************************
- * Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor;
-
-import org.eclipse.core.commands.AbstractHandler;
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.commands.IHandler;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IEditorModel;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ISashWindowsContentProvider;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.MessageBox;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.handlers.HandlerUtil;
-
-/**
- * Command to create a new TextEditor.
- * The command create a new IEditorModel and add it to the Sashwindow repository model.
- *
- * @author dumoulin
- */
-public class CreateTextEditorCommandHandler extends AbstractHandler implements IHandler {
-
- /**
- * Method called when the command is invoked.
- */
- public Object execute(ExecutionEvent event) throws ExecutionException {
-
- // Create the Editor Model
- IEditorModel model = new TextEditorPartModel();
- // Get the Sashwindow model
- ISashWindowsContentProvider contentProvider = getSashWindowsContentProvider(event);
- if(contentProvider == null) {
- showErrorDialog("Can't create Editor. Reason: Can't get current editor ContentProvider.");
- }
- // Add it to the current folder
- contentProvider.addPage(model);
- return null;
- }
-
-
- /**
- * Show an ErrorDialog.
- *
- * @param string
- */
- private void showErrorDialog(String text) {
- MessageBox dialog = new MessageBox(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.ICON_WARNING | SWT.OK | SWT.APPLICATION_MODAL);
- dialog.setText(text);
- dialog.open();
- return;
- }
-
-
- /**
- * Get the current MultiDiagramEditor.
- *
- * @return
- */
- protected IEditorPart getMultiDiagramEditor() {
- IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
- IEditorPart editorPart = page.getActiveEditor();
- return editorPart;
- }
-
- /**
- * Get the shared object.
- * @param event
- *
- * @return
- * @throws ExecutionException
- */
- protected ISashWindowsContentProvider getSashWindowsContentProvider(ExecutionEvent event) throws ExecutionException {
- IEditorPart editor = HandlerUtil.getActiveEditorChecked(event);
-// IEditorPart editor = getMultiDiagramEditor();
-
- ISashWindowsContentProvider contentProvider = (ISashWindowsContentProvider)editor.getAdapter(ISashWindowsContentProvider.class);
- return contentProvider;
- }
-
-}
+/*****************************************************************************
+ * Copyright (c) 2008 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor;
+
+import org.eclipse.core.commands.AbstractHandler;
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.commands.IHandler;
+import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IEditorModel;
+import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ISashWindowsContentProvider;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.MessageBox;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.handlers.HandlerUtil;
+
+/**
+ * Command to create a new TextEditor.
+ * The command create a new IEditorModel and add it to the Sashwindow repository model.
+ *
+ * @author dumoulin
+ */
+public class CreateTextEditorCommandHandler extends AbstractHandler implements IHandler {
+
+ /**
+ * Method called when the command is invoked.
+ */
+ public Object execute(ExecutionEvent event) throws ExecutionException {
+
+ // Create the Editor Model
+ IEditorModel model = new TextEditorPartModel();
+ // Get the Sashwindow model
+ ISashWindowsContentProvider contentProvider = getSashWindowsContentProvider(event);
+ if(contentProvider == null) {
+ showErrorDialog("Can't create Editor. Reason: Can't get current editor ContentProvider.");
+ }
+ // Add it to the current folder
+ contentProvider.addPage(model);
+ return null;
+ }
+
+
+ /**
+ * Show an ErrorDialog.
+ *
+ * @param string
+ */
+ private void showErrorDialog(String text) {
+ MessageBox dialog = new MessageBox(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.ICON_WARNING | SWT.OK | SWT.APPLICATION_MODAL);
+ dialog.setText(text);
+ dialog.open();
+ return;
+ }
+
+
+ /**
+ * Get the current MultiDiagramEditor.
+ *
+ * @return
+ */
+ protected IEditorPart getMultiDiagramEditor() {
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ IEditorPart editorPart = page.getActiveEditor();
+ return editorPart;
+ }
+
+ /**
+ * Get the shared object.
+ * @param event
+ *
+ * @return
+ * @throws ExecutionException
+ */
+ protected ISashWindowsContentProvider getSashWindowsContentProvider(ExecutionEvent event) throws ExecutionException {
+ IEditorPart editor = HandlerUtil.getActiveEditorChecked(event);
+// IEditorPart editor = getMultiDiagramEditor();
+
+ ISashWindowsContentProvider contentProvider = (ISashWindowsContentProvider)editor.getAdapter(ISashWindowsContentProvider.class);
+ return contentProvider;
+ }
+
+}
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/TabTextEditor.java b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/TabTextEditor.java
index 838efb0a1af..865bcb52486 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/TabTextEditor.java
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.fulleditor/src/org/eclipse/papyrus/example/core/sashwindows/fulleditor/texteditor/TabTextEditor.java
@@ -1,39 +1,39 @@
-/*****************************************************************************
- * Copyright (c) 2009 CEA LIST & LIFL
- *
- *
- * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor;
-
-import org.eclipse.ui.editors.text.TextEditor;
-
-
-/**
- * A TextEditor that can be used as Tab of a sashes window.
- *
- * @author dumoulin
- */
-public class TabTextEditor extends TextEditor {
-
- /**
- *
- */
- public TabTextEditor() {
- }
-
- /**
- * Set the name of this part. {@inheritDoc}
- */
- @Override
- public void setPartName(String partName) {
- super.setPartName(partName);
- }
-}
+/*****************************************************************************
+ * Copyright (c) 2009 CEA LIST & LIFL
+ *
+ *
+ * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrus.example.core.sashwindows.fulleditor.texteditor;
+
+import org.eclipse.ui.editors.text.TextEditor;
+
+
+/**
+ * A TextEditor that can be used as Tab of a sashes window.
+ *
+ * @author dumoulin
+ */
+public class TabTextEditor extends TextEditor {
+
+ /**
+ *
+ */
+ public TabTextEditor() {
+ }
+
+ /**
+ * Set the name of this part. {@inheritDoc}
+ */
+ @Override
+ public void setPartName(String partName) {
+ super.setPartName(partName);
+ }
+}
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.classpath b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.classpath
index 2d1a4302f04..64c5e31b7a2 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.classpath
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.classpath
@@ -1,7 +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>
+<?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/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.project b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.project
index b1297849328..246ddd7a0ee 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.project
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/.project
@@ -1,28 +1,28 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.example.core.sashwindows.simpleeditor</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>
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.papyrus.example.core.sashwindows.simpleeditor</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/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/about.html b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/about.html
index 82d49bf5f81..d35d5aed64c 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/about.html
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/about.html
@@ -1,28 +1,28 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June 5, 2007</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was
-provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+
+<p>June 5, 2007</p>
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content. Check the Redistributor's license that was
+provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/build.properties b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/build.properties
index d4e63335e69..74f4c7d7af6 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/build.properties
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/build.properties
@@ -1,8 +1,8 @@
-source.. = src/
-output.. = bin/
-bin.includes = plugin.xml,\
- META-INF/,\
- .,\
- icons/,\
- about.html,\
- plugin.properties
+source.. = src/
+output.. = bin/
+bin.includes = plugin.xml,\
+ META-INF/,\
+ .,\
+ icons/,\
+ about.html,\
+ plugin.properties
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/plugin.xml b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/plugin.xml
index 6005740a446..16f8aa4ab65 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/plugin.xml
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/plugin.xml
@@ -1,28 +1,28 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
-
- <extension
- point="org.eclipse.ui.editors">
- <editor
- name="Sash Windows Simple Editor"
- extensions="simpleEditor"
- icon="icons/sample.gif"
- contributorClass="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.editors.MultiPageEditorContributor"
- class="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.editors.SimpleTextMultiPageEditor"
- id="org.eclipse.papyrus.example.sashwindows.SimpleEditor">
- </editor>
- </extension>
- <extension
- point="org.eclipse.ui.newWizards">
- <!-- @generated NOT -->
- <wizard
- name="%wizardSash"
- icon="icons/sample.gif"
- category="org.eclipse.papyrus.wizards.category/org.eclipse.papyrus.examples"
- class="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.wizards.MultiPageEditorNewWizard"
- id="org.eclipse.papyrus.example.sashwindows.wizards.SimpleEditor">
- </wizard>
- </extension>
-
-</plugin>
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.2"?>
+<plugin>
+
+ <extension
+ point="org.eclipse.ui.editors">
+ <editor
+ name="Sash Windows Simple Editor"
+ extensions="simpleEditor"
+ icon="icons/sample.gif"
+ contributorClass="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.editors.MultiPageEditorContributor"
+ class="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.editors.SimpleTextMultiPageEditor"
+ id="org.eclipse.papyrus.example.sashwindows.SimpleEditor">
+ </editor>
+ </extension>
+ <extension
+ point="org.eclipse.ui.newWizards">
+ <!-- @generated NOT -->
+ <wizard
+ name="%wizardSash"
+ icon="icons/sample.gif"
+ category="org.eclipse.papyrus.wizards.category/org.eclipse.papyrus.examples"
+ class="org.eclipse.papyrus.example.core.sashwindows.simpleeditor.wizards.MultiPageEditorNewWizard"
+ id="org.eclipse.papyrus.example.sashwindows.wizards.SimpleEditor">
+ </wizard>
+ </extension>
+
+</plugin>
diff --git a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/core/sashwindows/simpleeditor/Activator.java b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/core/sashwindows/simpleeditor/Activator.java
index 98db081c499..d15f10bdd04 100644
--- a/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/core/sashwindows/simpleeditor/Activator.java
+++ b/examples/core/org.eclipse.papyrus.example.core.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/core/sashwindows/simpleeditor/Activator.java
@@ -1,77 +1,77 @@
-/*****************************************************************************
- * Copyright (c) 2009 CEA LIST & LIFL
- *
- *
- * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.example.core.sashwindows.simpleeditor;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-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.example.core.sashwindows.simpleeditor";
-
- // 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;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path
- *
- * @param path
- * the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return imageDescriptorFromPlugin(PLUGIN_ID, path);
- }
-}
+/*****************************************************************************
+ * Copyright (c) 2009 CEA LIST & LIFL
+ *
+ *
+ * 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 Cedric.dumoulin@lifl.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+package org.eclipse.papyrus.example.core.sashwindows.simpleeditor;
+
+import org.eclipse.jface.resource.ImageDescriptor;
+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.example.core.sashwindows.simpleeditor";
+
+ // 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;
+ }
+
+ /**
+ * Returns an image descriptor for the image file at the given
+ * plug-in relative path
+ *
+ * @param path
+ * the path
+ * @return the image descriptor
+ */
+ public static ImageDescriptor getImageDescriptor(String path) {
+ return imageDescriptorFromPlugin(PLUGIN_ID, path);
+ }
+}

Back to the top