pub fn move_child_by_pos<W: Into<ControlHandle>>(&self, col: u32, row: u32, new_col: u32, new_row: u32) {
        let base = {
            let mut inner = self.inner.borrow_mut();
            if inner.base.is_null() {
                panic!("GridLayout is not initialized");
            }

            let index = inner.children.iter().position(|item| item.col == col && item.row == row);
            match index {
                Some(i) => { 
                    let mut child = inner.children.remove(i); 
                    child.col = new_col;
                    child.row = new_row;
                    inner.children.push(child);
                },
                None => {}
            }
            
            inner.base
        };
        

        let (w, h) = unsafe { wh::get_window_size(base) };
        self.update_layout(w as u32, h as u32);
    }
/**
        Move the selected control to a new position in the grid layout. The old position
        becomes empty (as if `remove_child` was called). However it won't remove the control
        at the new position if there is one. 

        This method won't do anything if there is no control at the specified position.

        Panic:
        - If the layout is not initialized
    */
Move the selected control to a new position in the grid layout. The old position
becomes empty (as if `remove_child` was called). However it won't remove the control
at the new position if there is one.

This method won't do anything if there is no control at the specified position.

If the layout is not initialized
Move the selected control to a new position in the grid layout . The old position becomes empty ( as if ` remove_child ` was called ) . However it won ' t remove the control at the new position if there is one . This method won ' t do anything if there is no control at the specified position . If the layout is not initialized
pub fn move_child_by_pos<W: Into<ControlHandle>>(&self, col: u32, row: u32, new_col: u32, new_row: u32) {
        let base = {
            let mut inner = self.inner.borrow_mut();
            if inner.base.is_null() {
                panic!("GridLayout is not initialized");
            }
            let index = inner.children.iter().position(|item| item.col == col && item.row == row);
            match index {
                Some(i) => { 
                    let mut child = inner.children.remove(i); 
                    child.col = new_col;
                    child.row = new_row;
                    inner.children.push(child);
                },
                None => {}
            }
            inner.base
        };
        let (w, h) = unsafe { wh::get_window_size(base) };
        self.update_layout(w as u32, h as u32);
    }
pub fn move_child_by_pos < W : Into < ControlHandle > > ( & self , col : u32 , row : u32 , new_col : u32 , new_row : u32 ) { let base = { let mut inner = self . inner . borrow_mut ( ) ; if inner . base . is_null ( ) { panic ! ( " " ) ; } let index = inner . children . iter ( ) . position ( | item | item . col == col && item . row == row ) ; match index { Some ( i ) => { let mut child = inner . children . remove ( i ) ; child . col = new_col ; child . row = new_row ; inner . children . push ( child ) ; } , None => { } } inner . base } ; let ( w , h ) = unsafe { wh :: get_window_size ( base ) } ; self . update_layout ( w as u32 , h as u32 ) ; }
Move the selected control to a new position in the grid layout.
Move the selected control to a new position in the grid layout .
&self
col
u32
row
u32
new_col
u32
new_row
u32