pub trait NativeUi<UI> {
// Required method
fn build_ui(inital_state: Self) -> Result<UI, NwgError>;
}
Expand description
A structure that implements this trait is considered a GUI structure. The structure will hold GUI components and possibly user data.
The goal of NativeUi
and PartialUi
is to provide a common way to define NWG applications.
Native-windows-derive can automatically implement this trait.
For an example on how to implement this trait, see the Small application layout section in the NWG documentation.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.