mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Marked several strings as untranslatable and added the target build goal name to the converted project
This commit is contained in:
parent
5ba83e3c91
commit
00c80d0e7e
1 changed files with 8 additions and 7 deletions
|
@ -119,15 +119,15 @@ public class UpdateManagedProjectAction implements IWorkbenchWindowActionDelegat
|
||||||
Shell shell = ManagedBuilderUIPlugin.getDefault().getShell();
|
Shell shell = ManagedBuilderUIPlugin.getDefault().getShell();
|
||||||
boolean shouldUpdate = MessageDialog.openQuestion(shell,
|
boolean shouldUpdate = MessageDialog.openQuestion(shell,
|
||||||
ManagedBuilderUIPlugin.getResourceString("ManagedBuildConvert.12x.warning.title"), //$NON-NLS-1$
|
ManagedBuilderUIPlugin.getResourceString("ManagedBuildConvert.12x.warning.title"), //$NON-NLS-1$
|
||||||
ManagedBuilderUIPlugin.getFormattedString("ManagedBuildConvert.12x.warning.message", new String[]{project.getName()})); //$NON-NLS-1$
|
ManagedBuilderUIPlugin.getFormattedString("ManagedBuildConvert.12x.warning.message", project.getName())); //$NON-NLS-1$
|
||||||
if (shouldUpdate) {
|
if (shouldUpdate) {
|
||||||
backupFile.delete(true, monitor);
|
backupFile.delete(true, monitor);
|
||||||
} else {
|
} else {
|
||||||
monitor.setCanceled(true);
|
monitor.setCanceled(true);
|
||||||
throw new OperationCanceledException(ManagedBuilderUIPlugin.getFormattedString("ManagedBuildConvert.12x.cancelled.message", new String[]{project.getName()}));
|
throw new OperationCanceledException(ManagedBuilderUIPlugin.getFormattedString("ManagedBuildConvert.12x.cancelled.message", project.getName())); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
settingsFile.copy(backupFile.getFullPath(), true, monitor); //$NON-NLS-1$
|
settingsFile.copy(backupFile.getFullPath(), true, monitor);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected static void convertConfiguration(ITarget newTarget, ITarget newParent, Element oldConfig, IProgressMonitor monitor) {
|
protected static void convertConfiguration(ITarget newTarget, ITarget newParent, Element oldConfig, IProgressMonitor monitor) {
|
||||||
|
@ -167,7 +167,7 @@ public class UpdateManagedProjectAction implements IWorkbenchWindowActionDelegat
|
||||||
defId += ID_STATIC;
|
defId += ID_STATIC;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
defId += ID_SEPARATOR + (debug ? "debug" : "release");
|
defId += ID_SEPARATOR + (debug ? "debug" : "release"); //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
newParentConfig = newParent.getConfiguration(defId);
|
newParentConfig = newParent.getConfiguration(defId);
|
||||||
if (newParentConfig == null) {
|
if (newParentConfig == null) {
|
||||||
// Create a default gnu exe release or debug
|
// Create a default gnu exe release or debug
|
||||||
|
@ -364,6 +364,7 @@ public class UpdateManagedProjectAction implements IWorkbenchWindowActionDelegat
|
||||||
try {
|
try {
|
||||||
// Create a new target based on the new parent
|
// Create a new target based on the new parent
|
||||||
newTarget = ManagedBuildManager.createTarget(project, newParent);
|
newTarget = ManagedBuildManager.createTarget(project, newParent);
|
||||||
|
newTarget.setArtifactName(oldTarget.getAttribute(ITarget.ARTIFACT_NAME));
|
||||||
|
|
||||||
// Create new configurations
|
// Create new configurations
|
||||||
NodeList configNodes = oldTarget.getElementsByTagName(IConfiguration.CONFIGURATION_ELEMENT_NAME);
|
NodeList configNodes = oldTarget.getElementsByTagName(IConfiguration.CONFIGURATION_ELEMENT_NAME);
|
||||||
|
@ -405,7 +406,7 @@ public class UpdateManagedProjectAction implements IWorkbenchWindowActionDelegat
|
||||||
}
|
}
|
||||||
|
|
||||||
// Now complete the new tool id
|
// Now complete the new tool id
|
||||||
newToolId += ID_SEPARATOR + (cppFlag ? "cpp" : "c") + ID_SEPARATOR;
|
newToolId += ID_SEPARATOR + (cppFlag ? "cpp" : "c") + ID_SEPARATOR; //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
switch (toolType) {
|
switch (toolType) {
|
||||||
case TOOL_TYPE_COMPILER:
|
case TOOL_TYPE_COMPILER:
|
||||||
newToolId += TOOL_NAME_COMPILER;
|
newToolId += TOOL_NAME_COMPILER;
|
||||||
|
@ -563,7 +564,7 @@ public class UpdateManagedProjectAction implements IWorkbenchWindowActionDelegat
|
||||||
} catch (InvocationTargetException e) {
|
} catch (InvocationTargetException e) {
|
||||||
ManagedBuilderUIPlugin.logException(e,
|
ManagedBuilderUIPlugin.logException(e,
|
||||||
ManagedBuilderUIPlugin.getResourceString("ManagedBuilderStartup.update.exception.error"), //$NON-NLS-1$
|
ManagedBuilderUIPlugin.getResourceString("ManagedBuilderStartup.update.exception.error"), //$NON-NLS-1$
|
||||||
ManagedBuilderUIPlugin.getFormattedString("ManagedBuilderStartup.update.exception.message", new String[]{project.getName()})); //$NON-NLS-2$
|
ManagedBuilderUIPlugin.getFormattedString("ManagedBuilderStartup.update.exception.message", project.getName())); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue