1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-03 07:05:24 +02:00

[244173] externalized strings in RemoteRunLaunchDelegate.

This commit is contained in:
Anna Dushistova 2008-09-25 09:13:52 +00:00
parent 6a534ee891
commit dcb459d97b
5 changed files with 46 additions and 17 deletions

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.rse.remotecdt;singleton:=true
Bundle-Version: 2.1.1.qualifier
Bundle-Version: 2.1.100.qualifier
Bundle-Activator: org.eclipse.rse.internal.remotecdt.Activator
Bundle-Localization: plugin
Require-Bundle: org.eclipse.rse.ui;bundle-version="[3.0.0,4.0.0)",

View file

@ -6,9 +6,10 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Martin Oberhuber (Wind River) - initial API and implementation
* Ewa Matejska (PalmSource) - [158783] browse button for cdt remote path
* Martin Oberhuber (Wind River) - initial API and implementation
* Ewa Matejska (PalmSource) - [158783] browse button for cdt remote path
* Johann Draschwandtner (Wind River) - [231827][remotecdt]Auto-compute default for Remote path
* Anna Dushistova (MontaVista) - [244173][remotecdt][nls] Externalize Strings in RemoteRunLaunchDelegate
*******************************************************************************/
package org.eclipse.rse.internal.remotecdt;
@ -40,13 +41,30 @@ public class Messages extends NLS {
public static String RemoteCMainTab_Properties_Location;
public static String RemoteCMainTab_Properties_Skip_default;
public static String RemoteRunLaunchDelegate_0;
public static String RemoteRunLaunchDelegate_RemoteShell;
public static String RemoteRunLaunchDelegate_1;
public static String RemoteRunLaunchDelegate_10;
public static String RemoteRunLaunchDelegate_11;
public static String RemoteRunLaunchDelegate_12;
public static String RemoteRunLaunchDelegate_13;
public static String RemoteRunLaunchDelegate_14;
public static String RemoteRunLaunchDelegate_2;
public static String RemoteRunLaunchDelegate_3;
public static String RemoteRunLaunchDelegate_4;
public static String RemoteRunLaunchDelegate_5;
public static String RemoteRunLaunchDelegate_6;
public static String RemoteRunLaunchDelegate_7;
public static String RemoteRunLaunchDelegate_8;
public static String RemoteRunLaunchDelegate_9;
static {
// initialize resource bundle

View file

@ -6,12 +6,13 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Ewa Matejska (PalmSource) - Adapted from LocalRunLaunchDelegate
* Ewa Matejska (PalmSource) - Adapted from LocalRunLaunchDelegate
* Martin Oberhuber (Wind River) - [186128] Move IProgressMonitor last in all API
* Martin Oberhuber (Wind River) - [186773] split ISystemRegistryUI from ISystemRegistry
* Martin Oberhuber (Wind River) - [226301][api] IShellService should throw SystemMessageException on error
* Anna Dushistova (MontaVista) - [234490][remotecdt] Launching with disconnected target fails
* Anna Dushistova (MontaVista) - [235298][remotecdt] Further improve progress reporting and cancellation of Remote CDT Launch
* Anna Dushistova (MontaVista) - [244173][remotecdt][nls] Externalize Strings in RemoteRunLaunchDelegate
*******************************************************************************/
@ -87,7 +88,7 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
if(mode.equals(ILaunchManager.DEBUG_MODE)){
monitor.beginTask("Launching", 100); //$NON-NLS-1$
monitor.beginTask(Messages.RemoteRunLaunchDelegate_0, 100);
setDefaultSourceLocator(launch, config);
String debugMode = config.getAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_START_MODE,
ICDTLaunchConfigurationConstants.DEBUGGER_MODE_RUN);
@ -96,11 +97,11 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
ICDISession dsession = null;
try {
// Download the binary to the remote before debugging.
monitor.setTaskName("Downloading"); //$NON-NLS-1$
monitor.setTaskName(Messages.RemoteRunLaunchDelegate_2);
remoteFileDownload(config, launch, exePath.toString(), remoteExePath, new SubProgressMonitor(monitor, 80));
// Automatically start up the gdbserver. In the future this should be expanded to launch
// an arbitrary remote damon.
// an arbitrary remote daemon.
String gdbserver_port_number = config.getAttribute(IRemoteConnectionConfigurationConstants.ATTR_GDBSERVER_PORT,
IRemoteConnectionConfigurationConstants.ATTR_GDBSERVER_PORT_DEFAULT);
String gdbserver_command = config.getAttribute(IRemoteConnectionConfigurationConstants.ATTR_GDBSERVER_COMMAND,
@ -109,7 +110,7 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
+ spaceEscapify(remoteExePath);
if(arguments != null && !arguments.equals("")) //$NON-NLS-1$
command_arguments += " " + arguments; //$NON-NLS-1$
monitor.setTaskName("Launching"); //$NON-NLS-1$
monitor.setTaskName(Messages.RemoteRunLaunchDelegate_9);
remoteShellProcess = remoteShellExec(config, gdbserver_command,
command_arguments, new SubProgressMonitor(monitor, 5));
DebugPlugin.newProcess(launch, remoteShellProcess, Messages.RemoteRunLaunchDelegate_RemoteShell);
@ -165,14 +166,14 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
}
} else if(mode.equals(ILaunchManager.RUN_MODE)) {
monitor.beginTask("Launching", 100); //$NON-NLS-1$
monitor.beginTask(Messages.RemoteRunLaunchDelegate_10, 100);
Process remoteProcess = null;
try {
// Download the binary to the remote before debugging.
monitor.setTaskName("Downloading"); //$NON-NLS-1$
monitor.setTaskName(Messages.RemoteRunLaunchDelegate_11);
remoteFileDownload(config, launch, exePath.toString(),remoteExePath, new SubProgressMonitor(monitor,80));
// Use a remote shell to launch the binary.
monitor.setTaskName("Launching"); //$NON-NLS-1$
monitor.setTaskName(Messages.RemoteRunLaunchDelegate_12);
remoteProcess = remoteShellExec(config, remoteExePath, arguments, new SubProgressMonitor(monitor,20));
DebugPlugin.newProcess(launch, remoteProcess, renderProcessLabel(exePath.toOSString()));
} catch (CoreException e) {
@ -207,7 +208,7 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
if(connections[i].getAliasName().equals(remoteConnection))
break;
if(i >= connections.length) {
abort("Could not find the remote connection.", null, ICDTLaunchConfigurationConstants.ERR_INTERNAL_ERROR); //$NON-NLS-1$
abort(Messages.RemoteRunLaunchDelegate_13, null, ICDTLaunchConfigurationConstants.ERR_INTERNAL_ERROR);
}
return connections[i];
}
@ -261,7 +262,7 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
if(skipDownload)
// Nothing to do. Download is skipped.
return null;
monitor.beginTask("Downloading remote file", 100); //$NON-NLS-1$
monitor.beginTask(Messages.RemoteRunLaunchDelegate_14, 100);
IFileService fileService = (IFileService) getConnectedRemoteService(config, FILE_SERVICE, new SubProgressMonitor(monitor, 10));
File file = new File(localExePath);
Path remotePath = new Path(remoteExePath);
@ -292,7 +293,7 @@ public class RemoteRunLaunchDelegate extends AbstractCLaunchDelegate {
// The exit command is called to force the remote shell to close after our command
// is executed. This is to prevent a running process at the end of the debug session.
// See Bug 158786.
monitor.beginTask("Executing "+ remoteCommandPath +" "+ arguments, 10);
monitor.beginTask(NLS.bind(Messages.RemoteRunLaunchDelegate_8, remoteCommandPath,arguments), 10);
String real_remote_command = arguments == null ? spaceEscapify(remoteCommandPath) :
spaceEscapify(remoteCommandPath) + " " + arguments; //$NON-NLS-1$
String remote_command = real_remote_command + CMD_DELIMITER + EXIT_CMD;

View file

@ -6,21 +6,31 @@
# http://www.eclipse.org/legal/epl-v10.html
#
# Contributors:
# Martin Oberhuber (Wind River) - externalized strings
# Ewa Matejska (PalmSource) - [158783] browse button for cdt remote path
# Martin Oberhuber (Wind River) - externalized strings
# Ewa Matejska (PalmSource) - [158783] browse button for cdt remote path
# Johann Draschwandtner (Wind River) - [231827][remotecdt]Auto-compute default for Remote path
# Anna Dushistova (MontaVista) - [244173][remotecdt][nls] Externalize Strings in RemoteRunLaunchDelegate
################################################################################
# NLS_MESSAGEFORMAT_VAR
# NLS_ENCODING=UTF-8
RemoteRunLaunchDelegate_0=Launching
RemoteRunLaunchDelegate_RemoteShell=Remote Shell
RemoteRunLaunchDelegate_1=Unidentified mode {0} passed to RemoteRunLaunchDelegate
RemoteRunLaunchDelegate_10=Launching
RemoteRunLaunchDelegate_11=Downloading
RemoteRunLaunchDelegate_12=Launching
RemoteRunLaunchDelegate_13=Could not find the remote connection.
RemoteRunLaunchDelegate_14=Downloading remote file
RemoteRunLaunchDelegate_2=Downloading
RemoteRunLaunchDelegate_3=Wrong service requested.
RemoteRunLaunchDelegate_4=No subsystem found.\n
RemoteRunLaunchDelegate_5=Could not connect to the remote system.
RemoteRunLaunchDelegate_6=Error during file upload.
RemoteRunLaunchDelegate_7=Could not create the hostShellProcess.\n
RemoteRunLaunchDelegate_8=Executing {0} {1}
RemoteRunLaunchDelegate_9=Launching
RemoteCMainTab_Program=Remote Absolute File Path for C/C++ Application:
RemoteCMainTab_SkipDownload=Skip download to target path.
Remote_GDB_Debugger_Options=Remote GDB Debugger Options

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.rse.remotecdt"
label="%featureName"
version="2.1.1.qualifier"
version="2.1.100.qualifier"
provider-name="%providerName"
plugin="org.eclipse.rse.remotecdt"
image="eclipse_update_120.jpg">