Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Vogel2020-01-13 09:03:18 +0000
committerLars Vogel2020-01-15 07:55:40 +0000
commitef601e2f25021d9b861b231dcb100738f7e1b989 (patch)
treecfd94d72bb979e430a445e41d600cbb5c634bff3 /org.eclipse.debug.ui/ui/org/eclipse
parentea1b2c82018821d079bce0fa0a103d7a8b8468ff (diff)
downloadeclipse.platform.debug-ef601e2f25021d9b861b231dcb100738f7e1b989.tar.gz
eclipse.platform.debug-ef601e2f25021d9b861b231dcb100738f7e1b989.tar.xz
eclipse.platform.debug-ef601e2f25021d9b861b231dcb100738f7e1b989.zip
Benefit of this way rather than System.getProperty("line.separator") is that there are no security checks. Change-Id: Ib14dc56626a541a2bace31952281cfbb6e0a9a00 Signed-off-by: Lars Vogel <Lars.Vogel@vogella.com>
Diffstat (limited to 'org.eclipse.debug.ui/ui/org/eclipse')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CopyTableRenderingToClipboardAction.java6
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/EnvironmentTab.java2
2 files changed, 4 insertions, 4 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CopyTableRenderingToClipboardAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CopyTableRenderingToClipboardAction.java
index 2ec3f8297..e500c7ff5 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CopyTableRenderingToClipboardAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CopyTableRenderingToClipboardAction.java
@@ -75,7 +75,7 @@ public class CopyTableRenderingToClipboardAction extends Action
// get title of view tab
String label = fRendering.getLabel();
tableContents.append(label);
- tableContents.append(System.getProperty("line.separator")); //$NON-NLS-1$
+ tableContents.append(System.lineSeparator());
tableContents.append(COLUMN_SEPERATOR);
int charsPerByte = fRendering.getNumCharsPerByte();
@@ -135,7 +135,7 @@ public class CopyTableRenderingToClipboardAction extends Action
tableContents.append(COLUMN_SEPERATOR);
}
- tableContents.append(System.getProperty("line.separator")); //$NON-NLS-1$
+ tableContents.append(System.lineSeparator());
StringBuilder temp;
//get the column contents from all the rows
@@ -157,7 +157,7 @@ public class CopyTableRenderingToClipboardAction extends Action
tableContents.append(temp);
}
- tableContents.append(System.getProperty("line.separator")); //$NON-NLS-1$
+ tableContents.append(System.lineSeparator());
}
return tableContents.toString();
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/EnvironmentTab.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/EnvironmentTab.java
index 9b1311656..ae81f0b27 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/EnvironmentTab.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/EnvironmentTab.java
@@ -712,7 +712,7 @@ public class EnvironmentTab extends AbstractLaunchConfigurationTab {
MultipleInputDialog dialog = new MultipleInputDialog(getShell(),
LaunchConfigurationsMessages.EnvironmentTab_11);
dialog.addTextField(NAME_LABEL, originalName, false);
- if (value != null && value.contains(System.getProperty("line.separator"))) { //$NON-NLS-1$
+ if (value != null && value.contains(System.lineSeparator())) {
dialog.addMultilinedVariablesField(VALUE_LABEL, value, true);
} else {
dialog.addVariablesField(VALUE_LABEL, value, true);

Back to the top