From 8fea90aff68f27d366aa6005987597440ff3fe6e Mon Sep 17 00:00:00 2001 From: David Inglis Date: Tue, 18 May 2004 15:54:07 +0000 Subject: [PATCH] removed deprecated dependancy --- .../org/eclipse/cdt/internal/core/win32/ProcessList.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/core/org.eclipse.cdt.core.win32/src/org/eclipse/cdt/internal/core/win32/ProcessList.java b/core/org.eclipse.cdt.core.win32/src/org/eclipse/cdt/internal/core/win32/ProcessList.java index a3698f7e3d5..5bd890476d5 100644 --- a/core/org.eclipse.cdt.core.win32/src/org/eclipse/cdt/internal/core/win32/ProcessList.java +++ b/core/org.eclipse.cdt.core.win32/src/org/eclipse/cdt/internal/core/win32/ProcessList.java @@ -12,9 +12,9 @@ import org.eclipse.cdt.core.CCorePlugin; import org.eclipse.cdt.core.IProcessInfo; import org.eclipse.cdt.core.IProcessList; import org.eclipse.cdt.utils.spawner.ProcessFactory; -import org.eclipse.core.runtime.IPluginDescriptor; import org.eclipse.core.runtime.Path; import org.eclipse.core.runtime.Platform; +import org.osgi.framework.Bundle; /* * Currently this will only work for Windows XP since tasklist @@ -31,9 +31,10 @@ public class ProcessList implements IProcessList { Process p = null; String command = null; InputStream in = null; - IPluginDescriptor desc = CCorePlugin.getDefault().getDescriptor(); + Bundle bundle = Platform.getBundle(CCorePlugin.PLUGIN_ID); + try { - URL url = desc.find(new Path("$os$/listtasks.exe")); //$NON-NLS-1$ + URL url = Platform.find(bundle, new Path("$os$/listtasks.exe")); //$NON-NLS-1$ url = Platform.resolve(url); String path = url.getFile(); File file = new File(path);