fractal::components::context_menu_bin

Trait ContextMenuBinExt

Source
pub trait ContextMenuBinExt: 'static {
    // Required methods
    fn has_context_menu(&self) -> bool;
    fn set_has_context_menu(&self, has_context_menu: bool);
    fn popover(&self) -> Option<PopoverMenu>;
    fn set_popover(&self, popover: Option<PopoverMenu>);
    fn child(&self) -> Option<Widget>;
    fn set_child(&self, child: Option<&impl IsA<Widget>>);
    fn menu_opened(&self);
}

Required Methods§

Source

fn has_context_menu(&self) -> bool

Whether this widget has a context menu.

Source

fn set_has_context_menu(&self, has_context_menu: bool)

Set whether this widget has a context menu.

Source

fn popover(&self) -> Option<PopoverMenu>

Get the PopoverMenu used in the context menu.

Source

fn set_popover(&self, popover: Option<PopoverMenu>)

Set the PopoverMenu used in the context menu.

Source

fn child(&self) -> Option<Widget>

Get the child widget.

Source

fn set_child(&self, child: Option<&impl IsA<Widget>>)

Set the child widget.

Source

fn menu_opened(&self)

Called when the menu was requested to open but before the menu is shown.

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.

Implementors§