pub fn initialize(&mut self, window: Option<WindowId>, data: &T, env: &Env) -> PlatformMenu {
        if let Some(build) = &mut self.build {
            self.menu = Some((build)(window, data, env));
        }
        self.old_data = Some(data.clone());
        self.refresh(data, env)
    }
/// Build an initial menu from the application data.
Build an initial menu from the application data.
Build an initial menu from the application data .
pub fn initialize(&mut self, window: Option<WindowId>, data: &T, env: &Env) -> PlatformMenu {
        if let Some(build) = &mut self.build {
            self.menu = Some((build)(window, data, env));
        }
        self.old_data = Some(data.clone());
        self.refresh(data, env)
    }
pub fn initialize ( & mut self , window : Option < WindowId > , data : & T , env : & Env ) -> PlatformMenu { if let Some ( build ) = & mut self . build { self . menu = Some ( ( build ) ( window , data , env ) ) ; } self . old_data = Some ( data . clone ( ) ) ; self . refresh ( data , env ) }
Build an initial menu from the application data.
Build an initial menu from the application data .
&mut self
window
Option<WindowId>
data
&T
env
&Env
&mut self
window
Option<WindowId>
data
&T
env
&Env