Skip to main content

CloseWatcherMethods

pub trait CloseWatcherMethods<D: DomTypes> {
    // Required methods
    fn RequestClose(&self, cx: &mut JSContext);
    fn Close(&self, cx: &mut JSContext);
    fn Destroy(&self, cx: &mut JSContext);
    fn GetOncancel(
        &self,
        cx: &mut JSContext,
    ) -> Option<RootedCallback<EventHandlerNonNull<D>>>;
    fn SetOncancel(
        &self,
        cx: &mut JSContext,
        value: Option<RootedCallback<EventHandlerNonNull<D>>>,
    );
    fn GetOnclose(
        &self,
        cx: &mut JSContext,
    ) -> Option<RootedCallback<EventHandlerNonNull<D>>>;
    fn SetOnclose(
        &self,
        cx: &mut JSContext,
        value: Option<RootedCallback<EventHandlerNonNull<D>>>,
    );
    fn Constructor(
        cx: &mut JSContext,
        global: &D::Window,
        proto: Option<HandleObject<'_>>,
        options: &CloseWatcherOptions<D>,
    ) -> Fallible<DomRoot<D::CloseWatcher>>;
}

Required Methods§

Source

fn RequestClose(&self, cx: &mut JSContext)

Source

fn Close(&self, cx: &mut JSContext)

Source

fn Destroy(&self, cx: &mut JSContext)

Source

fn GetOncancel( &self, cx: &mut JSContext, ) -> Option<RootedCallback<EventHandlerNonNull<D>>>

Source

fn SetOncancel( &self, cx: &mut JSContext, value: Option<RootedCallback<EventHandlerNonNull<D>>>, )

Source

fn GetOnclose( &self, cx: &mut JSContext, ) -> Option<RootedCallback<EventHandlerNonNull<D>>>

Source

fn SetOnclose( &self, cx: &mut JSContext, value: Option<RootedCallback<EventHandlerNonNull<D>>>, )

Source

fn Constructor( cx: &mut JSContext, global: &D::Window, proto: Option<HandleObject<'_>>, options: &CloseWatcherOptions<D>, ) -> Fallible<DomRoot<D::CloseWatcher>>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§