1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-14 03:35:37 +02:00

bug 261976: Externalize strings

This commit is contained in:
Andrew Gvozdev 2012-03-17 06:39:04 -04:00
parent ac840daf1c
commit bb9be952d5
4 changed files with 9 additions and 5 deletions

View file

@ -16,6 +16,7 @@ import java.io.OutputStream;
import java.util.Properties;
import org.eclipse.cdt.internal.core.Cygwin;
import org.eclipse.cdt.internal.core.Messages;
import org.eclipse.cdt.internal.core.ProcessClosure;
import org.eclipse.cdt.utils.PathUtil;
import org.eclipse.cdt.utils.spawner.EnvironmentReader;
@ -25,6 +26,7 @@ import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.Platform;
import org.eclipse.osgi.util.NLS;
/**
* @noextend This class is not intended to be subclassed by clients.
@ -201,8 +203,8 @@ public class CommandLauncher implements ICommandLauncher {
envPathValue = System.getenv(PATH_ENV);
}
errorMessage = errorMessage + NEWLINE
+ "Error: Program \"" + command + "\" not found in PATH" + NEWLINE
+ "PATH=[" + envPathValue + "]" + NEWLINE;
+ NLS.bind(Messages.CommandLauncher_ProgramNotFoundInPath, command) + NEWLINE
+ "PATH=[" + envPathValue + "]" + NEWLINE; //$NON-NLS-1$ //$NON-NLS-2$
}
setErrorMessage(errorMessage);
fProcess = null;
@ -258,7 +260,7 @@ public class CommandLauncher implements ICommandLauncher {
if (monitor.isCanceled()) {
closure.terminate();
state = COMMAND_CANCELED;
setErrorMessage(CCorePlugin.getResourceString("CommandLauncher.error.commandCanceled")); //$NON-NLS-1$
setErrorMessage(Messages.CommandLauncher_CommandCancelled);
}
try {

View file

@ -26,8 +26,6 @@ CoreModel.PathEntry.DuplicateEntry= Duplicate path entries found ({0}), path: [{
CoreModel.PathEntry.NestedEntry= Nested path entries
CoreModel.PathEntry.InvalidPathEntry= Invalid path
CommandLauncher.error.commandCanceled=Command canceled
CCProjectNature.exception.noNature=Project must have a cnature
CCorePlugin.exception.noBinaryFormat=No Binary Format

View file

@ -16,6 +16,8 @@ public class Messages extends NLS {
private static final String BUNDLE_NAME = "org.eclipse.cdt.internal.core.messages"; //$NON-NLS-1$
public static String Util_unexpectedError;
public static String Addr_valueOutOfRange;
public static String CommandLauncher_CommandCancelled;
public static String CommandLauncher_ProgramNotFoundInPath;
public static String convention_illegalIdentifier;
public static String convention_invalid;
public static String convention_reservedKeyword;

View file

@ -47,6 +47,8 @@ convention_enum_invalidName= Enum name is invalid
Util_unexpectedError=Unexpected error
Addr_valueOutOfRange=Address is outside valid range.
CommandLauncher_CommandCancelled=Command canceled
CommandLauncher_ProgramNotFoundInPath=Error: Program "{0}" not found in PATH
XmlUtil_InternalErrorLoading=Internal error while trying to load XML document
XmlUtil_InternalErrorSerializing=Internal error while trying to serialize XML Document.