removeBetween method
void
removeBetween(
- Node? previousChild,
- Node? nextChild,
- Node oldChild
)
Implementation
void removeBetween(Node? previousChild, Node? nextChild, Node oldChild) {
assert(oldChild.parentNode == this);
if (nextChild != null) {
nextChild..previousSibling = previousChild;
}
if (previousChild != null) {
previousChild.nextSibling = nextChild;
}
if (firstChild == oldChild) {
firstChild = nextChild;
}
if (lastChild == oldChild) {
lastChild = previousChild;
}
oldChild.previousSibling = null;
oldChild.nextSibling = null;
oldChild.parentOrShadowHostNode = null;
}