mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
fixes dereferencing on an immutable reference (#31864)
This commit is contained in:
parent
585e0d69cd
commit
f7669b5238
32 changed files with 76 additions and 77 deletions
|
@ -277,7 +277,7 @@ impl Event {
|
|||
|
||||
// Step 5.13
|
||||
for object in event_path.iter().rev() {
|
||||
if &**object == &*target {
|
||||
if &**object == target {
|
||||
self.phase.set(EventPhase::AtTarget);
|
||||
} else {
|
||||
self.phase.set(EventPhase::Capturing);
|
||||
|
@ -298,7 +298,7 @@ impl Event {
|
|||
|
||||
// Step 5.14
|
||||
for object in event_path.iter() {
|
||||
let at_target = &**object == &*target;
|
||||
let at_target = &**object == target;
|
||||
if at_target || self.bubbles.get() {
|
||||
self.phase.set(if at_target {
|
||||
EventPhase::AtTarget
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue