mark strings as not for externalization
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/Logger.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/Logger.java index 7b3131c..d834649 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/Logger.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/Logger.java
@@ -26,19 +26,19 @@ /** * Controls debugging output for loading/storing of the Snippets model */ - public static final boolean DEBUG_DEFINITION_PERSISTENCE = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/definition_persistence")); //$NON-NLS-1$ + public static final boolean DEBUG_DEFINITION_PERSISTENCE = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/definition_persistence")); //$NON-NLS-1$ //$NON-NLS-2$ /** * Controls debugging output for drag and drop processing */ - public static final boolean DEBUG_DRAG_AND_DROP = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/drag_and_drop")); //$NON-NLS-1$ + public static final boolean DEBUG_DRAG_AND_DROP = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/drag_and_drop")); //$NON-NLS-1$ //$NON-NLS-2$ /** * Controls debugging output for selection within the view */ - public static final boolean DEBUG_PALETTE_SELECTION = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/palette_selection")); //$NON-NLS-1$ + public static final boolean DEBUG_PALETTE_SELECTION = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/palette_selection")); //$NON-NLS-1$ //$NON-NLS-2$ /** * Controls debugging output for replacement of the model's category list */ - public static final boolean DEBUG_VIEWER_CONTENT = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/viewer_content")); //$NON-NLS-1$ + public static final boolean DEBUG_VIEWER_CONTENT = "true".equalsIgnoreCase(Platform.getDebugOption("org.eclipse.wst.common.snippets/debug/viewer_content")); //$NON-NLS-1$ //$NON-NLS-2$ public static final int ERROR = IStatus.ERROR; // 4 public static final int ERROR_DEBUG = 200 + ERROR;
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/AbstractModelFactory.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/AbstractModelFactory.java index 74e503e..dc3c2c5 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/AbstractModelFactory.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/AbstractModelFactory.java
@@ -166,7 +166,7 @@ return; Object propertyValue = value; if (propertyValue == null) { - propertyValue = ""; + propertyValue = ""; //$NON-NLS-1$ } if (property.equals(SnippetsPlugin.NAMES.CATEGORY)) item.setCategoryName(propertyValue.toString()); @@ -185,7 +185,7 @@ return; Object propertyValue = value; if (propertyValue == null) { - propertyValue = ""; + propertyValue = ""; //$NON-NLS-1$ } if (property.equals(SnippetsPlugin.NAMES.DEFAULT)) variable.setDefaultValue(propertyValue.toString());
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/ModelFactoryForUser.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/ModelFactoryForUser.java index 20061e2..c460b44 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/ModelFactoryForUser.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/ModelFactoryForUser.java
@@ -136,9 +136,9 @@ * (https://bugs.eclipse.org/bugs/show_bug.cgi?id=102941). Convert * '\n' to native EOL. */ - String systemEOL = System.getProperty("line.separator"); - if (!"\n".equals(systemEOL)) { - content = StringUtils.replace(content, "\n", systemEOL); + String systemEOL = System.getProperty("line.separator"); //$NON-NLS-1$ + if (!"\n".equals(systemEOL)) { //$NON-NLS-1$ + content = StringUtils.replace(content, "\n", systemEOL); //$NON-NLS-1$ } return content; }
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/UserModelDumper.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/UserModelDumper.java index 34addc8..d7a6b57 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/UserModelDumper.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/palette/UserModelDumper.java
@@ -137,8 +137,8 @@ * (https://bugs.eclipse.org/bugs/show_bug.cgi?id=102941). * Normalize to '\n'. */ - contents = StringUtils.replace(contents, "\r\n", "\n"); - contents = StringUtils.replace(contents, "\r", "\n"); + contents = StringUtils.replace(contents, "\r\n", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ + contents = StringUtils.replace(contents, "\r", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ element.appendChild(doc.createCDATASection(contents)); } return element;
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/util/XMLDocumentProvider.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/util/XMLDocumentProvider.java index 6655e5a..a33d033 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/util/XMLDocumentProvider.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/internal/util/XMLDocumentProvider.java
@@ -213,7 +213,7 @@ result.removeChild(children.item(i)); } // we're going through this effort to avoid a NS element - Element settings = result.createElementNS("http://www.w3.org/XML/1998/namespace", getRootElementName()); + Element settings = result.createElementNS("http://www.w3.org/XML/1998/namespace", getRootElementName()); //$NON-NLS-1$ result.appendChild(settings); return result; }
diff --git a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/ui/DefaultSnippetInsertion.java b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/ui/DefaultSnippetInsertion.java index 3af8269..10dc1f4 100644 --- a/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/ui/DefaultSnippetInsertion.java +++ b/org.eclipse.wst.common.snippets/src/org/eclipse/wst/common/snippets/ui/DefaultSnippetInsertion.java
@@ -65,8 +65,8 @@ String replacement = getInsertString(editorPart.getEditorSite().getShell()); if (replacement != null && (replacement.length() > 0 || textSelection.getLength() > 0)) { // Update EOLs (bug 80231) - replacement = StringUtils.replace(replacement, "\r\n", "\n"); - replacement = StringUtils.replace(replacement, "\r", "\n"); + replacement = StringUtils.replace(replacement, "\r\n", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ + replacement = StringUtils.replace(replacement, "\r", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ String preferredEOL = null; if (document instanceof IDocumentExtension4) { @@ -94,10 +94,10 @@ } if (preferredEOL == null) { - preferredEOL = System.getProperty("line.separator"); + preferredEOL = System.getProperty("line.separator"); //$NON-NLS-1$ } - if (!"\n".equals(preferredEOL) && preferredEOL != null) { - replacement = StringUtils.replace(replacement, "\n", preferredEOL); + if (!"\n".equals(preferredEOL) && preferredEOL != null) { //$NON-NLS-1$ + replacement = StringUtils.replace(replacement, "\n", preferredEOL); //$NON-NLS-1$ } document.replace(textSelection.getOffset(), textSelection.getLength(), replacement); @@ -115,11 +115,11 @@ } String content = VariableItemHelper.getInsertString(shell, item); // Update EOLs (bug 80231) - String systemEOL = System.getProperty("line.separator"); - content = StringUtils.replace(content, "\r\n", "\n"); - content = StringUtils.replace(content, "\r", "\n"); - if (!"\n".equals(systemEOL) && systemEOL != null) { - content = StringUtils.replace(content, "\n", systemEOL); + String systemEOL = System.getProperty("line.separator"); //$NON-NLS-1$ + content = StringUtils.replace(content, "\r\n", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ + content = StringUtils.replace(content, "\r", "\n"); //$NON-NLS-1$ //$NON-NLS-2$ + if (!"\n".equals(systemEOL) && systemEOL != null) { //$NON-NLS-1$ + content = StringUtils.replace(content, "\n", systemEOL); //$NON-NLS-1$ } event.data = content; }