Question

I'm making a simple extra java app launcher for Eclipse 3.2 (JBuilder 2007-8) for internal use.

So I looked up all the documentations related, including this one The Launching Framework from eclipse.org and have managed to make everything else working with the exception of the launch shortcut.

alt text

This is the part of my plugin.xml.

   <extension
     point="org.eclipse.debug.ui.launchShortcuts">
  <shortcut
        category="mycompany.javalaunchext.launchConfig"
        class="mycompany.javalaunchext.LaunchShortcut"
        description="launchshortcutsdescription"
        icon="icons/k2mountain.png"
        id="mycompany.javalaunchext.launchShortcut"
        label="Java Application Ext."
        modes="run, debug">
     <perspective
           id="org.eclipse.jdt.ui.JavaPerspective">
     </perspective>
     <perspective
           id="org.eclipse.jdt.ui.JavaHierarchyPerspective">
     </perspective>
     <perspective
           id="org.eclipse.jdt.ui.JavaBrowsingPerspective">
     </perspective>
     <perspective
           id="org.eclipse.debug.ui.DebugPerspective">
     </perspective>
  </shortcut>

The configuration name in the category section is correct and the class in the class section, i believe, is correctly implemented. (basically copied from org.eclipse.jdt.debug.ui.launchConfigurations.JavaApplicationLaunchShortcut)


I'm really not sure if I'm supposed to write a follow-up here but let me clarify my question more. I've extended org.eclipse.jdt.debug.ui.launchConfigurations.JavaLaunchShortcut. Plus, I've added my own logger to constructors and methods, but the class seems like it's never even instantiating.

Was it helpful?

Solution

I had to add contextualLaunch under org.eclipse.debug.ui.launchShortcuts.

The old way seems like it's deprecated a long ago.

For other people who are working on the same subject, you might want to extend org.eclipse.ui.commands and bindings, too.

I cannot choose this answer but this is the answer that I (the questioner) was looking for.

OTHER TIPS

You class should implement ILaunchShortcut. Check out the Javadoc.

What exception are you getting? Check the error log.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top