Skip to main content

UAShadowRoot

Trait UAShadowRoot 

Source
pub(crate) trait UAShadowRoot<ShadowTree> {
    // Required methods
    fn store_for_shadow_tree(
        &self,
        cx: &mut JSContext,
        shadow_root: DomRoot<ShadowRoot>,
    );
    fn borrow_for_shadow_tree(&self) -> Ref<'_, Option<ShadowTree>>;

    // Provided methods
    fn ensure_shadow_tree(
        &self,
        cx: &mut JSContext,
        element: &Element,
    ) -> Ref<'_, ShadowTree> { ... }
    fn should_mark_as_ua_widget(&self) -> bool { ... }
}

Required Methods§

Source

fn store_for_shadow_tree( &self, cx: &mut JSContext, shadow_root: DomRoot<ShadowRoot>, )

Source

fn borrow_for_shadow_tree(&self) -> Ref<'_, Option<ShadowTree>>

Provided Methods§

Source

fn ensure_shadow_tree( &self, cx: &mut JSContext, element: &Element, ) -> Ref<'_, ShadowTree>

Source

fn should_mark_as_ua_widget(&self) -> bool

TODO: Remove this method and fix the media element controls to properly be clickable

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§