diff --git a/platform/platform-api/src/com/intellij/openapi/ui/MasterDetailsComponent.java b/platform/platform-api/src/com/intellij/openapi/ui/MasterDetailsComponent.java index 77f1f6e6ab9e..604cd4487911 100644 --- a/platform/platform-api/src/com/intellij/openapi/ui/MasterDetailsComponent.java +++ b/platform/platform-api/src/com/intellij/openapi/ui/MasterDetailsComponent.java @@ -1,4 +1,4 @@ -// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. +// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.openapi.ui; import com.intellij.CommonBundle; @@ -681,14 +681,14 @@ public abstract class MasterDetailsComponent implements Configurable, DetailsCom final String name = scopeConfigurable.getDisplayName(); if (name.trim().isEmpty()) { selectNodeInTree(node); - throw new ConfigurationException("Name should contain non-space characters"); + throw new ConfigurationException(UIBundle.message("master.detail.err.empty.name")); } if (names.contains(name)) { final NamedConfigurable selectedConfigurable = getSelectedConfigurable(); if (selectedConfigurable == null || !Comparing.strEqual(selectedConfigurable.getDisplayName(), name)) { selectNodeInTree(node); } - throw new ConfigurationException(CommonBundle.message("smth.already.exist.error.message", prefix, name), title); + throw new ConfigurationException(UIBundle.message("master.detail.err.duplicate", prefix, name), title); } names.add(name); } diff --git a/platform/platform-resources-en/src/messages/CommonBundle.properties b/platform/platform-resources-en/src/messages/CommonBundle.properties index 69647ee2417b..beee4aac690c 100644 --- a/platform/platform-resources-en/src/messages/CommonBundle.properties +++ b/platform/platform-resources-en/src/messages/CommonBundle.properties @@ -70,7 +70,7 @@ button.background=&Background button.load.file=Load File date.frequency=Once {0} name.label.text=Na&me: -smth.already.exist.error.message={0} with name ''{1}'' already exists + comparison.policy.default.name=Default comparison.policy.trim.space.name=Trim space comparison.policy.ignore.spaces.name=Ignore spaces diff --git a/platform/platform-resources-en/src/messages/UIBundle.properties b/platform/platform-resources-en/src/messages/UIBundle.properties index dc8792c55550..7086284adf4d 100644 --- a/platform/platform-resources-en/src/messages/UIBundle.properties +++ b/platform/platform-resources-en/src/messages/UIBundle.properties @@ -217,3 +217,6 @@ date.dialog.title=Choose Date io.error.dialog.no.proxy=Set up HTTP proxy settings io.error.dialog.retry=Try again + +master.detail.err.empty.name=Name should contain non-space characters +master.detail.err.duplicate={0} with the name ''{1}'' already exists \ No newline at end of file