mirror of
https://github.com/servo/servo.git
synced 2025-07-16 11:53:39 +01:00
Implement GlobalRef::reflector as an inherent method.
Reflectable is meant for actual DOM objects, not for references to them.
This commit is contained in:
parent
94aa8ca80a
commit
9be52dc41a
1 changed files with 2 additions and 3 deletions
|
@ -196,10 +196,9 @@ impl<'a> GlobalRef<'a> {
|
|||
GlobalRef::Worker(worker) => worker.set_devtools_wants_updates(send_updates),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> Reflectable for GlobalRef<'a> {
|
||||
fn reflector(&self) -> &Reflector {
|
||||
/// Returns the receiver's reflector.
|
||||
pub fn reflector(&self) -> &Reflector {
|
||||
match *self {
|
||||
GlobalRef::Window(ref window) => window.reflector(),
|
||||
GlobalRef::Worker(ref worker) => worker.reflector(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue