bug 8300; rvd: floppy moose; aprvd: chofmann

This commit is contained in:
jfrancis%netscape.com 1999-06-16 23:40:16 +00:00
parent 2a037aa6e6
commit 78b68b1878
2 changed files with 2 additions and 2 deletions

View File

@ -1687,7 +1687,7 @@ nsHTMLEditRules::ReturnInHeader(nsIDOMSelection *aSelection,
// merge text node with like sibling, if any
nsCOMPtr<nsIDOMNode> sibling;
textNode->GetNextSibling(getter_AddRefs(sibling));
if (sibling)
if (sibling && mEditor->IsTextNode(sibling) && mEditor->IsEditable(sibling))
{
res = mEditor->JoinNodes(textNode,sibling,p);
if (NS_FAILED(res)) return res;

View File

@ -1687,7 +1687,7 @@ nsHTMLEditRules::ReturnInHeader(nsIDOMSelection *aSelection,
// merge text node with like sibling, if any
nsCOMPtr<nsIDOMNode> sibling;
textNode->GetNextSibling(getter_AddRefs(sibling));
if (sibling)
if (sibling && mEditor->IsTextNode(sibling) && mEditor->IsEditable(sibling))
{
res = mEditor->JoinNodes(textNode,sibling,p);
if (NS_FAILED(res)) return res;