fix global carbide debugger prefs read by using proper plugin id for which prefs were written
--- a/debuggercdi/com.nokia.cdt.debug.common/src/com/nokia/cdt/debug/common/internal/source/lookup/CarbideSourcePathComputerDelegate.java Fri Mar 12 12:26:03 2010 -0600
+++ b/debuggercdi/com.nokia.cdt.debug.common/src/com/nokia/cdt/debug/common/internal/source/lookup/CarbideSourcePathComputerDelegate.java Fri Mar 12 14:18:47 2010 -0600
@@ -27,6 +27,7 @@
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.Platform;
import org.eclipse.debug.core.ILaunchConfiguration;
import org.eclipse.debug.core.sourcelookup.ISourceContainer;
import org.eclipse.debug.core.sourcelookup.ISourcePathComputerDelegate;
@@ -40,7 +41,10 @@
public class CarbideSourcePathComputerDelegate implements ISourcePathComputerDelegate {
/** From legacy DE support. */
- public static final String PSC_FindSourceOutsideWorkspace = "com.freescale.cdt.debug.cw.PN_FindSourceOutsideWorkspace";
+ public static final String PSC_FindSourceOutsideWorkspace = "com.freescale.cdt.debug.cw.PN_FindSourceOutsideWorkspace"; // $//$NON-NLS-N$
+
+ /** Plugin ID to look up Carbide global debugger prefs */
+ public static final String CWPluginID = "com.freescale.cdt.debug.cw.core"; // $//$NON-NLS-N$
/**
* Constructor for CSourcePathComputerDelegate.
@@ -68,9 +72,10 @@
containers.add( 0, new ProjectSourceContainer( project, true ) );
}
}
- if (CarbideCommonDebuggerPlugin.getDefault().getPluginPreferences().getBoolean(
- PSC_FindSourceOutsideWorkspace))
+
+ if (Platform.getPreferencesService().getBoolean( CWPluginID, PSC_FindSourceOutsideWorkspace, false, null)){
containers.add( 0, new AbsolutePathSourceContainer() );
+ }
return (ISourceContainer[])containers.toArray( new ISourceContainer[containers.size()] );
}
}