Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add menu entry to "Run As"?

In Plugin Developpment Environnement of Eclipse, How ca i add an menu entry to "Run As" for a specific Editor?

like image 396
Imen Avatar asked Feb 23 '10 16:02

Imen


People also ask

How do you use the Run As option?

The easiest way to run an application under another user is to use the Windows File Explorer GUI. Just find an application (or a shortcut) you want to start, hold the Shift key, and right-click on it. Select Run as different user in the context menu.

How do I get to the Run menu?

Way 2: Add Run to Start menu using Cortana icon Click the Start button to choose ALL apps and navigate to Windows System. You will see the Run command under the Windows System. Then right-click Run to pick Pin to Start from the context menu.

Why is there no option to run as administrator?

If your computer's installation files are corrupted or missing, it can display various errors, including the “Run as Administrator” not working issue. To solve this, you can use a built-in tool in your Operating System called Windows SFC or System File Checker.


1 Answers

You can get some tips in the Eclipse article:

We Have Lift-off: The Launching Framework in Eclipse

Declaring a launch configuration type

The first step in creating our applet launcher is declaring a config type, as shown in the following snippet of XML from our plug-in's plugin.xml file:
Non-UI declaration

<extension point="org.eclipse.debug.core.launchConfigurationTypes">
    <launchConfigurationType
        name="Java Applet"
        delegate="org.eclipse.jdt.internal.launching.JavaAppletLaunchConfigurationDelegate"
        modes="run, debug"               
        id="org.eclipse.jdt.launching.javaApplet">        
    </launchConfigurationType>
</extension>

The most important part of this declaration is the delegate attribute which specifies the fully-qualified name of a class that implements the interface org.eclipse.debug.core.model.ILaunchConfigurationDelegate.
The delegate is the brains of the launcher, and implements the launch() method which launches a specified config.

like image 64
VonC Avatar answered Oct 26 '22 08:10

VonC