pub fn js_set_auto_size(&mut self, autosize: bool) {
        if autosize {
            let handle = Some(ResizeObserverHandle::new(
                &self.elem,
                &self.renderer,
                self.root.borrow().as_ref().unwrap(),
            ));
            *self.resize_handle.borrow_mut() = handle;
        } else {
            *self.resize_handle.borrow_mut() = None;
        }
    }
/// Sets the auto-size behavior of this component.  When `true`, this
/// `<perspective-viewer>` will register a `ResizeObserver` on itself and
/// call `resize()` whenever its own dimensions change.
///
/// # Arguments
/// - `autosize` Whether to register a `ResizeObserver` on this element or
///   not.
Sets the auto-size behavior of this component.
Sets the auto - size behavior of this component .
pub fn js_set_auto_size(&mut self, autosize: bool) {
        if autosize {
            let handle = Some(ResizeObserverHandle::new(
                &self.elem,
                &self.renderer,
                self.root.borrow().as_ref().unwrap(),
            ));
            *self.resize_handle.borrow_mut() = handle;
        } else {
            *self.resize_handle.borrow_mut() = None;
        }
    }
pub fn js_set_auto_size ( & mut self , autosize : bool ) { if autosize { let handle = Some ( ResizeObserverHandle :: new ( & self . elem , & self . renderer , self . root . borrow ( ) . as_ref ( ) . unwrap ( ) , ) ) ; * self . resize_handle . borrow_mut ( ) = handle ; } else { * self . resize_handle . borrow_mut ( ) = None ; } }
Sets the auto-size behavior of this component.
Sets the auto - size behavior of this component .
&mut self
autosize
bool
&mut self
autosize
bool
Whether to register a `ResizeObserver` on this element or
not.
Whether to register a ` ResizeObserver ` on this element or not .