1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-22 15:53:58 +02:00

Use the BootLoader.getOS() to find out about the OS

in the selection
This commit is contained in:
Alain Magloire 2003-12-17 16:42:28 +00:00
parent 01deaa0d8b
commit 62670bfc70

View file

@ -15,6 +15,7 @@ import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
import org.eclipse.cdt.launch.internal.ui.LaunchUIPlugin;
import org.eclipse.cdt.ui.CElementLabelProvider;
import org.eclipse.core.boot.BootLoader;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IAdaptable;
@ -111,9 +112,10 @@ public class CApplicationLaunchShortcut implements ILaunchShortcut {
ICDebugConfiguration debugConfig = null;
ICDebugConfiguration[] debugConfigs = CDebugCorePlugin.getDefault().getDebugConfigurations();
List debugList = new ArrayList(debugConfigs.length);
String os = BootLoader.getOS();
for (int i = 0; i < debugConfigs.length; i++) {
String platform = debugConfigs[i].getPlatform();
if (platform == null || platform.equals("native")) {
if (platform == null || platform.equals("native") || platform.equals(os)) {
debugList.add(debugConfigs[i]);
}
}