mirror of
https://github.com/servo/servo.git
synced 2025-06-23 16:44:33 +01:00
auto merge of #2482 : Ms2ger/servo/rev_iter, r=jdm
This commit is contained in:
commit
2545647ceb
2 changed files with 3 additions and 3 deletions
|
@ -854,7 +854,7 @@ impl LayoutTask {
|
||||||
for item in iterator {
|
for item in iterator {
|
||||||
match *item {
|
match *item {
|
||||||
ClipDisplayItemClass(ref cc) => {
|
ClipDisplayItemClass(ref cc) => {
|
||||||
mouse_over_test(x, y, cc.children.list.rev_iter(), result);
|
mouse_over_test(x, y, cc.children.list.iter().rev(), result);
|
||||||
}
|
}
|
||||||
_ => {
|
_ => {
|
||||||
let bounds = item.bounds();
|
let bounds = item.bounds();
|
||||||
|
@ -881,7 +881,7 @@ impl LayoutTask {
|
||||||
Some(ref display_list) => {
|
Some(ref display_list) => {
|
||||||
mouse_over_test(x,
|
mouse_over_test(x,
|
||||||
y,
|
y,
|
||||||
display_list.list.rev_iter(),
|
display_list.list.iter().rev(),
|
||||||
&mut mouse_over_list);
|
&mut mouse_over_list);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -43,7 +43,7 @@ pub fn dispatch_event<'a, 'b>(target: &JSRef<'a, EventTarget>,
|
||||||
//FIXME: The "callback this value" should be currentTarget
|
//FIXME: The "callback this value" should be currentTarget
|
||||||
|
|
||||||
/* capturing */
|
/* capturing */
|
||||||
for cur_target in chain.as_slice().rev_iter() {
|
for cur_target in chain.as_slice().iter().rev() {
|
||||||
let stopped = match cur_target.get_listeners_for(type_, Capturing) {
|
let stopped = match cur_target.get_listeners_for(type_, Capturing) {
|
||||||
Some(listeners) => {
|
Some(listeners) => {
|
||||||
event.current_target.assign(Some(cur_target.deref().clone()));
|
event.current_target.assign(Some(cur_target.deref().clone()));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue