1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-23 00:45:28 +02:00

Bug #112787 ManagedCommandLineGenerator not called to show Tool Settings.

Applied patch.
This commit is contained in:
Oleg Krasilnikov 2007-02-26 12:22:22 +00:00
parent f55428ec76
commit dc3905bfb1

View file

@ -17,6 +17,8 @@ import org.eclipse.cdt.core.settings.model.ICSettingBase;
import org.eclipse.cdt.managedbuilder.core.BuildException;
import org.eclipse.cdt.managedbuilder.core.IConfiguration;
import org.eclipse.cdt.managedbuilder.core.IHoldsOptions;
import org.eclipse.cdt.managedbuilder.core.IManagedCommandLineGenerator;
import org.eclipse.cdt.managedbuilder.core.IManagedCommandLineInfo;
import org.eclipse.cdt.managedbuilder.core.IOption;
import org.eclipse.cdt.managedbuilder.core.IOptionCategory;
import org.eclipse.cdt.managedbuilder.core.IResourceInfo;
@ -27,9 +29,9 @@ import org.eclipse.cdt.managedbuilder.internal.macros.BuildMacroProvider;
import org.eclipse.cdt.managedbuilder.internal.macros.BuildfileMacroSubstitutor;
import org.eclipse.cdt.utils.cdtvariables.SupplierBasedCdtVariableSubstitutor;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.ListenerList;
import org.eclipse.jface.preference.IPreferenceStore;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.core.runtime.ListenerList;
import org.eclipse.jface.util.PropertyChangeEvent;
public class ToolSettingsPrefStore implements IPreferenceStore {
@ -146,11 +148,17 @@ public class ToolSettingsPrefStore implements IPreferenceStore {
else if(ALL_OPTIONS_ID.equals(name)){
try {
SupplierBasedCdtVariableSubstitutor macroSubstitutor = new BuildfileMacroSubstitutor(null, EMPTY_STRING, " "); //$NON-NLS-1$
return listToString(((Tool)optCategory).getToolCommandFlags(
Tool tool = (Tool)optCategory;
String[] flags = tool.getToolCommandFlags(
null,
null,
macroSubstitutor,
obtainMacroProvider()));
macroSubstitutor,
obtainMacroProvider());
IManagedCommandLineGenerator cmdLGen = tool.getCommandLineGenerator();
IManagedCommandLineInfo cmdLInfo = cmdLGen.generateCommandLineInfo(tool,
EMPTY_STRING, flags, EMPTY_STRING, EMPTY_STRING, EMPTY_STRING,
null,tool.getCommandLinePattern());
return cmdLInfo.getFlags();
} catch (BuildException e) {}
}
} else {