diff options
| author | kitlo | 2018-12-10 18:56:04 +0000 |
|---|---|---|
| committer | Lars Vogel | 2018-12-13 10:49:52 +0000 |
| commit | b9a0a04566089d81f1909d3ea4733a11c62eb944 (patch) | |
| tree | e5adbecb9b9bc93c4dd0bf52ea174e13722a762c | |
| parent | 0a0e44733a94e46826345c7d6be8f75afd4b871a (diff) | |
| download | eclipse.pde.ui-b9a0a04566089d81f1909d3ea4733a11c62eb944.tar.gz eclipse.pde.ui-b9a0a04566089d81f1909d3ea4733a11c62eb944.tar.xz eclipse.pde.ui-b9a0a04566089d81f1909d3ea4733a11c62eb944.zip | |
Bug 244461 - Duplicating colon in error message
Change-Id: Idef56221389bf7411ca02a210240988593b906cc
Signed-off-by: kitlo <kitlo@us.ibm.com>
3 files changed, 10 insertions, 4 deletions
diff --git a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/PDEUIMessages.java b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/PDEUIMessages.java index 2755433486..3f19a81471 100644 --- a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/PDEUIMessages.java +++ b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/PDEUIMessages.java @@ -15,6 +15,7 @@ * Fabian Miehe - Bug 440420 * Martin Karpisek <martin.karpisek@gmail.com> - Bug 438509 * Axel Richard (Obeo) - Bug 41353 - Launch configurations prototypes + * Kit Lo (IBM) - Bug 244461 - Duplicating colon in error message *******************************************************************************/ package org.eclipse.pde.internal.ui; @@ -1200,6 +1201,7 @@ public class PDEUIMessages extends NLS { public static String ContentPage_pClassGroup; public static String ContentPage_pid; public static String ContentPage_pversion; + public static String ContentPage_pversion_message; public static String ContentPage_pname; public static String ContentPage_pprovider; public static String ContentPage_fid; diff --git a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/pderesources.properties b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/pderesources.properties index 814db12c88..a74c8652f9 100644 --- a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/pderesources.properties +++ b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/pderesources.properties @@ -17,6 +17,7 @@ # Lars Vogel <Lars.Vogel@vogella.com> - Bug 473877 # Martin Karpisek <martin.karpisek@gmail.com> - Bug 438509 # Axel Richard (Obeo) - Bug 41353 - Launch configurations prototypes +# Kit Lo (IBM) - Bug 244461 - Duplicating colon in error message ############################################################################### ##################################### # PDE resource strings @@ -761,6 +762,7 @@ ContentSection_2=The features selected below will be included in this target def ContentPage_pClassGroup = Options ContentPage_pid = &ID: ContentPage_pversion = &Version: +ContentPage_pversion_message = Version: {0} ContentPage_pname = N&ame: ContentPage_pprovider = Ven&dor: ContentPage_fid = &ID: diff --git a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/wizards/plugin/ContentPage.java b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/wizards/plugin/ContentPage.java index 0e70e80d6b..c56ca51828 100644 --- a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/wizards/plugin/ContentPage.java +++ b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/wizards/plugin/ContentPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2015 IBM Corporation and others. + * Copyright (c) 2000, 2018 IBM Corporation and others. * * This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -10,17 +10,19 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Kit Lo (IBM) - Bug 244461 - Duplicating colon in error message *******************************************************************************/ package org.eclipse.pde.internal.ui.wizards.plugin; +import java.text.MessageFormat; + import org.eclipse.core.runtime.IStatus; import org.eclipse.jface.dialogs.IDialogSettings; import org.eclipse.jface.wizard.IWizardPage; import org.eclipse.jface.wizard.WizardPage; import org.eclipse.pde.internal.core.util.*; import org.eclipse.pde.internal.ui.PDEUIMessages; -import org.eclipse.pde.internal.ui.util.PDELabelUtility; import org.eclipse.pde.internal.ui.wizards.BundleProviderHistoryUtil; import org.eclipse.pde.internal.ui.wizards.IProjectProvider; import org.eclipse.pde.ui.IFieldData; @@ -122,9 +124,9 @@ public abstract class ContentPage extends WizardPage { */ protected String validateVersion(Text text) { if (text.getText().trim().length() == 0) { - return PDELabelUtility.qualifyMessage(PDELabelUtility.getFieldLabel(text), PDEUIMessages.ControlValidationUtility_errorMsgValueMustBeSpecified); + return MessageFormat.format(PDEUIMessages.ContentPage_pversion_message, PDEUIMessages.ControlValidationUtility_errorMsgValueMustBeSpecified); } else if (!isVersionValid(text.getText().trim())) { - return PDELabelUtility.qualifyMessage(PDELabelUtility.getFieldLabel(text), UtilMessages.BundleErrorReporter_InvalidFormatInBundleVersion); + return MessageFormat.format(PDEUIMessages.ContentPage_pversion_message, UtilMessages.BundleErrorReporter_InvalidFormatInBundleVersion); } return null; } |
