mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-04 02:57:38 +00:00
fixes 88109: caret jumps down when typing after inserting table. One liner to properly set selection after table insertion. r=fm;sr=kin
This commit is contained in:
parent
141ff38c0f
commit
e317c80316
@ -1801,6 +1801,7 @@ nsHTMLEditor::InsertElementAtSelection(nsIDOMElement* aElement, PRBool aDeleteSe
|
||||
nsCOMPtr<nsIDOMNode> brNode;
|
||||
res = CreateBR(parentSelectedNode, offsetForInsert+1, address_of(brNode));
|
||||
if (NS_FAILED(res)) return res;
|
||||
selection->Collapse(parentSelectedNode, offsetForInsert+1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1801,6 +1801,7 @@ nsHTMLEditor::InsertElementAtSelection(nsIDOMElement* aElement, PRBool aDeleteSe
|
||||
nsCOMPtr<nsIDOMNode> brNode;
|
||||
res = CreateBR(parentSelectedNode, offsetForInsert+1, address_of(brNode));
|
||||
if (NS_FAILED(res)) return res;
|
||||
selection->Collapse(parentSelectedNode, offsetForInsert+1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user