diff options
author | Michael Rennie | 2006-11-27 16:08:44 +0000 |
---|---|---|
committer | Michael Rennie | 2006-11-27 16:08:44 +0000 |
commit | ff7d1da075b2f1697077d5f9c40070d7a22e3c33 (patch) | |
tree | 2413de312024a9ecf5dff74a4c2f77711d4954c9 /org.eclipse.debug.ui/schema | |
parent | 3f516aedc7583bd29687835a846063a2495c4b22 (diff) | |
download | eclipse.platform.debug-ff7d1da075b2f1697077d5f9c40070d7a22e3c33.tar.gz eclipse.platform.debug-ff7d1da075b2f1697077d5f9c40070d7a22e3c33.tar.xz eclipse.platform.debug-ff7d1da075b2f1697077d5f9c40070d7a22e3c33.zip |
Bug 165855
Launch Shortcuts shows deprecated example.
Diffstat (limited to 'org.eclipse.debug.ui/schema')
-rw-r--r-- | org.eclipse.debug.ui/schema/launchShortcuts.exsd | 44 |
1 files changed, 31 insertions, 13 deletions
diff --git a/org.eclipse.debug.ui/schema/launchShortcuts.exsd b/org.eclipse.debug.ui/schema/launchShortcuts.exsd index 1fbe77145..42193a200 100644 --- a/org.eclipse.debug.ui/schema/launchShortcuts.exsd +++ b/org.eclipse.debug.ui/schema/launchShortcuts.exsd @@ -196,26 +196,44 @@ appears in the run and/or debug cascade menus to launch the workbench selection <meta.section type="examples"/> </appInfo> <documentation> - The following is an example of a launch shortcut extension point: + The following is an example of the Java Application launch shortcut contribution with an enablement expression: <p> <pre> <extension point="org.eclipse.debug.ui.launchShortcuts"> <shortcut - id="com.example.ExampleLaunchShortcutId" - modes="run,debug" - class="com.example.ExampleLaunchShortcutImpl" - label="Example Launch Shortcut" - icon="icons/examples.gif"> - <perspective id="org.eclipse.jdt.ui.JavaPerspective"/> - <perspective id="org.eclipse.debug.ui.DebugPerspective"/> - </shortcut> - </extension> + label="Java Application" + icon="$nl$/icons/full/etool16/java_app.gif" + helpContextId="org.eclipse.jdt.debug.ui.shortcut_local_java_application" + modes="run, debug" + class="org.eclipse.jdt.internal.debug.ui.launcher.JavaApplicationLaunchShortcut" + id="org.eclipse.jdt.debug.ui.localJavaShortcut"> + <contextualLaunch> + <enablement> + <with variable="selection"> + <count value="1"/> + <iterate> + <or> + <test property="org.eclipse.jdt.launching.hasMain"/> + <and> + <test property="org.eclipse.jdt.launching.isContainer"/> + <test property="org.eclipse.jdt.launching.hasProjectNature" args="org.eclipse.jdt.core.javanature"/> + </and> + </or> + </iterate> + </with> + </enablement> + </contextualLaunch> +</shortcut> </pre> </p> - +<p> In the above example, a launch shortcut will be shown in the run and debug cascade menus with the label -"Example Launch Shortcut", in the JavaPerspective and the DebugPerspective. +"Java Application". Furthermore, the shortcut will only appear if the selected item has a main method in it, or it is a Java project. +</p> +<p> +For more information on property testers see <code>org.eclipse.core.expressions.PropertyTester</code> +</p> </documentation> </annotation> @@ -255,7 +273,7 @@ Since 3.1, the debug platform registers a command handler for each launch shortc <meta.section type="copyright"/> </appInfo> <documentation> -Copyright (c) 2000, 2005 IBM Corporation and others.<br> + Copyright (c) 2000, 2005 IBM Corporation and others.<br> 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 |