pub trait OwnerWindow<D: DomTypes> {
// Provided method
fn owner_window(&self) -> Option<DomRoot<D::Window>> { ... }
}Expand description
Try to obtain a Window object from a callback target. This Window may be different than the callback’s associated global if the owner has been adopted into a different realm than it was created in. As such, the default implementation should be used for any callback target that cannot be adopted (i.e. is not a descendant of Node).