Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 33861 Details for
Bug 29580
[launch] Key bindings for launch configs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Sample patch
config-keys.patch (text/plain), 7.79 KB, created by
Darin Wright
on 2006-01-31 09:59:54 EST
(
hide
)
Description:
Sample patch
Filename:
MIME Type:
Creator:
Darin Wright
Created:
2006-01-31 09:59:54 EST
Size:
7.79 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.debug.ui >Index: plugin.xml >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.debug.ui/plugin.xml,v >retrieving revision 1.357 >diff -u -r1.357 plugin.xml >--- plugin.xml 16 Jan 2006 14:59:27 -0000 1.357 >+++ plugin.xml 31 Jan 2006 15:01:07 -0000 >@@ -2518,4 +2518,24 @@ > </wizard> > </extension> > >+<extension point="org.eclipse.ui.commands"> >+ <command >+ name="Launch Configuration" >+ description="Launches a launch configuration" >+ categoryId="org.eclipse.debug.ui.category.run" >+ id="org.eclipse.debug.ui.launchConfiguration" >+ defaultHandler="org.eclipse.debug.internal.ui.actions.LaunchConfigurationHanlder"> >+ <commandParameter >+ id="org.eclipse.debug.ui.actions.launchConfiguration.configHandle" >+ name="Configuration" >+ values="org.eclipse.debug.internal.ui.actions.LaunchConfigurationParameterValues" /> >+ <commandParameter >+ id="org.eclipse.debug.ui.actions.launchConfiguration.mode" >+ name="Mode" >+ optional="true" >+ values="org.eclipse.debug.internal.ui.actions.LaunchModeParameterValues"/> >+ </command> >+</extension> >+ >+ > </plugin> >\ No newline at end of file >Index: ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationParameterValues.java >=================================================================== >RCS file: ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationParameterValues.java >diff -N ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationParameterValues.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationParameterValues.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,50 @@ >+/******************************************************************************* >+ * Copyright (c) 2006 IBM Corporation and others. >+ * 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 >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+package org.eclipse.debug.internal.ui.actions; >+ >+import java.util.HashMap; >+import java.util.Map; >+ >+import org.eclipse.core.commands.IParameterValues; >+import org.eclipse.core.runtime.CoreException; >+import org.eclipse.debug.core.DebugPlugin; >+import org.eclipse.debug.core.ILaunchConfiguration; >+import org.eclipse.debug.internal.ui.DebugUIPlugin; >+import org.eclipse.debug.ui.DebugUITools; >+ >+/** >+ * Launch configuration parameter values for key binding support. >+ * >+ * @since 3.2 >+ * >+ */ >+public class LaunchConfigurationParameterValues implements IParameterValues { >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.core.commands.IParameterValues#getParameterValues() >+ */ >+ public Map getParameterValues() { >+ Map map = new HashMap(); >+ try { >+ ILaunchConfiguration[] configurations = DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurations(); >+ for (int i = 0; i < configurations.length; i++) { >+ ILaunchConfiguration configuration = configurations[i]; >+ if (!DebugUITools.isPrivate(configuration)) { >+ map.put(configuration.getName(), configuration.getMemento()); >+ } >+ } >+ } catch (CoreException e) { >+ DebugUIPlugin.log(e); >+ } >+ return map; >+ } >+ >+} >Index: ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationHanlder.java >=================================================================== >RCS file: ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationHanlder.java >diff -N ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationHanlder.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ ui/org/eclipse/debug/internal/ui/actions/LaunchConfigurationHanlder.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,43 @@ >+/******************************************************************************* >+ * Copyright (c) 2006 IBM Corporation and others. >+ * 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 >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+package org.eclipse.debug.internal.ui.actions; >+ >+import org.eclipse.core.commands.AbstractHandler; >+import org.eclipse.core.commands.ExecutionEvent; >+import org.eclipse.core.commands.ExecutionException; >+import org.eclipse.core.commands.IHandler; >+import org.eclipse.core.runtime.CoreException; >+import org.eclipse.debug.core.DebugPlugin; >+import org.eclipse.debug.core.ILaunchConfiguration; >+import org.eclipse.debug.ui.DebugUITools; >+ >+public class LaunchConfigurationHanlder extends AbstractHandler implements IHandler { >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent) >+ */ >+ public Object execute(ExecutionEvent event) throws ExecutionException { >+ String mode = event.getParameter("org.eclipse.debug.ui.actions.launchConfiguration.mode"); >+ String handle = event.getParameter("org.eclipse.debug.ui.actions.launchConfiguration.configHandle"); >+ if (mode != null && handle != null) { >+ try { >+ ILaunchConfiguration configuration = DebugPlugin.getDefault().getLaunchManager().getLaunchConfiguration(handle); >+ if (configuration.exists()) { >+ DebugUITools.launch(configuration, mode); >+ } >+ } catch (CoreException e) { >+ throw new ExecutionException(e.getStatus().getMessage(), e); >+ } >+ } >+ return null; >+ } >+ >+} >Index: ui/org/eclipse/debug/internal/ui/actions/LaunchModeParameterValues.java >=================================================================== >RCS file: ui/org/eclipse/debug/internal/ui/actions/LaunchModeParameterValues.java >diff -N ui/org/eclipse/debug/internal/ui/actions/LaunchModeParameterValues.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ ui/org/eclipse/debug/internal/ui/actions/LaunchModeParameterValues.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,43 @@ >+/******************************************************************************* >+ * Copyright (c) 2006 IBM Corporation and others. >+ * 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 >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+package org.eclipse.debug.internal.ui.actions; >+ >+import java.util.HashMap; >+import java.util.Map; >+ >+import org.eclipse.core.commands.IParameterValues; >+import org.eclipse.debug.core.DebugPlugin; >+import org.eclipse.debug.core.ILaunchMode; >+import org.eclipse.debug.internal.ui.DebugUIPlugin; >+ >+/** >+ * Launch mode parameter values for key binding support. >+ * >+ * @since 3.2 >+ */ >+public class LaunchModeParameterValues implements IParameterValues { >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.core.commands.IParameterValues#getParameterValues() >+ */ >+ public Map getParameterValues() { >+ Map map = new HashMap(); >+ ILaunchMode[] launchModes = DebugPlugin.getDefault().getLaunchManager().getLaunchModes(); >+ for (int i = 0; i < launchModes.length; i++) { >+ ILaunchMode mode = launchModes[i]; >+ String label = mode.getLabel(); >+ label = DebugUIPlugin.removeAccelerators(label); >+ map.put(label, mode.getIdentifier()); >+ } >+ return map; >+ } >+ >+}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 29580
: 33861 |
224934
|
275195