fn redraw(&self)
    where
        MSG: Debug,
    {
        let mut new_view = Self::calculate_view_layout(
            &self.app.borrow(),
            *self.window_size.borrow(),
        );
        let (w, h) = *self.window_size.borrow();
        let (adjusted_w, adjusted_h) = (w as f32 - 0.0, h as f32 - 0.0);

        compute_node_layout(
            &mut new_view,
            Size {
                width: Number::Defined(adjusted_w),
                height: Number::Defined(adjusted_h),
            },
        );
        {
            let current_vdom = self.current_vdom.borrow();
            let diff = mt_dom::diff_with_key(
                &current_vdom,
                &new_view,
                &AttribKey::Key,
            );
            apply_patches::apply_patches(
                self,
                &current_vdom,
                &self.root_container(),
                &diff,
            );
        }
        *self.current_vdom.borrow_mut() = new_view;
    }
/// redraw the UI due to layout changes caused by resize on the main window
redraw the UI due to layout changes caused by resize on the main window
redraw the UI due to layout changes caused by resize on the main window
fn redraw(&self)
    where
        MSG: Debug,
    {
        let mut new_view = Self::calculate_view_layout(
            &self.app.borrow(),
            *self.window_size.borrow(),
        );
        let (w, h) = *self.window_size.borrow();
        let (adjusted_w, adjusted_h) = (w as f32 - 0.0, h as f32 - 0.0);
        compute_node_layout(
            &mut new_view,
            Size {
                width: Number::Defined(adjusted_w),
                height: Number::Defined(adjusted_h),
            },
        );
        {
            let current_vdom = self.current_vdom.borrow();
            let diff = mt_dom::diff_with_key(
                &current_vdom,
                &new_view,
                &AttribKey::Key,
            );
            apply_patches::apply_patches(
                self,
                &current_vdom,
                &self.root_container(),
                &diff,
            );
        }
        *self.current_vdom.borrow_mut() = new_view;
    }
fn redraw ( & self ) where MSG : Debug , { let mut new_view = Self :: calculate_view_layout ( & self . app . borrow ( ) , * self . window_size . borrow ( ) , ) ; let ( w , h ) = * self . window_size . borrow ( ) ; let ( adjusted_w , adjusted_h ) = ( w as f32 - 0.0 , h as f32 - 0.0 ) ; compute_node_layout ( & mut new_view , Size { width : Number :: Defined ( adjusted_w ) , height : Number :: Defined ( adjusted_h ) , } , ) ; { let current_vdom = self . current_vdom . borrow ( ) ; let diff = mt_dom :: diff_with_key ( & current_vdom , & new_view , & AttribKey :: Key , ) ; apply_patches :: apply_patches ( self , & current_vdom , & self . root_container ( ) , & diff , ) ; } * self . current_vdom . borrow_mut ( ) = new_view ; }
redraw the UI due to layout changes caused by resize on the main window
redraw the UI due to layout changes caused by resize on the main window
&self
&self