Struct sixtyfps_corelib::window::ComponentWindow [−][src]
The ComponentWindow is the (rust) facing public type that can render the items of components to the screen.
Implementations
impl ComponentWindow
[src]
impl ComponentWindow
[src]pub fn new(window_impl: Rc<Window>) -> Self
[src]
Creates a new instance of a CompomentWindow based on the given window implementation. Only used internally.
pub fn show(&self)
[src]
Registers the window with the windowing system, in order to render the component’s items and react to input events once the event loop spins.
pub fn hide(&self)
[src]
De-registers the window with the windowing system.
pub fn scale_factor(&self) -> f32
[src]
Returns the scale factor set on the window.
pub fn set_scale_factor(&self, factor: f32)
[src]
Sets an overriding scale factor for the window. This is typically only used for testing.
pub fn free_graphics_resources<'a>(&self, items: &Slice<'a, Pin<ItemRef<'a>>>)
[src]
This function is called by the generated code when a component and therefore its tree of items are destroyed. The implementation typically uses this to free the underlying graphics resources cached via RenderingCache.
pub fn set_focus_item(&self, focus_item: &ItemRc)
[src]
Clears the focus on any previously focused item and makes the provided item the focus item, in order to receive future key events.
pub fn set_component(&self, component: &ComponentRc)
[src]
Associates this window with the specified component, for future event handling, etc.
pub fn show_popup(&self, popup: &ComponentRc, position: Point)
[src]
Show a popup at the given position
pub fn close_popup(&self)
[src]
Close the active popup if any
Trait Implementations
impl Clone for ComponentWindow
[src]
impl Clone for ComponentWindow
[src]fn clone(&self) -> ComponentWindow
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
Auto Trait Implementations
impl !RefUnwindSafe for ComponentWindow
impl !RefUnwindSafe for ComponentWindow
impl !Send for ComponentWindow
impl !Send for ComponentWindow
impl !Sync for ComponentWindow
impl !Sync for ComponentWindow
impl Unpin for ComponentWindow
impl Unpin for ComponentWindow
impl !UnwindSafe for ComponentWindow
impl !UnwindSafe for ComponentWindow