fn update_size(&self) {
        let (width, height) = self.canvas.size();
    
        // After the texture was resized write the new data to the shared memory
        self.canvas.resize_texture(width, height, true);
        self.update_texture();

        // Resize the viewport
        self.canvas.resize();
        self.canvas.render();

        // Saves the new window size and propagate the events to the other instances
        let data = self.data.borrow();
        data.set_window_size(self.window.size());
        data.sync();
    }
/// Resize the canvas to match the new window size. Also update the shared texture data.
Resize the canvas to match the new window size. Also update the shared texture data.
Resize the canvas to match the new window size . Also update the shared texture data .
fn update_size(&self) {
        let (width, height) = self.canvas.size();
        // After the texture was resized write the new data to the shared memory
        self.canvas.resize_texture(width, height, true);
        self.update_texture();
        // Resize the viewport
        self.canvas.resize();
        self.canvas.render();
        // Saves the new window size and propagate the events to the other instances
        let data = self.data.borrow();
        data.set_window_size(self.window.size());
        data.sync();
    }
fn update_size ( & self ) { let ( width , height ) = self . canvas . size ( ) ; // After the texture was resized write the new data to the shared memory self . canvas . resize_texture ( width , height , true ) ; self . update_texture ( ) ; // Resize the viewport self . canvas . resize ( ) ; self . canvas . render ( ) ; // Saves the new window size and propagate the events to the other instances let data = self . data . borrow ( ) ; data . set_window_size ( self . window . size ( ) ) ; data . sync ( ) ; }
Resize the canvas to match the new window size.
Resize the canvas to match the new window size .
&self