diff --git a/lib/sanselan-0.98-snapshot.jar b/lib/sanselan-0.98-snapshot.jar
index f61b34ec92b7..055d97ca320f 100644
Binary files a/lib/sanselan-0.98-snapshot.jar and b/lib/sanselan-0.98-snapshot.jar differ
diff --git a/lib/src/sanselan-0.98-snapshot-src.jar b/lib/src/sanselan-0.98-snapshot-src.jar
index 782638b13b48..a7a88ae646ad 100644
Binary files a/lib/src/sanselan-0.98-snapshot-src.jar and b/lib/src/sanselan-0.98-snapshot-src.jar differ
diff --git a/xml/impl/src/com/intellij/codeInsight/daemon/impl/analysis/CreateNSDeclarationIntentionFix.java b/xml/impl/src/com/intellij/codeInsight/daemon/impl/analysis/CreateNSDeclarationIntentionFix.java
index 4ef31b9582c3..d28e7d27b8e6 100644
--- a/xml/impl/src/com/intellij/codeInsight/daemon/impl/analysis/CreateNSDeclarationIntentionFix.java
+++ b/xml/impl/src/com/intellij/codeInsight/daemon/impl/analysis/CreateNSDeclarationIntentionFix.java
@@ -90,7 +90,7 @@ public class CreateNSDeclarationIntentionFix implements HintAction, LocalQuickFi
public CreateNSDeclarationIntentionFix(final PsiElement element,
final String namespacePrefix,
- final XmlToken token,
+ @Nullable final XmlToken token,
XmlFile containingFile) {
myNamespacePrefix = namespacePrefix;
myElement = element;
@@ -151,10 +151,12 @@ public class CreateNSDeclarationIntentionFix implements HintAction, LocalQuickFi
return;
} else {
prefix = ExtendedTagInsertHandler.suggestPrefix(xmlFile, namespace);
- if (StringUtil.isNotEmpty(prefix)) {
- ExtendedTagInsertHandler.qualifyWithPrefix(prefix, myElement);
- PsiDocumentManager.getInstance(project).doPostponedOperationsAndUnblockDocument(editor.getDocument());
+ if (StringUtil.isEmpty(prefix)) {
+ HintManager.getInstance().showInformationHint(editor, "Namespace not found");
+ return;
}
+ ExtendedTagInsertHandler.qualifyWithPrefix(prefix, myElement);
+ PsiDocumentManager.getInstance(project).doPostponedOperationsAndUnblockDocument(editor.getDocument());
}
}
final int offset = editor.getCaretModel().getOffset();
diff --git a/xml/impl/src/com/intellij/psi/XmlElementFactoryImpl.java b/xml/impl/src/com/intellij/psi/XmlElementFactoryImpl.java
index d640ebab40e3..0c524e199067 100644
--- a/xml/impl/src/com/intellij/psi/XmlElementFactoryImpl.java
+++ b/xml/impl/src/com/intellij/psi/XmlElementFactoryImpl.java
@@ -56,7 +56,7 @@ public class XmlElementFactoryImpl extends XmlElementFactory {
}
@NotNull
- public XmlAttribute createXmlAttribute(@NotNull String name, String value) throws IncorrectOperationException {
+ public XmlAttribute createXmlAttribute(@NotNull String name, @NotNull String value) throws IncorrectOperationException {
final char quoteChar;
if (!value.contains("\"")) {
quoteChar = '"';
diff --git a/xml/openapi/src/com/intellij/psi/XmlElementFactory.java b/xml/openapi/src/com/intellij/psi/XmlElementFactory.java
index 2e5d7c0c01ea..d94b87dbffad 100644
--- a/xml/openapi/src/com/intellij/psi/XmlElementFactory.java
+++ b/xml/openapi/src/com/intellij/psi/XmlElementFactory.java
@@ -86,5 +86,5 @@ public abstract class XmlElementFactory {
* @throws IncorrectOperationException if either name or value are not valid.
*/
@NotNull
- public abstract XmlAttribute createXmlAttribute(@NotNull @NonNls String name, String value) throws IncorrectOperationException;
+ public abstract XmlAttribute createXmlAttribute(@NotNull @NonNls String name, @NotNull String value) throws IncorrectOperationException;
}