diff options
author | cdumoulin | 2009-05-25 10:21:37 +0000 |
---|---|---|
committer | cdumoulin | 2009-05-25 10:21:37 +0000 |
commit | 6f01de1fe54b4dbbbe6b04336e8ec03724f06b17 (patch) | |
tree | 0a6e12fcee84a48952a4f0d869e8e7be50609b27 | |
parent | 14d2c55e421ef291e121cea4ff71124e011aba8f (diff) | |
download | org.eclipse.papyrus-6f01de1fe54b4dbbbe6b04336e8ec03724f06b17.tar.gz org.eclipse.papyrus-6f01de1fe54b4dbbbe6b04336e8ec03724f06b17.tar.xz org.eclipse.papyrus-6f01de1fe54b4dbbbe6b04336e8ec03724f06b17.zip |
NEW - bug 268775: [Sash Editor] Improve and finalize plugin
https://bugs.eclipse.org/bugs/show_bug.cgi?id=268775
Change compiler settings to jre1.5.
Remove bad @Override
12 files changed, 29 insertions, 54 deletions
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/.classpath b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/.classpath index 8a8f1668cdc..2d1a4302f04 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/.classpath +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/.classpath @@ -1,6 +1,6 @@ <?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/JavaSE-1.6"/>
+ <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"/>
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/plugin.xml b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/plugin.xml index c2bb10ffaca..90f6d0661fa 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/plugin.xml +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/plugin.xml @@ -5,26 +5,26 @@ <extension
point="org.eclipse.ui.editors">
<editor
- name="Sample Multi-Text Editor"
- extensions="mte"
+ name="Sash Windows Full Editor"
+ extensions="fullEditor"
icon="icons/sample.gif"
contributorClass="org.eclipse.papyrus.example.sashwindows.fulleditor.editor.MultiTextEditorContributor"
class="org.eclipse.papyrus.example.sashwindows.fulleditor.editor.MultiTextEditor"
- id="org.eclipse.example.multitext.editors.MultiTextEditor">
+ id="org.eclipse.papyrus.example.sashwindows.FullEditor">
</editor>
</extension>
<extension
point="org.eclipse.ui.newWizards">
<category
- name="Sample Wizards"
- id="org.eclipse.example.multitext.editor">
+ id="org.eclipse.papyrus.example.sashwindows"
+ name="Sash Windows Examples">
</category>
<wizard
- name="Multi-Text Editor file"
+ name="Sash Windows Full Editor"
icon="icons/sample.gif"
- category="org.eclipse.example.multitext.editor"
+ category="org.eclipse.papyrus.example.sashwindows"
class="org.eclipse.papyrus.example.sashwindows.fulleditor.wizards.MultiTextNewWizard"
- id="org.eclipse.example.multitext.wizards.MultiTextNewWizard">
+ id="org.eclipse.papyrus.example.sashwindows.wizards.FullEditor">
</wizard>
</extension>
<extension
@@ -33,7 +33,7 @@ locationURI="menu:org.eclipse.ui.main.menu?after=navigate">
<menu
id="org.eclipse.example.multitext.ui.menu"
- label="Multi Text Editor">
+ label="Sash Windows Full Editor">
<menu
id="org.eclipse.example.multitext.ui.menu.create"
label="Create Tab">
@@ -90,7 +90,7 @@ <with
variable="activeEditorId">
<equals
- value="org.eclipse.example.multitext.editors.MultiTextEditor">
+ value="org.eclipse.papyrus.example.sashwindows.FullEditor">
</equals>
</with>
</or>
@@ -104,7 +104,7 @@ <with
variable="activeEditorId">
<equals
- value="org.eclipse.example.multitext.editors.MultiTextEditor">
+ value="org.eclipse.papyrus.example.sashwindows.FullEditor">
</equals>
</with>
</or>
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/editor/MultiTextEditor.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/editor/MultiTextEditor.java index 2b3e1acc071..fabf9d1b45d 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/editor/MultiTextEditor.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/editor/MultiTextEditor.java @@ -63,7 +63,6 @@ public class MultiTextEditor extends /*MultiPageEditor */ AbstractMultiPageSashE */ private IPropertyListener dirtyPropertyListener = new IPropertyListener() { - @Override public void propertyChanged(Object source, int propId) { if(propId == PROP_DIRTY) isDirty = true; diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java index 6835b7523ef..3e63306f23e 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/CreateMessageCommandHandler.java @@ -35,7 +35,6 @@ public class CreateMessageCommandHandler extends AbstractHandler implements IHan /**
* Method called when the command is invoked.
*/
- @Override
public Object execute(ExecutionEvent event) throws ExecutionException {
// Create the Editor Model
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/MessagePartModel.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/MessagePartModel.java index 09dcf4b396e..147d4e02eda 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/MessagePartModel.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/msgpage/MessagePartModel.java @@ -41,7 +41,6 @@ public class MessagePartModel implements IComponentModel { * Return the control to be shown.
* {@inheritDoc}
*/
- @Override
public Composite createPartControl(Composite parent) {
Composite composite = new Composite(parent, SWT.NONE);
FillLayout layout = new FillLayout();
@@ -55,12 +54,10 @@ public class MessagePartModel implements IComponentModel { return composite;
}
- @Override
public Image getTabIcon() {
return null;
}
- @Override
public String getTabTitle() {
return title;
}
@@ -69,7 +66,6 @@ public class MessagePartModel implements IComponentModel { * Return this. In this implementation, the rawModel and the IEditorModel are the same.
*
*/
- @Override
public Object getRawModel() {
return this;
}
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java index 2e8b7aa9d70..653336bca03 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/CreateTextEditorCommandHandler.java @@ -35,7 +35,6 @@ public class CreateTextEditorCommandHandler extends AbstractHandler implements I /**
* Method called when the command is invoked.
*/
- @Override
public Object execute(ExecutionEvent event) throws ExecutionException {
// Create the Editor Model
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/TextEditorPartModel.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/TextEditorPartModel.java index f5f270c0ea3..1cf3f4b1c1b 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/TextEditorPartModel.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/texteditor/TextEditorPartModel.java @@ -48,7 +48,6 @@ public class TextEditorPartModel implements IEditorModel { title = "newText" + count++;
}
- @Override
public IEditorPart createIEditorPart() throws PartInitException {
editor = new TabTextEditor();
if (title == null)
@@ -56,12 +55,10 @@ public class TextEditorPartModel implements IEditorModel { return editor;
}
- @Override
public Image getTabIcon() {
return null;
}
- @Override
public String getTabTitle() {
return title;
}
@@ -70,7 +67,6 @@ public class TextEditorPartModel implements IEditorModel { * Return this. In this implementation, the rawModel and the IEditorModel are the same.
*
*/
- @Override
public Object getRawModel() {
return this;
}
@@ -79,7 +75,6 @@ public class TextEditorPartModel implements IEditorModel { * Return the ActionBarContributor dedicated to the created editor.
* Can return null if no particular ActionBarContributor is required.;
*/
- @Override
public EditorActionBarContributor getActionBarContributor() {
return null;
}
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/wizards/MultiTextNewWizardPage.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/wizards/MultiTextNewWizardPage.java index d91bca823ff..6481f6cd1d6 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/wizards/MultiTextNewWizardPage.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.fulleditor/src/org/eclipse/papyrus/example/sashwindows/fulleditor/wizards/MultiTextNewWizardPage.java @@ -40,8 +40,8 @@ public class MultiTextNewWizardPage extends WizardPage { */ public MultiTextNewWizardPage(ISelection selection) { super("wizardPage"); - setTitle("Multi-page Editor File"); - setDescription("This wizard creates a new file with *.mte extension that can be opened by a multi-page editor."); + setTitle("Sash Windows Full Editor File"); + setDescription("This wizard creates a new file with *.fullEditor extension that can be opened by a multi-page editor."); this.selection = selection; } @@ -109,7 +109,7 @@ public class MultiTextNewWizardPage extends WizardPage { containerText.setText(container.getFullPath().toString()); } } - fileText.setText("new_file.mte"); + fileText.setText("new_file.fullEditor"); } /** @@ -162,8 +162,8 @@ public class MultiTextNewWizardPage extends WizardPage { int dotLoc = fileName.lastIndexOf('.'); if (dotLoc != -1) { String ext = fileName.substring(dotLoc + 1); - if (ext.equalsIgnoreCase("mte") == false) { - updateStatus("File extension must be \"mte\""); + if (ext.equalsIgnoreCase("fullEditor") == false) { + updateStatus("File extension must be \"fullEditor\""); return; } } diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/.classpath b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/.classpath index 8a8f1668cdc..2d1a4302f04 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/.classpath +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/.classpath @@ -1,6 +1,6 @@ <?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/JavaSE-1.6"/>
+ <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"/>
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/plugin.xml b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/plugin.xml index 050b2b5523f..90e5c5596d0 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/plugin.xml +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/plugin.xml @@ -5,26 +5,26 @@ <extension
point="org.eclipse.ui.editors">
<editor
- name="Core Multi-page Editor"
- extensions="mpe"
+ name="Sash Windows Simple Editor"
+ extensions="simpleEditor"
icon="icons/sample.gif"
contributorClass="org.eclipse.papyrus.example.sashwindows.simpleeditor.editors.MultiPageEditorContributor"
class="org.eclipse.papyrus.example.sashwindows.simpleeditor.editors.SimpleTextMultiPageEditor"
- id="org.eclipse.papyrus.example.core.editors.MultiPageEditor">
+ id="org.eclipse.papyrus.example.sashwindows.SimpleEditor">
</editor>
</extension>
<extension
point="org.eclipse.ui.newWizards">
<category
- name="Core Editor Wizards"
- id="org.eclipse.papyrus.example.core">
+ name="Sash Windows Examples"
+ id="org.eclipse.papyrus.example.sashwindows">
</category>
<wizard
- name="Multi-page Editor file"
+ name="Sash Windows Simple Editor"
icon="icons/sample.gif"
- category="org.eclipse.papyrus.example.core"
+ category="org.eclipse.papyrus.example.sashwindows"
class="org.eclipse.papyrus.example.sashwindows.simpleeditor.wizards.MultiPageEditorNewWizard"
- id="org.eclipse.papyrus.example.core.wizards.MultiPageEditorNewWizard">
+ id="org.eclipse.papyrus.example.sashwindows.wizards.SimpleEditor">
</wizard>
</extension>
diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/editors/SimpleTextMultiPageEditor.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/editors/SimpleTextMultiPageEditor.java index ea2fc9a8be2..3e4e2005fee 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/editors/SimpleTextMultiPageEditor.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/editors/SimpleTextMultiPageEditor.java @@ -106,28 +106,23 @@ public class SimpleTextMultiPageEditor extends MultiPageEditor implements IResou */ public class Page0 implements IEditorModel { - @Override public IEditorPart createIEditorPart() throws PartInitException { editor = new TextEditor(); return editor; } - @Override public Image getTabIcon() { return null; } - @Override public String getTabTitle() { return editor.getTitle(); } - @Override public Object getRawModel() { return this; } - @Override public EditorActionBarContributor getActionBarContributor() { return null; } @@ -139,7 +134,6 @@ public class SimpleTextMultiPageEditor extends MultiPageEditor implements IResou */ public class Page1 implements IComponentModel { - @Override public Composite createPartControl(Composite parent) { Composite composite = new Composite(parent, SWT.NONE); GridLayout layout = new GridLayout(); @@ -161,17 +155,14 @@ public class SimpleTextMultiPageEditor extends MultiPageEditor implements IResou return composite; } - @Override public Image getTabIcon() { return null; } - @Override public String getTabTitle() { return "Properties"; } - @Override public Object getRawModel() { return this; } @@ -180,7 +171,6 @@ public class SimpleTextMultiPageEditor extends MultiPageEditor implements IResou public class Page2 implements IComponentModel { - @Override public Composite createPartControl(Composite parent) { Composite composite = new Composite(getContainer(), SWT.NONE); FillLayout layout = new FillLayout(); @@ -191,17 +181,14 @@ public class SimpleTextMultiPageEditor extends MultiPageEditor implements IResou return composite; } - @Override public Image getTabIcon() { return null; } - @Override public String getTabTitle() { return "Preview"; } - @Override public Object getRawModel() { return this; } diff --git a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/wizards/MultiPageEditorNewWizardPage.java b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/wizards/MultiPageEditorNewWizardPage.java index bdc524038c7..58d1a490378 100644 --- a/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/wizards/MultiPageEditorNewWizardPage.java +++ b/plugins/others/org.eclipse.papyrus.example.sashwindows.simpleeditor/src/org/eclipse/papyrus/example/sashwindows/simpleeditor/wizards/MultiPageEditorNewWizardPage.java @@ -122,7 +122,7 @@ public class MultiPageEditorNewWizardPage extends WizardPage { containerText.setText(container.getFullPath().toString()); } } - fileText.setText("new_file.mpe"); + fileText.setText("new_file.simpleEditor"); } /** @@ -175,8 +175,8 @@ public class MultiPageEditorNewWizardPage extends WizardPage { int dotLoc = fileName.lastIndexOf('.'); if (dotLoc != -1) { String ext = fileName.substring(dotLoc + 1); - if (ext.equalsIgnoreCase("mpe") == false) { - updateStatus("File extension must be \"mpe\""); + if (ext.equalsIgnoreCase("simpleEditor") == false) { + updateStatus("File extension must be \"simpleEditor\""); return; } } |