mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
style: Refactor children handling.
Moving traversal_children away from TNode I can make TNode trivial enough, in order to share a QuerySelector implementation between Servo and Gecko.
This commit is contained in:
parent
7c2265360f
commit
a11d268468
9 changed files with 149 additions and 158 deletions
|
@ -100,14 +100,6 @@ pub trait LayoutNode: Debug + GetLayoutData + TNode {
|
|||
fn traverse_preorder(self) -> TreeIterator<Self> {
|
||||
TreeIterator::new(self)
|
||||
}
|
||||
|
||||
fn first_child(&self) -> Option<Self>;
|
||||
|
||||
fn last_child(&self) -> Option<Self>;
|
||||
|
||||
fn prev_sibling(&self) -> Option<Self>;
|
||||
|
||||
fn next_sibling(&self) -> Option<Self>;
|
||||
}
|
||||
|
||||
pub struct ReverseChildrenIterator<ConcreteNode> where ConcreteNode: LayoutNode {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue