Home | History | Annotate | Download | only in page

Lines Matching full:node

35 #include "Node.h"
44 static Node* selectionShadowAncestor(Frame* frame)
46 Node* node = frame->selection()->selection().base().anchorNode();
47 if (!node)
49 Node* shadowAncestor = node->shadowAncestorNode();
50 if (shadowAncestor == node)
98 Node* DOMSelection::anchorNode() const
102 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
104 return anchorPosition(visibleSelection()).node();
111 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
116 Node* DOMSelection::focusNode() const
120 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
122 return focusPosition(visibleSelection()).node();
129 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
134 Node* DOMSelection::baseNode() const
138 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
140 return basePosition(visibleSelection()).node();
147 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
152 Node* DOMSelection::extentNode() const
156 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
158 return extentPosition(visibleSelection()).node();
165 if (Node* shadowAncestor = selectionShadowAncestor(m_frame))
201 void DOMSelection::collapse(Node* node, int offset, ExceptionCode& ec)
210 m_frame->selection()->moveTo(VisiblePosition(node, offset, DOWNSTREAM));
238 void DOMSelection::setBaseAndExtent(Node* baseNode, int baseOffset, Node* extentNode, int extentOffset, ExceptionCode& ec)
253 void DOMSelection::setPosition(Node* node, int offset, ExceptionCode& ec)
261 m_frame->selection()->moveTo(VisiblePosition(node, offset, DOWNSTREAM));
314 void DOMSelection::extend(Node* node, int offset, ExceptionCode& ec)
319 if (!node) {
323 if (offset < 0 || offset > (node->offsetInCharacters() ? caretMaxOffset(node) : (int)node->childNodeCount())) {
330 selection->setExtent(VisiblePosition(node, offset, DOWNSTREAM));
346 if (Node* shadowAncestor = selectionShadowAncestor(m_frame)) {
347 Node* container = shadowAncestor->parentNode();
425 bool DOMSelection::containsNode(const Node* n, bool allowPartial) const
435 Node* parentNode = n->parentNode();
458 void DOMSelection::selectAllChildren(Node* n, ExceptionCode& ec)
463 // This doesn't (and shouldn't) select text node characters.