From 2a721b7f3090748b152d59ae32136e405147902b Mon Sep 17 00:00:00 2001 From: "Eugene.Kudelevsky" Date: Mon, 12 Jul 2010 03:47:14 +0400 Subject: [PATCH] fix tests --- .../plugins/relaxNG/config/NoNamespaceSchemaProvider.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/relaxng/src/org/intellij/plugins/relaxNG/config/NoNamespaceSchemaProvider.java b/plugins/relaxng/src/org/intellij/plugins/relaxNG/config/NoNamespaceSchemaProvider.java index 556b68eb7c98..db4054aca590 100644 --- a/plugins/relaxng/src/org/intellij/plugins/relaxNG/config/NoNamespaceSchemaProvider.java +++ b/plugins/relaxng/src/org/intellij/plugins/relaxNG/config/NoNamespaceSchemaProvider.java @@ -50,6 +50,10 @@ public class NoNamespaceSchemaProvider extends XmlSchemaProvider { @Override public boolean isAvailable(@NotNull XmlFile file) { - return file.getFileType() == XmlFileType.INSTANCE; + if (file.getFileType() != XmlFileType.INSTANCE) { + return false; + } + NoNamespaceConfig config = NoNamespaceConfig.getInstance(file.getProject()); + return config != null && config.getMappedFile(file) != null; } } \ No newline at end of file