eclipse plugin: move all context menus in a dedicated group

eclipse plugin: add new dummy context menus
This commit is contained in:
Timotei Dolean 2010-05-27 19:15:18 +00:00
parent 7638525d89
commit 548712c03c
4 changed files with 111 additions and 8 deletions

View file

@ -29,19 +29,26 @@
adaptable="true"
objectClass="org.eclipse.core.resources.IProject"
nameFilter="*"
id="Wesnoth_Eclipse_Plugin.projectContributions">
id="plugin.projectContributions">
<action
class="wesnoth_eclipse_plugin.builder.ToggleNatureAction"
enablesFor="+"
icon="icons/wesnoth-icon_16.png"
id="actions.addRemoveNature"
label="Add/Remove Sample Nature"
menubarPath="additions">
menubarPath="_wesnoth">
</action>
<action
class="wesnoth_eclipse_plugin.action.WesnothProjectReport"
icon="icons/wesnoth-icon_16.png"
id="action.wesnothProjectReport"
label="Wesnoth project report"
menubarPath="_wesnoth">
</action>
</objectContribution>
<objectContribution
adaptable="true"
id="Wesnoth Eclipse Plugin.mapContributions"
id="plugin.mapContributions"
nameFilter="*maps*"
objectClass="org.eclipse.core.resources.IFolder">
<action
@ -50,12 +57,12 @@
icon="icons/wesnoth_editor-icon_16.png"
id="actions.importmap"
label="Import map"
menubarPath="additions">
menubarPath="_wesnoth">
</action>
</objectContribution>
<objectContribution
adaptable="false"
id="Wesnoth Eclipse Plugin.mapFilesContributions"
id="plugin.mapFilesContributions"
nameFilter="*.map"
objectClass="org.eclipse.core.resources.IFile">
<action
@ -64,12 +71,12 @@
icon="icons/wesnoth_editor-icon_16.png"
id="actions.openMapInEditor"
label="Open map in editor"
menubarPath="additions">
menubarPath="_wesnoth">
</action>
</objectContribution>
<objectContribution
adaptable="false"
id="Wesnoth Eclipse Plugin.configFilesContributions"
id="plugin.configFilesContributions"
nameFilter="*.cfg"
objectClass="org.eclipse.core.resources.IFile">
<action
@ -78,7 +85,28 @@
icon="icons/wesnoth-icon_16.png"
id="action.openScenarioInGame"
label="Open Scenario in game"
menubarPath="additions">
menubarPath="_wesnoth">
</action>
<menu
icon="icons/wesnoth-icon_16.png"
id="plugin.preprocessorMenu"
label="Preprocessor"
path="_wesnoth">
<groupMarker
name="preprocessorMenuMarker">
</groupMarker>
</menu>
<action
class="wesnoth_eclipse_plugin.action.ShowPreprocessedConfig"
id="action.preprocessedConfig"
label="Show preprocessed file"
menubarPath="plugin.preprocessorMenu/preprocessorMenuMarker">
</action>
<action
class="wesnoth_eclipse_plugin.action.ShowPlainPreprocessedConfig"
id="action.plainPreprocessedconfig"
label="Show plain preprocessed file"
menubarPath="plugin.preprocessorMenu/preprocessorMenuMarker">
</action>
</objectContribution>
</extension>

View file

@ -0,0 +1,25 @@
package wesnoth_eclipse_plugin.action;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.IObjectActionDelegate;
import org.eclipse.ui.IWorkbenchPart;
public class ShowPlainPreprocessedConfig implements IObjectActionDelegate
{
public ShowPlainPreprocessedConfig(){}
@Override
public void setActivePart(IAction action, IWorkbenchPart targetPart){
}
@Override
public void run(IAction action)
{
}
@Override
public void selectionChanged(IAction action, ISelection selection){
}
}

View file

@ -0,0 +1,25 @@
package wesnoth_eclipse_plugin.action;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.IObjectActionDelegate;
import org.eclipse.ui.IWorkbenchPart;
public class ShowPreprocessedConfig implements IObjectActionDelegate
{
public ShowPreprocessedConfig() { }
@Override
public void setActivePart(IAction action, IWorkbenchPart targetPart){
}
@Override
public void run(IAction action)
{
}
@Override
public void selectionChanged(IAction action, ISelection selection){
}
}

View file

@ -0,0 +1,25 @@
package wesnoth_eclipse_plugin.action;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.IObjectActionDelegate;
import org.eclipse.ui.IWorkbenchPart;
public class WesnothProjectReport implements IObjectActionDelegate
{
public WesnothProjectReport(){ }
@Override
public void setActivePart(IAction action, IWorkbenchPart targetPart){
}
@Override
public void run(IAction action)
{
}
@Override
public void selectionChanged(IAction action, ISelection selection){
}
}